Skip to content

Commit

Permalink
tools: update V8 gypfiles for 13.0
Browse files Browse the repository at this point in the history
  • Loading branch information
targos authored and nodejs-github-bot committed Sep 5, 2024
1 parent 8efa538 commit 8f7f59c
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 83 deletions.
12 changes: 0 additions & 12 deletions tools/v8_gypfiles/features.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -216,15 +216,6 @@
# Enable lazy source positions by default.
'v8_enable_lazy_source_positions%': 1,

# Enable third party HEAP library
'v8_enable_third_party_heap%': 0,

# Libaries used by third party heap
'v8_third_party_heap_libs%': [],

# Source code used by third party heap
'v8_third_party_heap_files%': [],

# Disable write barriers when GCs are non-incremental and
# heap has single generation.
'v8_disable_write_barriers%': 0,
Expand Down Expand Up @@ -434,9 +425,6 @@
['v8_disable_write_barriers==1', {
'defines': ['V8_DISABLE_WRITE_BARRIERS',],
}],
['v8_enable_third_party_heap==1', {
'defines': ['V8_ENABLE_THIRD_PARTY_HEAP',],
}],
['v8_enable_atomic_object_field_writes==1', {
'defines': ['V8_ATOMIC_OBJECT_FIELD_WRITES',],
}],
Expand Down
57 changes: 17 additions & 40 deletions tools/v8_gypfiles/toolchain.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@
# [GYP] this needs to be outside of the top level 'variables'
'conditions': [
['host_arch=="ia32" or host_arch=="x64" or \
host_arch=="ppc" or host_arch=="ppc64" or \
host_arch=="ppc64" or \
host_arch=="s390x" or \
clang==1', {
'variables': {
Expand All @@ -113,7 +113,7 @@
},
}],
['target_arch=="ia32" or target_arch=="x64" or \
target_arch=="ppc" or target_arch=="ppc64" or \
target_arch=="ppc64" or \
target_arch=="s390x" or clang==1', {
'variables': {
'target_cxx_is_biarch%': 1,
Expand Down Expand Up @@ -328,43 +328,24 @@
}],
],
}], # s390x
['v8_target_arch=="ppc" or v8_target_arch=="ppc64"', {
['v8_target_arch=="ppc64"', {
'defines': [
'V8_TARGET_ARCH_PPC64',
],
'cflags': [
'-ffp-contract=off',
],
'conditions': [
['v8_target_arch=="ppc"', {
'defines': [
'V8_TARGET_ARCH_PPC',
],
}],
['v8_target_arch=="ppc64"', {
'defines': [
'V8_TARGET_ARCH_PPC64',
],
'cflags': [
'-ffp-contract=off',
],
}],
['v8_host_byteorder=="little"', {
'defines': [
'V8_TARGET_ARCH_PPC_LE',
],
['OS=="aix" or OS=="os400"', {
# Work around AIX ceil, trunc and round oddities.
'cflags': [ '-mcpu=power5+ -mfprnd' ],
}],
['v8_host_byteorder=="big"', {
'defines': [
'V8_TARGET_ARCH_PPC_BE',
],
'conditions': [
['OS=="aix" or OS=="os400"', {
# Work around AIX ceil, trunc and round oddities.
'cflags': [ '-mcpu=power5+ -mfprnd' ],
}],
['OS=="aix" or OS=="os400"', {
# Work around AIX assembler popcntb bug.
'cflags': [ '-mno-popcntb' ],
}],
],
['OS=="aix" or OS=="os400"', {
# Work around AIX assembler popcntb bug.
'cflags': [ '-mno-popcntb' ],
}],
],
}], # ppc
}], # ppc64
['v8_target_arch=="ia32"', {
'defines': [
'V8_TARGET_ARCH_IA32',
Expand Down Expand Up @@ -595,8 +576,7 @@
}],
['(OS=="linux" or OS=="freebsd" or OS=="openbsd" or OS=="solaris" \
or OS=="netbsd" or OS=="mac" or OS=="android" or OS=="qnx") and \
(v8_target_arch=="arm" or v8_target_arch=="ia32" or \
v8_target_arch=="ppc")', {
(v8_target_arch=="arm" or v8_target_arch=="ia32")', {
'target_conditions': [
['_toolset=="host"', {
'conditions': [
Expand Down Expand Up @@ -679,9 +659,6 @@
'__STDC_FORMAT_MACROS',
'_ALL_SOURCE=1'],
'conditions': [
[ 'v8_target_arch=="ppc"', {
'ldflags': [ '-Wl,-bmaxdata:0x60000000/dsa' ],
}],
[ 'v8_target_arch=="ppc64"', {
'cflags': [ '-maix64', '-fdollars-in-identifiers', '-fno-extern-tls-init' ],
'ldflags': [ '-maix64 -Wl,-bbigtoc' ],
Expand Down
32 changes: 1 addition & 31 deletions tools/v8_gypfiles/v8.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -355,11 +355,6 @@
'<(V8_ROOT)/src/builtins/mips64/builtins-mips64.cc',
],
}],
['v8_target_arch=="ppc"', {
'sources': [
'<(V8_ROOT)/src/builtins/ppc/builtins-ppc.cc',
],
}],
['v8_target_arch=="ppc64"', {
'sources': [
'<(V8_ROOT)/src/builtins/ppc/builtins-ppc.cc',
Expand Down Expand Up @@ -761,11 +756,6 @@
}],
],
}],
['v8_target_arch=="ppc"', {
'sources': [
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_i18n_support.*?v8_current_cpu == \\"ppc\\".*?sources \\+= ")',
],
}],
['v8_target_arch=="ppc64"', {
'sources': [
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_i18n_support.*?v8_current_cpu == \\"ppc64\\".*?sources \\+= ")',
Expand Down Expand Up @@ -849,11 +839,6 @@
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_compiler_sources =.*?v8_current_cpu == \\"mips64\\".*?v8_compiler_sources \\+= ")',
],
}],
['v8_target_arch=="ppc"', {
'sources': [
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_compiler_sources =.*?v8_current_cpu == \\"ppc\\".*?v8_compiler_sources \\+= ")',
],
}],
['v8_target_arch=="ppc64"', {
'sources': [
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_compiler_sources =.*?v8_current_cpu == \\"ppc64\\".*?v8_compiler_sources \\+= ")',
Expand Down Expand Up @@ -1066,13 +1051,6 @@
'<(V8_ROOT)/src/wasm/fuzzing/random-module-generation.cc',
],
}],
['v8_enable_third_party_heap==1', {
# TODO(targos): add values from v8_third_party_heap_files to sources
}, {
'sources': [
'<(V8_ROOT)/src/heap/third-party/heap-api-stub.cc',
],
}],
['v8_enable_heap_snapshot_verify==1', {
'sources': [
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_heap_snapshot_verify.*?sources \\+= ")',
Expand Down Expand Up @@ -1154,11 +1132,6 @@
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_wasm_gdb_remote_debugging.*?v8_current_cpu == \\"mips64\\".*?sources \\+= ")',
],
}],
['v8_target_arch=="ppc"', {
'sources': [
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_wasm_gdb_remote_debugging.*?v8_current_cpu == \\"ppc\\".*?sources \\+= ")',
],
}],
['v8_target_arch=="ppc64"', {
'sources': [
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_wasm_gdb_remote_debugging.*?v8_current_cpu == \\"ppc64\\".*?sources \\+= ")',
Expand Down Expand Up @@ -1245,12 +1218,9 @@
['v8_postmortem_support', {
'dependencies': ['postmortem-metadata#target'],
}],
['v8_enable_third_party_heap', {
# TODO(targos): add values from v8_third_party_heap_libs to link_settings.libraries
}],
# Platforms that don't have Compare-And-Swap (CAS) support need to link atomic library
# to implement atomic memory access
['v8_current_cpu in ["mips64", "mips64el", "ppc", "arm", "riscv64", "loong64"]', {
['v8_current_cpu in ["mips64", "mips64el", "arm", "riscv64", "loong64"]', {
'link_settings': {
'libraries': ['-latomic', ],
},
Expand Down

0 comments on commit 8f7f59c

Please sign in to comment.