Update all Performance Scenario callers to use scenario_api paths
Remove the Blink forwarding headers. Bug: 365586676 Change-Id: I5f904df4f11e297e3a5ab289dc35739098b997f8 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6262781 Commit-Queue: Joe Mason <joenotcharles@google.com> Reviewed-by: Dave Tapuska <dtapuska@chromium.org> Reviewed-by: Orin Jaworski <orinj@chromium.org> Reviewed-by: Jeremy Roman <jbroman@chromium.org> Cr-Commit-Position: refs/heads/main@{#1420136}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
3e53a94893
commit
5e3b89e6ea
components/passage_embeddings
content
DEPS
browser
BUILD.gn
renderer_host
child
BUILD.gnchild_performance_coordinator.ccchild_performance_coordinator.hchild_performance_coordinator_unittest.cc
test
third_party/blink
public
common
tools
blinkpy
presubmit
@ -28,13 +28,10 @@ static_library("passage_embeddings") {
|
||||
"//build:blink_buildflags",
|
||||
"//components/optimization_guide/core",
|
||||
"//components/optimization_guide/proto:optimization_guide_proto",
|
||||
"//components/performance_manager/scenario_api",
|
||||
"//mojo/public/cpp/bindings",
|
||||
"//services/passage_embeddings/public/mojom",
|
||||
]
|
||||
|
||||
if (use_blink) {
|
||||
deps += [ "//third_party/blink/public/common:headers" ]
|
||||
}
|
||||
}
|
||||
|
||||
source_set("unit_tests") {
|
||||
|
@ -2,7 +2,7 @@ include_rules = [
|
||||
"+components/keyed_service/core",
|
||||
"+components/optimization_guide/core",
|
||||
"+components/optimization_guide/proto",
|
||||
"+components/performance_manager/scenario_api",
|
||||
"+mojo/public/cpp/bindings",
|
||||
"+services/passage_embeddings/public/mojom",
|
||||
"+third_party/blink/public/common",
|
||||
]
|
||||
|
@ -22,11 +22,9 @@ namespace passage_embeddings {
|
||||
|
||||
namespace {
|
||||
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
using ScenarioScope = blink::performance_scenarios::ScenarioScope;
|
||||
using LoadingScenario = blink::performance_scenarios::LoadingScenario;
|
||||
using InputScenario = blink::performance_scenarios::InputScenario;
|
||||
#endif
|
||||
using ScenarioScope = performance_scenarios::ScenarioScope;
|
||||
using LoadingScenario = performance_scenarios::LoadingScenario;
|
||||
using InputScenario = performance_scenarios::InputScenario;
|
||||
|
||||
std::string PassagePriorityToString(PassagePriority priority) {
|
||||
switch (priority) {
|
||||
@ -100,17 +98,12 @@ SchedulingEmbedder::SchedulingEmbedder(std::unique_ptr<Embedder> embedder,
|
||||
max_jobs_(max_jobs),
|
||||
max_batch_size_(max_batch_size),
|
||||
use_performance_scenario_(use_performance_scenario) {
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
if (use_performance_scenario_) {
|
||||
performance_scenario_observation_.Observe(
|
||||
blink::performance_scenarios::PerformanceScenarioObserverList::
|
||||
GetForScope(ScenarioScope::kGlobal)
|
||||
.get());
|
||||
performance_scenarios::PerformanceScenarioObserverList::GetForScope(
|
||||
ScenarioScope::kGlobal)
|
||||
.get());
|
||||
}
|
||||
#else
|
||||
// Performance scenario is not supported on some builds (e.g. iOS by default).
|
||||
use_performance_scenario_ = false;
|
||||
#endif
|
||||
}
|
||||
|
||||
SchedulingEmbedder::~SchedulingEmbedder() = default;
|
||||
@ -215,7 +208,6 @@ void SchedulingEmbedder::SubmitWorkToEmbedder() {
|
||||
}
|
||||
|
||||
bool SchedulingEmbedder::IsPerformanceScenarioReady() {
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
if (!jobs_.empty() &&
|
||||
jobs_.front().priority == PassagePriority::kUserInitiated) {
|
||||
// Do not block on performance scenario if user initiated a query.
|
||||
@ -223,17 +215,14 @@ bool SchedulingEmbedder::IsPerformanceScenarioReady() {
|
||||
}
|
||||
|
||||
LoadingScenario loading_scenario =
|
||||
blink::performance_scenarios::GetLoadingScenario(ScenarioScope::kGlobal)
|
||||
performance_scenarios::GetLoadingScenario(ScenarioScope::kGlobal)
|
||||
->load(std::memory_order_relaxed);
|
||||
InputScenario input_scenario =
|
||||
blink::performance_scenarios::GetInputScenario(ScenarioScope::kGlobal)
|
||||
performance_scenarios::GetInputScenario(ScenarioScope::kGlobal)
|
||||
->load(std::memory_order_relaxed);
|
||||
return (loading_scenario == LoadingScenario::kNoPageLoading ||
|
||||
loading_scenario == LoadingScenario::kBackgroundPageLoading) &&
|
||||
input_scenario == InputScenario::kNoInput;
|
||||
#else
|
||||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
void SchedulingEmbedder::SetOnEmbedderReadyCallback(
|
||||
@ -270,7 +259,6 @@ void SchedulingEmbedder::SetEmbedderMetadata(EmbedderMetadata metadata) {
|
||||
SubmitWorkToEmbedder();
|
||||
}
|
||||
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
void SchedulingEmbedder::OnLoadingScenarioChanged(
|
||||
ScenarioScope scope,
|
||||
LoadingScenario old_scenario,
|
||||
@ -287,7 +275,6 @@ void SchedulingEmbedder::OnInputScenarioChanged(ScenarioScope scope,
|
||||
<< static_cast<int>(new_scenario);
|
||||
SubmitWorkToEmbedder();
|
||||
}
|
||||
#endif
|
||||
|
||||
void SchedulingEmbedder::OnEmbeddingsComputed(std::vector<std::string> passages,
|
||||
std::vector<Embedding> embeddings,
|
||||
|
@ -16,15 +16,11 @@
|
||||
#include "base/scoped_observation.h"
|
||||
#include "base/time/time.h"
|
||||
#include "base/timer/elapsed_timer.h"
|
||||
#include "build/blink_buildflags.h"
|
||||
#include "build/build_config.h"
|
||||
#include "components/passage_embeddings/embedder.h"
|
||||
#include "components/passage_embeddings/passage_embeddings_types.h"
|
||||
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
#include "third_party/blink/public/common/performance/performance_scenario_observer.h"
|
||||
#include "third_party/blink/public/common/performance/performance_scenarios.h"
|
||||
#endif
|
||||
#include "components/performance_manager/scenario_api/performance_scenario_observer.h"
|
||||
#include "components/performance_manager/scenario_api/performance_scenarios.h"
|
||||
|
||||
namespace passage_embeddings {
|
||||
|
||||
@ -35,12 +31,8 @@ namespace passage_embeddings {
|
||||
// changes, all existing passages need their embeddings recomputed, which can
|
||||
// take a very long time and should be done at lower priority.
|
||||
class SchedulingEmbedder
|
||||
: public Embedder
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
,
|
||||
public blink::performance_scenarios::PerformanceScenarioObserver
|
||||
#endif
|
||||
{
|
||||
: public Embedder,
|
||||
public performance_scenarios::PerformanceScenarioObserver {
|
||||
public:
|
||||
SchedulingEmbedder(std::unique_ptr<Embedder> embedder,
|
||||
size_t max_jobs,
|
||||
@ -75,17 +67,15 @@ class SchedulingEmbedder
|
||||
|
||||
void SetEmbedderMetadata(EmbedderMetadata metadata) override;
|
||||
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
// PerformanceScenarioObserver:
|
||||
void OnLoadingScenarioChanged(
|
||||
blink::performance_scenarios::ScenarioScope scope,
|
||||
blink::performance_scenarios::LoadingScenario old_scenario,
|
||||
blink::performance_scenarios::LoadingScenario new_scenario) override;
|
||||
performance_scenarios::ScenarioScope scope,
|
||||
performance_scenarios::LoadingScenario old_scenario,
|
||||
performance_scenarios::LoadingScenario new_scenario) override;
|
||||
void OnInputScenarioChanged(
|
||||
blink::performance_scenarios::ScenarioScope scope,
|
||||
blink::performance_scenarios::InputScenario old_scenario,
|
||||
blink::performance_scenarios::InputScenario new_scenario) override;
|
||||
#endif
|
||||
performance_scenarios::ScenarioScope scope,
|
||||
performance_scenarios::InputScenario old_scenario,
|
||||
performance_scenarios::InputScenario new_scenario) override;
|
||||
|
||||
private:
|
||||
// A job consists of multiple passages, and each passage must have its
|
||||
@ -174,12 +164,10 @@ class SchedulingEmbedder
|
||||
// Whether to block embedding work submission on performance scenario.
|
||||
bool use_performance_scenario_;
|
||||
|
||||
#if BUILDFLAG(USE_BLINK)
|
||||
base::ScopedObservation<
|
||||
blink::performance_scenarios::PerformanceScenarioObserverList,
|
||||
performance_scenarios::PerformanceScenarioObserverList,
|
||||
SchedulingEmbedder>
|
||||
performance_scenario_observation_{this};
|
||||
#endif
|
||||
|
||||
base::WeakPtrFactory<SchedulingEmbedder> weak_ptr_factory_{this};
|
||||
};
|
||||
|
@ -33,6 +33,9 @@ include_rules = [
|
||||
# components/performance_manager sits between chrome/ and content/, except for
|
||||
# the mojo interfaces it exposes to content/ and third_party/blink/.
|
||||
"+components/performance_manager/public/mojom",
|
||||
# components/performance_manager/scenario_api is a subcomponent that can
|
||||
# query performance_manager scenarios from content/ and third_party/blink/.
|
||||
"+components/performance_manager/scenario_api",
|
||||
"+components/services/filesystem",
|
||||
"+components/services/font/public",
|
||||
"+components/services/font_data/public",
|
||||
|
@ -118,6 +118,7 @@ source_set("browser") {
|
||||
"//components/os_crypt/sync",
|
||||
"//components/payments/content/icon",
|
||||
"//components/payments/mojom",
|
||||
"//components/performance_manager/scenario_api",
|
||||
"//components/power_monitor",
|
||||
"//components/services/filesystem:lib",
|
||||
"//components/services/quarantine:quarantine",
|
||||
|
@ -12,6 +12,7 @@
|
||||
#include "base/no_destructor.h"
|
||||
#include "base/strings/strcat.h"
|
||||
#include "base/system/sys_info.h"
|
||||
#include "components/performance_manager/scenario_api/performance_scenarios.h"
|
||||
#include "content/browser/renderer_host/render_process_host_impl.h"
|
||||
#include "content/browser/site_instance_impl.h"
|
||||
#include "content/common/features.h"
|
||||
@ -20,13 +21,12 @@
|
||||
#include "content/public/browser/render_process_host.h"
|
||||
#include "content/public/common/content_client.h"
|
||||
#include "content/public/common/content_features.h"
|
||||
#include "third_party/blink/public/common/performance/performance_scenarios.h"
|
||||
|
||||
namespace content {
|
||||
|
||||
using blink::performance_scenarios::LoadingScenario;
|
||||
using blink::performance_scenarios::PerformanceScenarioObserverList;
|
||||
using blink::performance_scenarios::ScenarioScope;
|
||||
using performance_scenarios::LoadingScenario;
|
||||
using performance_scenarios::PerformanceScenarioObserverList;
|
||||
using performance_scenarios::ScenarioScope;
|
||||
using SpareProcessMaybeTakeAction =
|
||||
content::RenderProcessHostImpl::SpareProcessMaybeTakeAction;
|
||||
|
||||
@ -286,7 +286,7 @@ SpareRenderProcessHostManagerImpl::SpareRenderProcessHostManagerImpl()
|
||||
performance_scenario_observer_list->AddObserver(this);
|
||||
|
||||
is_browser_idle_ =
|
||||
blink::performance_scenarios::GetLoadingScenario(ScenarioScope::kGlobal)
|
||||
performance_scenarios::GetLoadingScenario(ScenarioScope::kGlobal)
|
||||
->load(std::memory_order_relaxed) ==
|
||||
LoadingScenario::kNoPageLoading;
|
||||
}
|
||||
|
@ -13,11 +13,11 @@
|
||||
#include "base/time/time.h"
|
||||
#include "base/timer/elapsed_timer.h"
|
||||
#include "base/timer/timer.h"
|
||||
#include "components/performance_manager/scenario_api/performance_scenario_observer.h"
|
||||
#include "content/common/content_export.h"
|
||||
#include "content/public/browser/process_allocation_context.h"
|
||||
#include "content/public/browser/render_process_host_observer.h"
|
||||
#include "content/public/browser/spare_render_process_host_manager.h"
|
||||
#include "third_party/blink/public/common/performance/performance_scenario_observer.h"
|
||||
|
||||
namespace content {
|
||||
|
||||
@ -64,7 +64,7 @@ enum class NoSpareRendererReason {
|
||||
class CONTENT_EXPORT SpareRenderProcessHostManagerImpl
|
||||
: public SpareRenderProcessHostManager,
|
||||
public RenderProcessHostObserver,
|
||||
public blink::performance_scenarios::PerformanceScenarioObserver {
|
||||
public performance_scenarios::PerformanceScenarioObserver {
|
||||
public:
|
||||
SpareRenderProcessHostManagerImpl();
|
||||
~SpareRenderProcessHostManagerImpl() override;
|
||||
@ -151,11 +151,11 @@ class CONTENT_EXPORT SpareRenderProcessHostManagerImpl
|
||||
const ChildProcessTerminationInfo& info) override;
|
||||
void RenderProcessHostDestroyed(RenderProcessHost* host) override;
|
||||
|
||||
// blink::performance_scenarios::PerformanceScenarioObserver:
|
||||
// performance_scenarios::PerformanceScenarioObserver:
|
||||
void OnLoadingScenarioChanged(
|
||||
blink::performance_scenarios::ScenarioScope scope,
|
||||
blink::performance_scenarios::LoadingScenario old_scenario,
|
||||
blink::performance_scenarios::LoadingScenario new_scenario) override;
|
||||
performance_scenarios::ScenarioScope scope,
|
||||
performance_scenarios::LoadingScenario old_scenario,
|
||||
performance_scenarios::LoadingScenario new_scenario) override;
|
||||
|
||||
void SetIsBrowserIdle(bool is_browser_idle);
|
||||
|
||||
|
@ -75,6 +75,7 @@ target(link_target_type, "child") {
|
||||
"//components/discardable_memory/public/mojom",
|
||||
"//components/metrics",
|
||||
"//components/performance_manager/public/mojom",
|
||||
"//components/performance_manager/scenario_api",
|
||||
"//components/permissions:permissions_common",
|
||||
"//components/tracing:startup_tracing",
|
||||
"//components/variations",
|
||||
|
@ -13,9 +13,9 @@
|
||||
#include "base/memory/weak_ptr.h"
|
||||
#include "base/sequence_checker.h"
|
||||
#include "components/performance_manager/public/mojom/coordination_unit.mojom.h"
|
||||
#include "components/performance_manager/scenario_api/performance_scenarios.h"
|
||||
#include "mojo/public/cpp/bindings/pending_receiver.h"
|
||||
#include "mojo/public/cpp/bindings/remote.h"
|
||||
#include "third_party/blink/public/common/performance/performance_scenarios.h"
|
||||
#include "third_party/perfetto/include/perfetto/tracing/track.h"
|
||||
|
||||
namespace content {
|
||||
@ -40,7 +40,7 @@ void ChildPerformanceCoordinator::OnInitializeChildProcessCoordination(
|
||||
base::ReadOnlySharedMemoryRegion global_region,
|
||||
base::ReadOnlySharedMemoryRegion process_region) {
|
||||
DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
|
||||
using blink::performance_scenarios::ScenarioScope;
|
||||
using performance_scenarios::ScenarioScope;
|
||||
if (global_region.IsValid()) {
|
||||
global_scenario_memory_.emplace(ScenarioScope::kGlobal,
|
||||
std::move(global_region));
|
||||
|
@ -11,10 +11,10 @@
|
||||
#include "base/memory/weak_ptr.h"
|
||||
#include "base/sequence_checker.h"
|
||||
#include "components/performance_manager/public/mojom/coordination_unit.mojom.h"
|
||||
#include "components/performance_manager/scenario_api/performance_scenarios.h"
|
||||
#include "content/common/content_export.h"
|
||||
#include "mojo/public/cpp/bindings/pending_receiver.h"
|
||||
#include "mojo/public/cpp/bindings/remote.h"
|
||||
#include "third_party/blink/public/common/performance/performance_scenarios.h"
|
||||
|
||||
namespace content {
|
||||
|
||||
@ -50,10 +50,10 @@ class CONTENT_EXPORT ChildPerformanceCoordinator {
|
||||
|
||||
// Scopers to manage the lifetime of shared memory regions for performance
|
||||
// scenarios. These regions are read by functions in
|
||||
// //third_party/blink/public/common/performance/performance_scenarios.h.
|
||||
std::optional<blink::performance_scenarios::ScopedReadOnlyScenarioMemory>
|
||||
// //components/performance_manager/scenario_api/performance_scenarios.h.
|
||||
std::optional<performance_scenarios::ScopedReadOnlyScenarioMemory>
|
||||
process_scenario_memory_ GUARDED_BY_CONTEXT(sequence_checker_);
|
||||
std::optional<blink::performance_scenarios::ScopedReadOnlyScenarioMemory>
|
||||
std::optional<performance_scenarios::ScopedReadOnlyScenarioMemory>
|
||||
global_scenario_memory_ GUARDED_BY_CONTEXT(sequence_checker_);
|
||||
|
||||
base::WeakPtrFactory<ChildPerformanceCoordinator> weak_factory_{this};
|
||||
|
@ -14,19 +14,19 @@
|
||||
#include "base/task/sequenced_task_runner.h"
|
||||
#include "base/test/task_environment.h"
|
||||
#include "components/performance_manager/public/mojom/coordination_unit.mojom.h"
|
||||
#include "components/performance_manager/scenario_api/performance_scenarios.h"
|
||||
#include "mojo/public/cpp/bindings/pending_receiver.h"
|
||||
#include "mojo/public/cpp/bindings/receiver.h"
|
||||
#include "testing/gmock/include/gmock/gmock.h"
|
||||
#include "testing/gtest/include/gtest/gtest.h"
|
||||
#include "third_party/blink/public/common/performance/performance_scenarios.h"
|
||||
|
||||
namespace content {
|
||||
namespace {
|
||||
|
||||
using blink::performance_scenarios::ScenarioScope;
|
||||
using blink::performance_scenarios::ScenarioState;
|
||||
using blink::performance_scenarios::ScopedReadOnlyScenarioMemory;
|
||||
using performance_manager::mojom::ChildProcessCoordinationUnit;
|
||||
using performance_scenarios::ScenarioScope;
|
||||
using performance_scenarios::ScenarioState;
|
||||
using performance_scenarios::ScopedReadOnlyScenarioMemory;
|
||||
using ::testing::_;
|
||||
using ::testing::Invoke;
|
||||
|
||||
|
@ -3085,6 +3085,7 @@ test("content_unittests") {
|
||||
"//components/offline_pages/buildflags",
|
||||
"//components/payments/mojom",
|
||||
"//components/performance_manager/public/mojom",
|
||||
"//components/performance_manager/scenario_api",
|
||||
"//components/permissions:permissions_common",
|
||||
"//components/permissions:test_support",
|
||||
"//components/services/quarantine/public/mojom",
|
||||
|
3
third_party/blink/public/common/BUILD.gn
vendored
3
third_party/blink/public/common/BUILD.gn
vendored
@ -268,8 +268,6 @@ source_set("headers") {
|
||||
"peerconnection/webrtc_ip_handling_policy.h",
|
||||
"peerconnection/webrtc_ip_handling_url_entry.h",
|
||||
"performance/largest_contentful_paint_type.h",
|
||||
"performance/performance_scenario_observer.h",
|
||||
"performance/performance_scenarios.h",
|
||||
"performance/performance_timeline_constants.h",
|
||||
"permissions/permission_utils.h",
|
||||
"permissions_policy/document_policy.h",
|
||||
@ -355,7 +353,6 @@ source_set("headers") {
|
||||
"//base",
|
||||
"//cc",
|
||||
"//components/content_settings/core/common",
|
||||
"//components/performance_manager/scenario_api",
|
||||
"//components/shared_highlighting/core/common",
|
||||
"//components/viz/common",
|
||||
"//gpu/command_buffer/common",
|
||||
|
1
third_party/blink/public/common/DEPS
vendored
1
third_party/blink/public/common/DEPS
vendored
@ -10,7 +10,6 @@ include_rules = [
|
||||
"+build",
|
||||
"+cc/paint/element_id.h",
|
||||
"+cc/trees/browser_controls_params.h",
|
||||
"+components/performance_manager/scenario_api",
|
||||
"+components/viz/common/surfaces/local_surface_id.h",
|
||||
"+components/viz/common/view_transition_element_resource_id.h",
|
||||
"+gpu/command_buffer/client/client_shared_image.h",
|
||||
|
@ -1,29 +0,0 @@
|
||||
// Copyright 2024 The Chromium Authors
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef THIRD_PARTY_BLINK_PUBLIC_COMMON_PERFORMANCE_PERFORMANCE_SCENARIO_OBSERVER_H_
|
||||
#define THIRD_PARTY_BLINK_PUBLIC_COMMON_PERFORMANCE_PERFORMANCE_SCENARIO_OBSERVER_H_
|
||||
|
||||
// Forwarding header that imports types from ::performance_scenarios into
|
||||
// ::blink::performance_scenarios.
|
||||
//
|
||||
// TODO(crbug.com/365586676): Convert all callers to use
|
||||
// components/performance_manager/scenario_api and delete this.
|
||||
|
||||
#include "components/performance_manager/scenario_api/performance_scenario_observer.h" // IWYU pragma: export
|
||||
|
||||
// PerformanceScenarioObserver uses types from this header in its signature so
|
||||
// they must be forwarded too.
|
||||
#include "third_party/blink/public/common/performance/performance_scenarios.h" // IWYU pragma: export
|
||||
|
||||
namespace blink::performance_scenarios {
|
||||
|
||||
using PerformanceScenarioObserver =
|
||||
::performance_scenarios::PerformanceScenarioObserver;
|
||||
using PerformanceScenarioObserverList =
|
||||
::performance_scenarios::PerformanceScenarioObserverList;
|
||||
|
||||
} // namespace blink::performance_scenarios
|
||||
|
||||
#endif // THIRD_PARTY_BLINK_PUBLIC_COMMON_PERFORMANCE_PERFORMANCE_SCENARIO_OBSERVER_H_
|
@ -1,44 +0,0 @@
|
||||
// Copyright 2024 The Chromium Authors
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
#ifndef THIRD_PARTY_BLINK_PUBLIC_COMMON_PERFORMANCE_PERFORMANCE_SCENARIOS_H_
|
||||
#define THIRD_PARTY_BLINK_PUBLIC_COMMON_PERFORMANCE_PERFORMANCE_SCENARIOS_H_
|
||||
|
||||
// Forwarding header that imports types from ::performance_scenarios into
|
||||
// ::blink::performance_scenarios.
|
||||
//
|
||||
// TODO(crbug.com/365586676): Convert all callers to use
|
||||
// components/performance_manager/scenario_api and delete this.
|
||||
|
||||
#include "base/compiler_specific.h"
|
||||
#include "components/performance_manager/scenario_api/performance_scenarios.h" // IWYU pragma: export
|
||||
|
||||
namespace blink::performance_scenarios {
|
||||
|
||||
using InputScenario = ::performance_scenarios::InputScenario;
|
||||
using LoadingScenario = ::performance_scenarios::LoadingScenario;
|
||||
using RefCountedScenarioMapping =
|
||||
::performance_scenarios::RefCountedScenarioMapping;
|
||||
using ScenarioScope = ::performance_scenarios::ScenarioScope;
|
||||
using ScenarioState = ::performance_scenarios::ScenarioState;
|
||||
using ScopedReadOnlyScenarioMemory =
|
||||
::performance_scenarios::ScopedReadOnlyScenarioMemory;
|
||||
template <typename T>
|
||||
using SharedAtomicRef = ::performance_scenarios::SharedAtomicRef<T>;
|
||||
|
||||
// If not inlined these function shims will lead to duplicate symbol errors.
|
||||
|
||||
ALWAYS_INLINE SharedAtomicRef<InputScenario> GetInputScenario(
|
||||
ScenarioScope scope) {
|
||||
return ::performance_scenarios::GetInputScenario(scope);
|
||||
}
|
||||
|
||||
ALWAYS_INLINE SharedAtomicRef<LoadingScenario> GetLoadingScenario(
|
||||
ScenarioScope scope) {
|
||||
return ::performance_scenarios::GetLoadingScenario(scope);
|
||||
}
|
||||
|
||||
} // namespace blink::performance_scenarios
|
||||
|
||||
#endif // THIRD_PARTY_BLINK_PUBLIC_COMMON_PERFORMANCE_PERFORMANCE_SCENARIOS_H_
|
@ -419,17 +419,6 @@ _CONFIG = [
|
||||
'network::DataElementBytes',
|
||||
],
|
||||
},
|
||||
{
|
||||
# Forwarding header importing ::performance_scenarios symbols into
|
||||
# blink::performance_scenarios.
|
||||
'paths': [
|
||||
'third_party/blink/public/common/performance/performance_scenarios.h',
|
||||
'third_party/blink/public/common/performance/performance_scenario_observer.h',
|
||||
],
|
||||
'allowed': [
|
||||
'performance_scenarios::.+',
|
||||
],
|
||||
},
|
||||
{
|
||||
'paths': [
|
||||
'third_party/blink/common/shared_storage/module_script_downloader.cc',
|
||||
|
Reference in New Issue
Block a user