Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: add flag to enable pointer compression #30463

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions common.gypi
Original file line number Diff line number Diff line change
@@ -73,9 +73,6 @@
# TODO(refack): make v8-perfetto happen
'v8_use_perfetto': 0,

'v8_enable_pointer_compression': 0,
'v8_enable_31bit_smis_on_64bit_arch': 0,

##### end V8 defaults #####

'conditions': [
7 changes: 7 additions & 0 deletions configure.py
Original file line number Diff line number Diff line change
@@ -346,6 +346,11 @@
dest='trace_maps',
help='Enable the --trace-maps flag in V8 (use at your own risk)')

parser.add_option('--experimental-enable-pointer-compression',
action='store_true',
dest='enable_pointer_compression',
help='[Experimental] Enable V8 pointer compression (limits max heap to 4GB and breaks ABI compatibility)')

parser.add_option('--v8-options',
action='store',
dest='v8_options',
@@ -1192,6 +1197,8 @@ def configure_v8(o):
o['variables']['v8_random_seed'] = 0 # Use a random seed for hash tables.
o['variables']['v8_promise_internal_field_count'] = 1 # Add internal field to promises for async hooks.
o['variables']['v8_use_siphash'] = 0 if options.without_siphash else 1
o['variables']['v8_enable_pointer_compression'] = 1 if options.enable_pointer_compression else 0
o['variables']['v8_enable_31bit_smis_on_64bit_arch'] = 1 if options.enable_pointer_compression else 0
o['variables']['v8_trace_maps'] = 1 if options.trace_maps else 0
o['variables']['node_use_v8_platform'] = b(not options.without_v8_platform)
o['variables']['node_use_bundled_v8'] = b(not options.without_bundled_v8)
2 changes: 2 additions & 0 deletions node.gyp
Original file line number Diff line number Diff line change
@@ -2,6 +2,8 @@
'variables': {
'v8_use_siphash%': 0,
'v8_trace_maps%': 0,
'v8_enable_pointer_compression%': 0,
'v8_enable_31bit_smis_on_64bit_arch%': 0,
mcollina marked this conversation as resolved.
Show resolved Hide resolved
'node_use_dtrace%': 'false',
'node_use_etw%': 'false',
'node_no_browser_globals%': 'false',