mirror of
https://github.com/Alex313031/thorium.git
synced 2025-01-10 03:47:44 -03:00
stop doing arch dependent V8 build.gns
This commit is contained in:
parent
40c50e0dad
commit
325d802c3f
6 changed files with 52 additions and 40700 deletions
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
@ -1149,6 +1149,9 @@ config("features") {
|
|||
if (v8_fuzzilli) {
|
||||
defines += [ "V8_FUZZILLI" ]
|
||||
}
|
||||
if (v8_enable_fuzztest) {
|
||||
defines += [ "V8_ENABLE_FUZZTEST" ]
|
||||
}
|
||||
if (v8_enable_short_builtin_calls) {
|
||||
defines += [ "V8_SHORT_BUILTIN_CALLS" ]
|
||||
}
|
||||
|
@ -1406,7 +1409,7 @@ config("toolchain") {
|
|||
defines += [ "V8_TARGET_ARCH_IA32" ]
|
||||
if (is_win) {
|
||||
# Ensure no surprising artifacts from 80bit double math with x86.
|
||||
cflags += [ "/O2", "/arch:SSE2" ]
|
||||
cflags += [ "/O2", "-Xclang", "-O3", "/arch:SSE2" ]
|
||||
}
|
||||
}
|
||||
if (v8_current_cpu == "x64") {
|
||||
|
@ -1415,14 +1418,14 @@ config("toolchain") {
|
|||
# Increase the initial stack size. The default is 1MB, this is 2MB. This
|
||||
# applies only to executables and shared libraries produced by V8 since
|
||||
# ldflags are not pushed to dependants.
|
||||
cflags += [ "/O2", "/arch:AVX" ]
|
||||
cflags += [ "/O2", "-Xclang", "-O3" ]
|
||||
ldflags += [ "/STACK:2097152" ]
|
||||
}
|
||||
if (is_linux || is_chromeos) {
|
||||
# Full optimization for V8.
|
||||
cflags += [ "-O3", "-msse3", "-mssse3", "-msse4.1", "-msse4.2", "-mavx", "-maes" ]
|
||||
ldflags += [ "-Wl,-O3", "-msse3", "-mssse3", "-msse4.1", "-msse4.2", "-mavx", "-maes" ]
|
||||
}
|
||||
}
|
||||
if (is_linux || is_chromeos) {
|
||||
# Full optimization for V8.
|
||||
cflags += [ "-O3" ]
|
||||
ldflags += [ "-Wl,-O3" ]
|
||||
}
|
||||
if (is_android && v8_android_log_stdout) {
|
||||
defines += [ "V8_ANDROID_LOG_STDOUT" ]
|
||||
|
@ -1488,7 +1491,6 @@ config("toolchain") {
|
|||
|
||||
if (is_clang) {
|
||||
cflags += [
|
||||
"-Wmissing-field-initializers",
|
||||
"-Wunreachable-code",
|
||||
|
||||
# TODO(v8:12245): Fix shadowing instances and remove.
|
||||
|
@ -1502,11 +1504,6 @@ config("toolchain") {
|
|||
# warning.
|
||||
cflags += [ "-Wctad-maybe-unsupported" ]
|
||||
}
|
||||
|
||||
if (v8_current_cpu == "x64" || v8_current_cpu == "arm64" ||
|
||||
v8_current_cpu == "mips64el" || v8_current_cpu == "riscv64") {
|
||||
cflags += [ "-Wshorten-64-to-32" ]
|
||||
}
|
||||
}
|
||||
|
||||
if (is_clang || !is_win) {
|
||||
|
@ -1702,6 +1699,10 @@ config("toolchain") {
|
|||
# of `this` in capture-by-value lambdas and preventing a build roll which
|
||||
# enables C++20 (see https://crbug.com/1374227).
|
||||
"-Wno-deprecated",
|
||||
|
||||
# Fix build with older versions of GCC
|
||||
# Ported from v8 bazel: https://crrev.com/c/3368869
|
||||
"-Wno-stringop-overflow",
|
||||
]
|
||||
}
|
||||
|
||||
|
@ -1711,6 +1712,17 @@ config("toolchain") {
|
|||
}
|
||||
}
|
||||
|
||||
config("strict_warnings") {
|
||||
cflags = []
|
||||
if (is_clang) {
|
||||
if (v8_current_cpu == "x64" || v8_current_cpu == "arm64" ||
|
||||
v8_current_cpu == "mips64el" || v8_current_cpu == "riscv64") {
|
||||
cflags += [ "-Wshorten-64-to-32" ]
|
||||
}
|
||||
cflags += [ "-Wmissing-field-initializers" ]
|
||||
}
|
||||
}
|
||||
|
||||
# For code that is hot during mksnapshot. In fast-mksnapshot builds, we
|
||||
# optimize some files even in debug builds to speed up mksnapshot times.
|
||||
config("always_turbofanimize") {
|
||||
|
@ -3294,6 +3306,7 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/compiler/common-operator.h",
|
||||
"src/compiler/compilation-dependencies.h",
|
||||
"src/compiler/compiler-source-position-table.h",
|
||||
"src/compiler/const-tracking-let-helpers.h",
|
||||
"src/compiler/constant-folding-reducer.h",
|
||||
"src/compiler/control-equivalence.h",
|
||||
"src/compiler/control-flow-optimizer.h",
|
||||
|
@ -3391,7 +3404,7 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/compiler/turboshaft/code-elimination-and-simplification-phase.h",
|
||||
"src/compiler/turboshaft/copying-phase.h",
|
||||
"src/compiler/turboshaft/csa-optimize-phase.h",
|
||||
"src/compiler/turboshaft/dataview-reducer.h",
|
||||
"src/compiler/turboshaft/dataview-lowering-reducer.h",
|
||||
"src/compiler/turboshaft/dead-code-elimination-reducer.h",
|
||||
"src/compiler/turboshaft/debug-feature-lowering-phase.h",
|
||||
"src/compiler/turboshaft/debug-feature-lowering-reducer.h",
|
||||
|
@ -3401,7 +3414,7 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/compiler/turboshaft/deopt-data.h",
|
||||
"src/compiler/turboshaft/duplication-optimization-reducer.h",
|
||||
"src/compiler/turboshaft/explicit-truncation-reducer.h",
|
||||
"src/compiler/turboshaft/fast-api-call-reducer.h",
|
||||
"src/compiler/turboshaft/fast-api-call-lowering-reducer.h",
|
||||
"src/compiler/turboshaft/fast-hash.h",
|
||||
"src/compiler/turboshaft/graph-builder.h",
|
||||
"src/compiler/turboshaft/graph-visualizer.h",
|
||||
|
@ -3430,7 +3443,6 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/compiler/turboshaft/pretenuring-propagation-reducer.h",
|
||||
"src/compiler/turboshaft/recreate-schedule-phase.h",
|
||||
"src/compiler/turboshaft/recreate-schedule.h",
|
||||
"src/compiler/turboshaft/reduce-args-helper.h",
|
||||
"src/compiler/turboshaft/reducer-traits.h",
|
||||
"src/compiler/turboshaft/representations.h",
|
||||
"src/compiler/turboshaft/required-optimization-reducer.h",
|
||||
|
@ -3442,7 +3454,7 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/compiler/turboshaft/simplify-tf-loops.h",
|
||||
"src/compiler/turboshaft/snapshot-table-opindex.h",
|
||||
"src/compiler/turboshaft/snapshot-table.h",
|
||||
"src/compiler/turboshaft/stack-check-reducer.h",
|
||||
"src/compiler/turboshaft/stack-check-lowering-reducer.h",
|
||||
"src/compiler/turboshaft/store-store-elimination-phase.h",
|
||||
"src/compiler/turboshaft/store-store-elimination-reducer.h",
|
||||
"src/compiler/turboshaft/structural-optimization-reducer.h",
|
||||
|
@ -3630,6 +3642,7 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/heap/marking.h",
|
||||
"src/heap/memory-allocator.h",
|
||||
"src/heap/memory-balancer.h",
|
||||
"src/heap/memory-chunk-header.h",
|
||||
"src/heap/memory-chunk-inl.h",
|
||||
"src/heap/memory-chunk-layout.h",
|
||||
"src/heap/memory-chunk.h",
|
||||
|
@ -4126,6 +4139,12 @@ v8_header_set("v8_internal_headers") {
|
|||
|
||||
if (v8_use_perfetto) {
|
||||
sources -= [ "//base/trace_event/common/trace_event_common.h" ]
|
||||
sources += [
|
||||
"src/tracing/code-data-source.h",
|
||||
"src/tracing/code-trace-context.h",
|
||||
"src/tracing/perfetto-logger.h",
|
||||
"src/tracing/perfetto-utils.h",
|
||||
]
|
||||
}
|
||||
|
||||
if (v8_enable_sparkplug) {
|
||||
|
@ -4185,7 +4204,7 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/compiler/turboshaft/int64-lowering-reducer.h",
|
||||
"src/compiler/turboshaft/wasm-assembler-helpers.h",
|
||||
"src/compiler/turboshaft/wasm-gc-optimize-phase.h",
|
||||
"src/compiler/turboshaft/wasm-gc-type-reducer.h",
|
||||
"src/compiler/turboshaft/wasm-gc-typed-optimization-reducer.h",
|
||||
"src/compiler/turboshaft/wasm-js-lowering-reducer.h",
|
||||
"src/compiler/turboshaft/wasm-load-elimination-reducer.h",
|
||||
"src/compiler/turboshaft/wasm-lowering-phase.h",
|
||||
|
@ -4220,6 +4239,7 @@ v8_header_set("v8_internal_headers") {
|
|||
"src/wasm/baseline/parallel-move.h",
|
||||
"src/wasm/canonical-types.h",
|
||||
"src/wasm/code-space-access.h",
|
||||
"src/wasm/compilation-environment-inl.h",
|
||||
"src/wasm/compilation-environment.h",
|
||||
"src/wasm/constant-expression-interface.h",
|
||||
"src/wasm/constant-expression.h",
|
||||
|
@ -4749,6 +4769,7 @@ v8_compiler_sources = [
|
|||
"src/compiler/common-operator.cc",
|
||||
"src/compiler/compilation-dependencies.cc",
|
||||
"src/compiler/compiler-source-position-table.cc",
|
||||
"src/compiler/const-tracking-let-helpers.cc",
|
||||
"src/compiler/constant-folding-reducer.cc",
|
||||
"src/compiler/control-equivalence.cc",
|
||||
"src/compiler/control-flow-optimizer.cc",
|
||||
|
@ -4925,7 +4946,7 @@ if (v8_enable_webassembly) {
|
|||
"src/compiler/int64-lowering.cc",
|
||||
"src/compiler/turboshaft/int64-lowering-phase.cc",
|
||||
"src/compiler/turboshaft/wasm-gc-optimize-phase.cc",
|
||||
"src/compiler/turboshaft/wasm-gc-type-reducer.cc",
|
||||
"src/compiler/turboshaft/wasm-gc-typed-optimization-reducer.cc",
|
||||
"src/compiler/turboshaft/wasm-lowering-phase.cc",
|
||||
"src/compiler/turboshaft/wasm-optimize-phase.cc",
|
||||
"src/compiler/turboshaft/wasm-turboshaft-compiler.cc",
|
||||
|
@ -5320,6 +5341,7 @@ v8_source_set("v8_base_without_compiler") {
|
|||
"src/heap/marking.cc",
|
||||
"src/heap/memory-allocator.cc",
|
||||
"src/heap/memory-balancer.cc",
|
||||
"src/heap/memory-chunk-header.cc",
|
||||
"src/heap/memory-chunk-layout.cc",
|
||||
"src/heap/memory-chunk.cc",
|
||||
"src/heap/memory-measurement.cc",
|
||||
|
@ -5641,6 +5663,14 @@ v8_source_set("v8_base_without_compiler") {
|
|||
}
|
||||
}
|
||||
|
||||
if (v8_use_perfetto) {
|
||||
sources += [
|
||||
"src/tracing/code-data-source.cc",
|
||||
"src/tracing/perfetto-logger.cc",
|
||||
"src/tracing/perfetto-utils.cc",
|
||||
]
|
||||
}
|
||||
|
||||
if (v8_enable_webassembly) {
|
||||
sources += [
|
||||
### gcmole(all) ###
|
||||
|
@ -5696,6 +5726,7 @@ v8_source_set("v8_base_without_compiler") {
|
|||
"src/wasm/wasm-serialization.cc",
|
||||
"src/wasm/wasm-subtyping.cc",
|
||||
"src/wasm/well-known-imports.cc",
|
||||
"src/wasm/wrappers.cc",
|
||||
]
|
||||
}
|
||||
|
||||
|
@ -8121,7 +8152,6 @@ if (!build_with_chromium && v8_use_perfetto) {
|
|||
"//third_party/perfetto/src/tracing/core",
|
||||
|
||||
# TODO(skyostil): Support non-POSIX platforms.
|
||||
"//third_party/perfetto/protos/perfetto/config:cpp",
|
||||
"//third_party/perfetto/protos/perfetto/trace/track_event:zero",
|
||||
"//third_party/perfetto/src/tracing:in_process_backend",
|
||||
"//third_party/perfetto/src/tracing:platform_impl",
|
||||
|
@ -8129,6 +8159,8 @@ if (!build_with_chromium && v8_use_perfetto) {
|
|||
|
||||
public_deps = [
|
||||
"//third_party/perfetto/include/perfetto/trace_processor",
|
||||
"//third_party/perfetto/protos/perfetto/config:cpp",
|
||||
"//third_party/perfetto/protos/perfetto/trace/chrome:zero",
|
||||
"//third_party/perfetto/src/trace_processor:export_json",
|
||||
"//third_party/perfetto/src/tracing:client_api",
|
||||
]
|
||||
|
|
Loading…
Reference in a new issue