| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent e2cb5d0 commit 30096ef
3 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -453,6 +453,11 @@ | |||
| 453 | 453 | dest='without_node_snapshot', | |
| 454 | 454 | help='Turn off V8 snapshot integration. Currently experimental.') | |
| 455 | 455 | ||
| 456 | + parser.add_option('--without-node-code-cache', | ||
| 457 | + action='store_true', | ||
| 458 | + dest='without_node_code_cache', | ||
| 459 | + help='Turn off V8 Code cache integration.') | ||
| 460 | + | ||
| 456 | 461 | intl_optgroup.add_option('--download', | |
| 457 | 462 | action='store', | |
| 458 | 463 | dest='download_list', | |
@@ -978,6 +983,12 @@ def configure_node(o): | |||
| 978 | 983 | else: | |
| 979 | 984 | o['variables']['node_use_node_snapshot'] = 'false' | |
| 980 | 985 | ||
| 986 | + if not options.without_node_code_cache: | ||
| 987 | + # TODO(refack): fix this when implementing embedded code-cache when cross-compiling. | ||
| 988 | + o['variables']['node_use_node_code_cache'] = b(not cross_compiling) | ||
| 989 | + else: | ||
| 990 | + o['variables']['node_use_node_code_cache'] = 'false' | ||
| 991 | + | ||
| 981 | 992 | if target_arch == 'arm': | |
| 982 | 993 | configure_arm(o) | |
| 983 | 994 | elif target_arch in ('mips', 'mipsel', 'mips64el'): | |
@@ -1083,9 +1094,7 @@ def configure_node(o): | |||
| 1083 | 1094 | o['variables']['debug_nghttp2'] = 'false' | |
| 1084 | 1095 | ||
| 1085 | 1096 | o['variables']['node_no_browser_globals'] = b(options.no_browser_globals) | |
| 1086 | - # TODO(refack): fix this when implementing embedded code-cache when cross-compiling. | ||
| 1087 | - if o['variables']['want_separate_host_toolset'] == 0: | ||
| 1088 | - o['variables']['node_code_cache'] = 'yes' # For testing | ||
| 1097 | + | ||
| 1089 | 1098 | o['variables']['node_shared'] = b(options.shared) | |
| 1090 | 1099 | node_module_version = getmoduleversion.get_version() | |
| 1091 | 1100 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -436,7 +436,7 @@ | |||
| 436 | 436 | }, | |
| 437 | 437 | }, | |
| 438 | 438 | }], | |
| 439 | - ['want_separate_host_toolset==0', { | ||
| 439 | + ['node_use_node_code_cache=="true"', { | ||
| 440 | 440 | 'dependencies': [ | |
| 441 | 441 | 'mkcodecache', | |
| 442 | 442 | ], | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -33,6 +33,8 @@ const loadedModules = process.moduleLoadList | |||
| 33 | 33 | // are all compiled without cache and we are doing the bookkeeping right. | |
| 34 | 34 | if (!process.features.cached_builtins) { | |
| 35 | 35 | console.log('The binary is not configured with code cache'); | |
| 36 | + assert(!process.config.variables.node_use_node_code_cache); | ||
| 37 | + | ||
| 36 | 38 | if (isMainThread) { | |
| 37 | 39 | assert.deepStrictEqual(compiledWithCache, new Set()); | |
| 38 | 40 | for (const key of loadedModules) { | |
@@ -46,10 +48,7 @@ if (!process.features.cached_builtins) { | |||
| 46 | 48 | assert.notDeepStrictEqual(compiledWithCache, new Set()); | |
| 47 | 49 | } | |
| 48 | 50 | } else { // Native compiled | |
| 49 | - assert.strictEqual( | ||
| 50 | - process.config.variables.node_code_cache, | ||
| 51 | - 'yes' | ||
| 52 | - ); | ||
| 51 | + assert(process.config.variables.node_use_node_code_cache); | ||
| 53 | 52 | ||
| 54 | 53 | if (!isMainThread) { | |
| 55 | 54 | for (const key of [ 'internal/bootstrap/pre_execution' ]) { | |
| Back | FazBrowse Home | New Git URL |
0 commit comments