v8/build_overrides/build.gni
Sami Kyostila 9dbab9bbdb [tracing] Migrate tracing to Perfetto track events
This patch replaces V8's tracing implementation (i.e., the TRACE_EVENT
macros) with the track event base implementation from Perfetto. The
advantages of doing this are:

1) This allows us to remove most tracing-related backend code from V8.

2) V8 can start writing strongly typed trace event arguments, which
   are more compact, easier to process and more extensible than legacy
   JSON-based trace arguments.

For the time being, we still support the old trace macros when V8 is
embedded into Chrome and other embedders.

Design doc: https://docs.google.com/document/d/1f7tt4cb-JcA5bQFR1oXk60ncJPpkL02_Hi_Bc6MfTQk/edit#heading=h.398p6b4eaen2

Bug: chromium:1006766
Change-Id: Ie71474fbe065821772b13d851487ebbca680c4ae
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1947688
Commit-Queue: Sami Kyöstilä <skyostil@chromium.org>
Auto-Submit: Sami Kyöstilä <skyostil@chromium.org>
Reviewed-by: Peter Marshall <petermarshall@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#67217}
2020-04-17 21:31:24 +00:00

55 lines
2.1 KiB
Plaintext

# Copyright 2016 The V8 project authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# Variable that can be used to support multiple build scenarios, like having
# Chromium specific targets in a client project's GN file etc.
build_with_chromium = false
# Used by perfetto to distinguish from its own standalone build and the
# chromium build.
perfetto_build_with_embedder = true
# When embedding perfetto, its build files need to know in which BUILD.gn file
# the embedder (v8) declared the protobuf targets. In the v8 case they are
# declared in the root v8/BUILD.gn.
perfetto_protobuf_target_prefix = "//"
perfetto_protobuf_gni = "//gni/proto_library.gni"
# We use Perfetto's Trace Processor to convert traces to the legacy JSON
# format.
enable_perfetto_trace_processor = true
# Uncomment these to specify a different NDK location and version in
# non-Chromium builds.
# default_android_ndk_root = "//third_party/android_ndk"
# default_android_ndk_version = "r10e"
# Some non-Chromium builds don't support building java targets.
enable_java_templates = false
# Some non-Chromium builds don't use Chromium's third_party/binutils.
linux_use_bundled_binutils_override = true
# Allows different projects to specify their own suppressions files.
asan_suppressions_file = "//build/sanitizers/asan_suppressions.cc"
lsan_suppressions_file = "//build/sanitizers/lsan_suppressions.cc"
tsan_suppressions_file = "//build/sanitizers/tsan_suppressions.cc"
# Skip assertions about 4GiB file size limit.
ignore_elf32_limitations = true
if (host_os == "mac") {
_result = exec_script("//build/mac/should_use_hermetic_xcode.py",
[ target_os ],
"value")
assert(_result != 2,
"Do not allow building targets with the default" +
"hermetic toolchain if the minimum OS version is not met.")
assert(_result != 3,
"iOS does not support building with a hermetic toolchain. " +
"Please install Xcode.")
use_system_xcode = _result == 0
}