blob: 1dc6c7d5ac51df9c1f55668b35d1cb0f4da4a5d5 [file] [log] [blame]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001# Copyright 2014 The Chromium Authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
Ben Murdoch014dc512016-03-22 12:00:34 +00005import("//build/config/android/config.gni")
6import("//build/config/arm.gni")
Ben Murdoch13e2dad2016-09-16 13:49:30 +01007import("//build/config/dcheck_always_on.gni")
Rubin Xu7bc1b612021-02-16 09:38:50 +00008import("//build/config/host_byteorder.gni")
Ben Murdoch014dc512016-03-22 12:00:34 +00009import("//build/config/mips.gni")
10import("//build/config/sanitizers/sanitizers.gni")
Rubin Xu7bc1b612021-02-16 09:38:50 +000011import("//build_overrides/build.gni")
Ben Murdoch014dc512016-03-22 12:00:34 +000012
13if (is_android) {
14 import("//build/config/android/rules.gni")
15}
16
Rubin Xu7bc1b612021-02-16 09:38:50 +000017import("gni/snapshot_toolchain.gni")
Ben Murdoch13e2dad2016-09-16 13:49:30 +010018import("gni/v8.gni")
Rubin Xu7bc1b612021-02-16 09:38:50 +000019
20# Specifies if the target build is a simulator build. Comparing target cpu
21# with v8 target cpu to not affect simulator builds for making cross-compile
22# snapshots.
23target_is_simulator = (target_cpu != v8_target_cpu && !v8_multi_arch_build) ||
24 (current_cpu != v8_current_cpu && v8_multi_arch_build)
25
26# For faster Windows builds. See https://crbug.com/v8/8475.
27emit_builtins_as_inline_asm = is_win && is_clang
Ben Murdoch014dc512016-03-22 12:00:34 +000028
29declare_args() {
Ben Murdochf91f0612016-11-29 16:50:11 +000030 # Print to stdout on Android.
31 v8_android_log_stdout = false
32
Rubin Xu7bc1b612021-02-16 09:38:50 +000033 # Dynamically set an additional dependency from v8/custom_deps.
34 v8_custom_deps = ""
35
36 # Turns on all V8 debug features. Enables running V8 in a pseudo debug mode
37 # within a release Chrome.
38 v8_enable_debugging_features = is_debug
39
40 # Sets -DV8_ENABLE_FUTURE.
41 v8_enable_future = false
42
43 # Lite mode disables a number of performance optimizations to reduce memory
44 # at the cost of performance.
45 # Sets --DV8_LITE_MODE.
46 v8_enable_lite_mode = false
47
Ben Murdochbcf72ee2016-08-08 18:44:38 +010048 # Sets -DVERIFY_HEAP.
Ben Murdoch62ed6312017-06-06 11:06:27 +010049 v8_enable_verify_heap = ""
50
51 # Sets -DVERIFY_PREDICTABLE
52 v8_enable_verify_predictable = false
Ben Murdochbcf72ee2016-08-08 18:44:38 +010053
54 # Enable compiler warnings when using V8_DEPRECATED apis.
Rubin Xu7bc1b612021-02-16 09:38:50 +000055 v8_deprecation_warnings = true
Ben Murdochbcf72ee2016-08-08 18:44:38 +010056
57 # Enable compiler warnings when using V8_DEPRECATE_SOON apis.
Rubin Xu7bc1b612021-02-16 09:38:50 +000058 v8_imminent_deprecation_warnings = true
Ben Murdochf91f0612016-11-29 16:50:11 +000059
60 # Embeds the given script into the snapshot.
61 v8_embed_script = ""
Ben Murdochbcf72ee2016-08-08 18:44:38 +010062
Rubin Xu7bc1b612021-02-16 09:38:50 +000063 # Allows the embedder to add a custom suffix to the version string.
64 v8_embedder_string = ""
65
Ben Murdochbcf72ee2016-08-08 18:44:38 +010066 # Sets -dENABLE_DISASSEMBLER.
Ben Murdochf91f0612016-11-29 16:50:11 +000067 v8_enable_disassembler = ""
Ben Murdochbcf72ee2016-08-08 18:44:38 +010068
Rubin Xu7bc1b612021-02-16 09:38:50 +000069 # Sets the number of internal fields on promise objects.
70 v8_promise_internal_field_count = 0
71
Ben Murdochbcf72ee2016-08-08 18:44:38 +010072 # Sets -dENABLE_GDB_JIT_INTERFACE.
Ben Murdochf91f0612016-11-29 16:50:11 +000073 v8_enable_gdbjit = ""
Ben Murdochbcf72ee2016-08-08 18:44:38 +010074
Ben Murdoch62ed6312017-06-06 11:06:27 +010075 # Sets -dENABLE_VTUNE_JIT_INTERFACE.
76 v8_enable_vtunejit = false
77
Rubin Xu7bc1b612021-02-16 09:38:50 +000078 # Sets -dENABLE_VTUNE_TRACEMARK.
79 v8_enable_vtunetracemark = false
80
Ben Murdochbcf72ee2016-08-08 18:44:38 +010081 # Sets -dENABLE_HANDLE_ZAPPING.
82 v8_enable_handle_zapping = is_debug
83
Ben Murdoch13e2dad2016-09-16 13:49:30 +010084 # Enable slow dchecks.
85 v8_enable_slow_dchecks = false
86
Rubin Xu7bc1b612021-02-16 09:38:50 +000087 # Enable fast mksnapshot runs.
88 v8_enable_fast_mksnapshot = false
89
90 # Optimize code for Torque executable, even during a debug build.
91 v8_enable_fast_torque = ""
92
93 # Enable the registration of unwinding info for Windows x64 and ARM64.
94 v8_win64_unwinding_info = true
95
96 # Enable code comments for builtins in the snapshot (impacts performance).
97 v8_enable_snapshot_code_comments = false
98
99 # Enable native counters from the snapshot (impacts performance, sets
100 # -dV8_SNAPSHOT_NATIVE_CODE_COUNTERS).
101 # This option will generate extra code in the snapshot to increment counters,
102 # as per the --native-code-counters flag.
103 v8_enable_snapshot_native_code_counters = ""
104
Ben Murdoch62ed6312017-06-06 11:06:27 +0100105 # Enable code-generation-time checking of types in the CodeStubAssembler.
106 v8_enable_verify_csa = false
107
Rubin Xu7bc1b612021-02-16 09:38:50 +0000108 # Enable pointer compression (sets -dV8_COMPRESS_POINTERS).
109 v8_enable_pointer_compression = ""
110 v8_enable_31bit_smis_on_64bit_arch = false
111
112 # Disable arguments adaptor frame (sets -dV8_NO_ARGUMENTS_ADAPTOR).
113 v8_disable_arguments_adaptor =
114 v8_current_cpu == "x86" || v8_current_cpu == "x64" ||
115 v8_current_cpu == "arm" || v8_current_cpu == "arm64" ||
116 v8_current_cpu == "mipsel" || v8_current_cpu == "mips64el"
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100117
118 # Sets -dOBJECT_PRINT.
Ben Murdoch62ed6312017-06-06 11:06:27 +0100119 v8_enable_object_print = ""
120
Rubin Xu7bc1b612021-02-16 09:38:50 +0000121 # Sets -dV8_TRACE_MAPS.
Ben Murdoch62ed6312017-06-06 11:06:27 +0100122 v8_enable_trace_maps = ""
123
124 # Sets -dV8_ENABLE_CHECKS.
125 v8_enable_v8_checks = ""
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100126
Rubin Xu7bc1b612021-02-16 09:38:50 +0000127 # Sets -dV8_TRACE_IGNITION.
128 v8_enable_trace_ignition = false
129
130 # Sets -dV8_TRACE_FEEDBACK_UPDATES.
131 v8_enable_trace_feedback_updates = false
132
133 # Sets -dV8_ATOMIC_OBJECT_FIELD_WRITES and turns all field write operations
134 # into relaxed atomic operations.
135 v8_enable_atomic_object_field_writes = ""
136
137 # Sets -dV8_ATOMIC_MARKING_STATE
138 v8_enable_atomic_marking_state = ""
139
140 # Controls the default values of v8_enable_atomic_object_field_writes and
141 # v8_enable_concurrent_marking_state. See the default setting code below.
142 v8_enable_concurrent_marking = true
143
144 # Runs mksnapshot with --turbo-profiling. After building in this
145 # configuration, any subsequent run of d8 will output information about usage
146 # of basic blocks in builtins.
147 v8_enable_builtins_profiling = false
148
149 # Runs mksnapshot with --turbo-profiling-verbose. After building in this
150 # configuration, any subsequent run of d8 will output information about usage
151 # of basic blocks in builtins, including the schedule and disassembly of all
152 # used builtins.
153 v8_enable_builtins_profiling_verbose = false
154
155 # Provides the given V8 log file as an input to mksnapshot, where it can be
156 # used for profile-guided optimization of builtins.
157 #
158 # To do profile-guided optimizations of builtins:
159 # 1. Build with v8_enable_builtins_profiling = true
160 # 2. Run your chosen workload with the --turbo-profiling-log-builtins flag.
161 # For Chrome, the invocation might look like this:
162 # chrome --no-sandbox --disable-extensions
163 # --js-flags="--turbo-profiling-log-builtins --logfile=path/to/v8.log"
164 # "http://localhost/test-suite"
165 # 3. Optionally repeat step 2 for additional workloads, and concatenate all of
166 # the resulting log files into a single file.
167 # 4. Build again with v8_builtins_profiling_log_file set to the file created
168 # in steps 2-3.
169 v8_builtins_profiling_log_file = ""
170
171 # Enables various testing features.
172 v8_enable_test_features = ""
173
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100174 # With post mortem support enabled, metadata is embedded into libv8 that
175 # describes various parameters of the VM for use by debuggers. See
176 # tools/gen-postmortem-metadata.py for details.
177 v8_postmortem_support = false
178
Rubin Xu7bc1b612021-02-16 09:38:50 +0000179 # Use Siphash as added protection against hash flooding attacks.
180 v8_use_siphash = false
181
Ben Murdochf3b273f2017-01-17 12:11:28 +0000182 # Switches off inlining in V8.
183 v8_no_inline = false
184
Ben Murdochc8c1d9e2017-03-08 14:04:23 +0000185 # Override OS page size when generating snapshot
186 v8_os_page_size = "0"
187
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100188 # Similar to vfp but on MIPS.
189 v8_can_use_fpu_instructions = true
190
191 # Similar to the ARM hard float ABI but on MIPS.
192 v8_use_mips_abi_hardfloat = true
Emily Bernier958fae72015-03-24 16:35:39 -0400193
Rubin Xu7bc1b612021-02-16 09:38:50 +0000194 # Controls the threshold for on-heap/off-heap Typed Arrays.
195 v8_typed_array_max_size_in_heap = 64
Ben Murdoch62ed6312017-06-06 11:06:27 +0100196
Rubin Xu7bc1b612021-02-16 09:38:50 +0000197 v8_enable_gdbjit = ((v8_current_cpu == "x86" || v8_current_cpu == "x64") &&
198 (is_linux || is_chromeos || is_mac)) ||
199 (v8_current_cpu == "ppc64" && (is_linux || is_chromeos))
Ben Murdoch62ed6312017-06-06 11:06:27 +0100200
Rubin Xu7bc1b612021-02-16 09:38:50 +0000201 # Temporary flag to allow embedders to update their microtasks scopes
202 # while rolling in a new version of V8.
203 v8_check_microtasks_scopes_consistency = ""
204
205 # Enable mitigations for executing untrusted code.
206 # Disabled by default on ia32 due to conflicting requirements with embedded
207 # builtins. Enabled by default on Android since it doesn't support
208 # site-isolation in Chrome and on simulator builds which test code generation
209 # on these platforms.
210 v8_untrusted_code_mitigations =
211 v8_current_cpu != "x86" && (is_android || target_is_simulator)
212
213 # Enable minor mark compact.
214 v8_enable_minor_mc = true
215
216 # Check that each header can be included in isolation (requires also
217 # setting the "check_v8_header_includes" gclient variable to run a
218 # specific hook).
219 v8_check_header_includes = false
220
221 # Enable sharing read-only space across isolates.
222 # Sets -DV8_SHARED_RO_HEAP.
223 v8_enable_shared_ro_heap = ""
224
225 # Enable lazy source positions by default.
226 v8_enable_lazy_source_positions = true
227
228 # Enable third party HEAP library
229 v8_enable_third_party_heap = false
230
231 # Libaries used by third party heap
232 v8_third_party_heap_libs = []
233
234 # Source code used by third party heap
235 v8_third_party_heap_files = []
236
237 # Disable write barriers when GCs are non-incremental and
238 # heap has single generation.
239 v8_disable_write_barriers = false
240
241 # Ensure that write barriers are always used.
242 # Useful for debugging purposes.
243 v8_enable_unconditional_write_barriers = false
244
245 # Redirect allocation in young generation so that there will be
246 # only one single generation.
247 v8_enable_single_generation = ""
248
249 # Use token threaded dispatch for the regular expression interpreter.
250 # Use switch-based dispatch if this is false
251 v8_enable_regexp_interpreter_threaded_dispatch = true
252
253 # Enable additional targets necessary for verification of torque
254 # file generation
255 v8_verify_torque_generation_invariance = false
256
257 # Disable all snapshot compression.
258 v8_enable_snapshot_compression = true
259
260 # Enable control-flow integrity features, such as pointer authentication for
261 # ARM64.
262 v8_control_flow_integrity = false
263
264 # Enable object names in cppgc for debug purposes.
265 cppgc_enable_object_names = false
266
267 # Enable heap reservation of size 4GB. Only possible for 64bit archs.
268 cppgc_enable_caged_heap = v8_current_cpu == "x64" || v8_current_cpu == "arm64"
269
270 # Enable young generation in cppgc.
271 cppgc_enable_young_generation = false
272
273 # Enable V8 zone compression experimental feature.
274 # Sets -DV8_COMPRESS_ZONES.
275 v8_enable_zone_compression = ""
276
277 # Enable V8 heap sandbox experimental feature.
278 # Sets -DV8_HEAP_SANDBOX.
279 v8_enable_heap_sandbox = ""
280
281 # Experimental feature for collecting per-class zone memory stats.
282 # Requires use_rtti = true
283 v8_enable_precise_zone_stats = false
284
285 # Experimental feature for always keeping prototypes in dict/"slow" mode
286 # Sets -DV8_DICT_MODE_PROTOTYPES
287 v8_dict_mode_prototypes = false
Ben Murdochf91f0612016-11-29 16:50:11 +0000288}
289
290# Derived defaults.
Ben Murdoch62ed6312017-06-06 11:06:27 +0100291if (v8_enable_verify_heap == "") {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000292 v8_enable_verify_heap = v8_enable_debugging_features
Ben Murdoch62ed6312017-06-06 11:06:27 +0100293}
294if (v8_enable_object_print == "") {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000295 v8_enable_object_print = v8_enable_debugging_features
Ben Murdochf91f0612016-11-29 16:50:11 +0000296}
297if (v8_enable_disassembler == "") {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000298 v8_enable_disassembler = v8_enable_debugging_features
Ben Murdoch62ed6312017-06-06 11:06:27 +0100299}
300if (v8_enable_trace_maps == "") {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000301 v8_enable_trace_maps = v8_enable_debugging_features
302}
303if (v8_enable_test_features == "") {
304 v8_enable_test_features = v8_enable_debugging_features || dcheck_always_on
Ben Murdoch62ed6312017-06-06 11:06:27 +0100305}
306if (v8_enable_v8_checks == "") {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000307 v8_enable_v8_checks = v8_enable_debugging_features
308}
309if (v8_check_microtasks_scopes_consistency == "") {
310 v8_check_microtasks_scopes_consistency =
311 v8_enable_debugging_features || dcheck_always_on
312}
313if (v8_enable_snapshot_native_code_counters == "") {
314 v8_enable_snapshot_native_code_counters = v8_enable_debugging_features
315}
316if (v8_enable_pointer_compression == "") {
317 v8_enable_pointer_compression =
318 v8_current_cpu == "arm64" || v8_current_cpu == "x64"
319}
320if (v8_enable_fast_torque == "") {
321 v8_enable_fast_torque = v8_enable_fast_mksnapshot
322}
323if (v8_enable_zone_compression == "") {
324 v8_enable_zone_compression = false
325}
326if (v8_enable_heap_sandbox == "") {
327 v8_enable_heap_sandbox = false
328}
329if (v8_enable_single_generation == "") {
330 v8_enable_single_generation = v8_disable_write_barriers
331}
332if (v8_enable_atomic_object_field_writes == "") {
333 v8_enable_atomic_object_field_writes = v8_enable_concurrent_marking
334}
335if (v8_enable_atomic_marking_state == "") {
336 v8_enable_atomic_marking_state = v8_enable_concurrent_marking
337}
338assert(!v8_enable_concurrent_marking || v8_enable_atomic_object_field_writes,
339 "Concurrent marking requires atomic object field writes.")
340assert(!v8_enable_concurrent_marking || v8_enable_atomic_marking_state,
341 "Concurrent marking requires atomic marking state.")
342
343# Toggle pointer compression for correctness fuzzing when building the
344# clang_x64_pointer_compression toolchain. We'll correctness-compare the
345# default build with the clang_x64_pointer_compression build.
346if (v8_multi_arch_build &&
347 rebase_path(get_label_info(":d8", "root_out_dir"), root_build_dir) ==
348 "clang_x64_pointer_compression") {
349 v8_enable_pointer_compression = !v8_enable_pointer_compression
350}
351if (v8_enable_shared_ro_heap == "") {
352 v8_enable_shared_ro_heap = !v8_enable_pointer_compression
Ben Murdochf91f0612016-11-29 16:50:11 +0000353}
354
Rubin Xu7bc1b612021-02-16 09:38:50 +0000355assert(!v8_disable_write_barriers || v8_enable_single_generation,
356 "Disabling write barriers works only with single generation")
Ben Murdochf3b273f2017-01-17 12:11:28 +0000357
Rubin Xu7bc1b612021-02-16 09:38:50 +0000358assert(v8_current_cpu != "x86" || !v8_untrusted_code_mitigations,
359 "Untrusted code mitigations are unsupported on ia32")
360
361assert(v8_current_cpu == "arm64" || !v8_control_flow_integrity,
362 "Control-flow integrity is only supported on arm64")
363
364if (v8_enable_shared_ro_heap && v8_enable_pointer_compression) {
365 assert(
366 is_linux || is_chromeos || is_android,
367 "Sharing read-only heap with pointer compression is only supported on Linux or Android")
368}
369
370assert(!v8_use_multi_snapshots || !v8_control_flow_integrity,
371 "Control-flow integrity does not support multisnapshots")
372
373assert(!v8_enable_heap_sandbox || v8_enable_pointer_compression,
374 "V8 Heap Sandbox requires pointer compression")
375
376assert(!v8_enable_unconditional_write_barriers || !v8_disable_write_barriers,
377 "Write barriers can't be both enabled and disabled")
378
379assert(!cppgc_enable_caged_heap || v8_current_cpu == "x64" ||
380 v8_current_cpu == "arm64",
381 "CppGC caged heap requires 64bit platforms")
382
383assert(!cppgc_enable_young_generation || cppgc_enable_caged_heap,
384 "Young generation in CppGC requires caged heap")
385
386if (v8_enable_single_generation == true) {
387 assert(
388 v8_enable_unconditional_write_barriers || v8_disable_write_barriers,
389 "Requires unconditional write barriers or none (which disables incremental marking)")
390}
391
392assert(!v8_enable_conservative_stack_scanning || v8_enable_single_generation,
393 "Conservative stack scanning requires single generation")
394
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000395v8_random_seed = "314159265"
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100396v8_toolset_for_shell = "host"
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000397
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000398###############################################################################
399# Configurations
400#
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000401
Rubin Xu7bc1b612021-02-16 09:38:50 +0000402config("internal_config_base") {
403 # Only targets in this file and its subdirs can depend on this.
404 visibility = [ "./*" ]
405
406 configs = [ ":v8_tracing_config" ]
407
408 include_dirs = [
409 ".",
410 "include",
411 "$target_gen_dir",
412 ]
413}
414
415config("internal_config") {
416 defines = []
417
418 # Only targets in this file and its subdirs can depend on this.
419 visibility = [ "./*" ]
420
421 configs = [
422 "//build/config/compiler:wexit_time_destructors",
423 ":internal_config_base",
424 ":v8_header_features",
425 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000426
Ben Murdoch014dc512016-03-22 12:00:34 +0000427 if (is_component_build) {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000428 defines += [ "BUILDING_V8_SHARED" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000429 }
430}
431
Rubin Xu7bc1b612021-02-16 09:38:50 +0000432# Should be applied to all targets that write trace events.
433config("v8_tracing_config") {
434 if (v8_use_perfetto) {
435 include_dirs = [
436 "third_party/perfetto/include",
437 "$root_gen_dir/third_party/perfetto",
438 "$root_gen_dir/third_party/perfetto/build_config",
439 ]
440 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000441}
442
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100443# This config should be applied to code using the libplatform.
444config("libplatform_config") {
445 include_dirs = [ "include" ]
Ben Murdochc8c1d9e2017-03-08 14:04:23 +0000446 if (is_component_build) {
447 defines = [ "USING_V8_PLATFORM_SHARED" ]
448 }
449}
450
451# This config should be applied to code using the libbase.
452config("libbase_config") {
453 if (is_component_build) {
454 defines = [ "USING_V8_BASE_SHARED" ]
455 }
456 libs = []
457 if (is_android && current_toolchain != host_toolchain) {
458 libs += [ "log" ]
459 }
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100460}
461
Rubin Xu7bc1b612021-02-16 09:38:50 +0000462# This config should be applied to code using the cppgc_base.
463config("cppgc_base_config") {
464 defines = []
465 if (cppgc_enable_object_names) {
466 defines += [ "CPPGC_SUPPORTS_OBJECT_NAMES" ]
467 }
468 if (cppgc_enable_caged_heap) {
469 defines += [ "CPPGC_CAGED_HEAP" ]
470 }
471 if (cppgc_enable_young_generation) {
472 defines += [ "CPPGC_YOUNG_GENERATION" ]
473 }
474}
475
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100476# This config should be applied to code using the libsampler.
477config("libsampler_config") {
478 include_dirs = [ "include" ]
479}
480
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000481# This config should only be applied to code using V8 and not any V8 code
482# itself.
483config("external_config") {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000484 defines = []
485 configs = [ ":v8_header_features" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000486 if (is_component_build) {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000487 defines += [ "USING_V8_SHARED" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000488 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000489 include_dirs = [
490 "include",
491 "$target_gen_dir/include",
492 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000493}
494
Ben Murdoch014dc512016-03-22 12:00:34 +0000495# This config should only be applied to code that needs to be explicitly
496# aware of whether we are using startup data or not.
497config("external_startup_data") {
498 if (v8_use_external_startup_data) {
499 defines = [ "V8_USE_EXTERNAL_STARTUP_DATA" ]
500 }
501}
502
Rubin Xu7bc1b612021-02-16 09:38:50 +0000503# Put defines that are used in public headers here; public headers are
504# defined in "v8_headers" and are included by embedders of V8.
505config("v8_header_features") {
506 visibility = [ ":*" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000507
508 defines = []
509
Rubin Xu7bc1b612021-02-16 09:38:50 +0000510 if (v8_enable_v8_checks) {
511 defines += [ "V8_ENABLE_CHECKS" ] # Used in "include/v8.h".
512 }
513 if (v8_enable_pointer_compression) {
514 defines += [ "V8_COMPRESS_POINTERS" ]
515 }
516 if (v8_enable_pointer_compression || v8_enable_31bit_smis_on_64bit_arch) {
517 defines += [ "V8_31BIT_SMIS_ON_64BIT_ARCH" ]
518 }
519 if (v8_enable_zone_compression) {
520 defines += [ "V8_COMPRESS_ZONES" ]
521 }
522 if (v8_enable_heap_sandbox) {
523 defines += [ "V8_HEAP_SANDBOX" ]
524 }
525 if (v8_deprecation_warnings) {
526 defines += [ "V8_DEPRECATION_WARNINGS" ]
527 }
528 if (v8_imminent_deprecation_warnings) {
529 defines += [ "V8_IMMINENT_DEPRECATION_WARNINGS" ]
530 }
531 if (v8_disable_arguments_adaptor) {
532 defines += [ "V8_NO_ARGUMENTS_ADAPTOR" ]
533 }
534}
535
536# Put defines here that are only used in our internal files and NEVER in
537# external headers that embedders (such as chromium and node) might include.
538config("features") {
539 # Only targets in this file and its subdirs can depend on this.
540 visibility = [ "./*" ]
541
542 defines = []
543
544 configs = [ ":v8_header_features" ]
545
546 if (v8_embedder_string != "") {
547 defines += [ "V8_EMBEDDER_STRING=\"$v8_embedder_string\"" ]
548 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100549 if (v8_enable_disassembler) {
Ben Murdoch014dc512016-03-22 12:00:34 +0000550 defines += [ "ENABLE_DISASSEMBLER" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000551 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000552 if (v8_promise_internal_field_count != 0) {
553 defines +=
554 [ "V8_PROMISE_INTERNAL_FIELD_COUNT=${v8_promise_internal_field_count}" ]
555 }
556 defines +=
557 [ "V8_TYPED_ARRAY_MAX_SIZE_IN_HEAP=${v8_typed_array_max_size_in_heap}" ]
558
559 assert(
560 !v8_enable_raw_heap_snapshots,
561 "This flag is deprecated and is now available through the inspector interface as an argument to profiler's method `takeHeapSnapshot`. Consider using blink's flag `enable_additional_blink_object_names` to get better naming of internal objects.")
562
563 if (v8_enable_future) {
564 defines += [ "V8_ENABLE_FUTURE" ]
565 }
566 if (v8_enable_lite_mode) {
567 defines += [ "V8_LITE_MODE" ]
568 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100569 if (v8_enable_gdbjit) {
Ben Murdoch014dc512016-03-22 12:00:34 +0000570 defines += [ "ENABLE_GDB_JIT_INTERFACE" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000571 }
Ben Murdoch62ed6312017-06-06 11:06:27 +0100572 if (v8_enable_vtunejit) {
573 defines += [ "ENABLE_VTUNE_JIT_INTERFACE" ]
574 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000575 if (v8_enable_vtunetracemark) {
576 defines += [ "ENABLE_VTUNE_TRACEMARK" ]
577 }
578 if (v8_enable_minor_mc) {
579 defines += [ "ENABLE_MINOR_MC" ]
580 }
Ben Murdoch62ed6312017-06-06 11:06:27 +0100581 if (v8_enable_object_print) {
Ben Murdoch014dc512016-03-22 12:00:34 +0000582 defines += [ "OBJECT_PRINT" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000583 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100584 if (v8_enable_verify_heap) {
Ben Murdoch014dc512016-03-22 12:00:34 +0000585 defines += [ "VERIFY_HEAP" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000586 }
Ben Murdoch62ed6312017-06-06 11:06:27 +0100587 if (v8_enable_verify_predictable) {
588 defines += [ "VERIFY_PREDICTABLE" ]
589 }
590 if (v8_enable_trace_maps) {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000591 defines += [ "V8_TRACE_MAPS" ]
Ben Murdoch62ed6312017-06-06 11:06:27 +0100592 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000593 if (v8_enable_trace_ignition) {
594 defines += [ "V8_TRACE_IGNITION" ]
Ben Murdoch62ed6312017-06-06 11:06:27 +0100595 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000596 if (v8_enable_trace_feedback_updates) {
597 defines += [ "V8_TRACE_FEEDBACK_UPDATES" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000598 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000599 if (v8_enable_test_features) {
600 defines += [ "V8_ENABLE_ALLOCATION_TIMEOUT" ]
601 defines += [ "V8_ENABLE_FORCE_SLOW_PATH" ]
602 defines += [ "V8_ENABLE_DOUBLE_CONST_STORE_CHECK" ]
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100603 }
604 if (v8_enable_i18n_support) {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000605 defines += [ "V8_INTL_SUPPORT" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000606 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100607 if (v8_enable_handle_zapping) {
Ben Murdoch014dc512016-03-22 12:00:34 +0000608 defines += [ "ENABLE_HANDLE_ZAPPING" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000609 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000610 if (v8_enable_snapshot_native_code_counters) {
611 defines += [ "V8_SNAPSHOT_NATIVE_CODE_COUNTERS" ]
612 }
613 if (v8_enable_single_generation) {
614 defines += [ "V8_ENABLE_SINGLE_GENERATION" ]
615 }
616 if (v8_enable_conservative_stack_scanning) {
617 defines += [ "V8_ENABLE_CONSERVATIVE_STACK_SCANNING" ]
618 }
619 if (v8_disable_write_barriers) {
620 defines += [ "V8_DISABLE_WRITE_BARRIERS" ]
621 }
622 if (v8_enable_third_party_heap) {
623 defines += [ "V8_ENABLE_THIRD_PARTY_HEAP" ]
624 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100625 if (v8_use_external_startup_data) {
Ben Murdoch014dc512016-03-22 12:00:34 +0000626 defines += [ "V8_USE_EXTERNAL_STARTUP_DATA" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000627 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000628 if (v8_enable_atomic_object_field_writes) {
629 defines += [ "V8_ATOMIC_OBJECT_FIELD_WRITES" ]
630 }
631 if (v8_enable_atomic_marking_state) {
632 defines += [ "V8_ATOMIC_MARKING_STATE" ]
633 }
634 if (v8_enable_lazy_source_positions) {
635 defines += [ "V8_ENABLE_LAZY_SOURCE_POSITIONS" ]
636 }
637 if (v8_check_microtasks_scopes_consistency) {
638 defines += [ "V8_CHECK_MICROTASKS_SCOPES_CONSISTENCY" ]
639 }
640 if (v8_use_multi_snapshots) {
641 defines += [ "V8_MULTI_SNAPSHOTS" ]
642 }
643 if (v8_use_siphash) {
644 defines += [ "V8_USE_SIPHASH" ]
645 }
646 if (v8_enable_shared_ro_heap) {
647 defines += [ "V8_SHARED_RO_HEAP" ]
648 }
649 if (v8_use_perfetto) {
650 defines += [ "V8_USE_PERFETTO" ]
651 }
652 if (v8_win64_unwinding_info) {
653 defines += [ "V8_WIN64_UNWINDING_INFO" ]
654 }
655 if (v8_enable_regexp_interpreter_threaded_dispatch) {
656 defines += [ "V8_ENABLE_REGEXP_INTERPRETER_THREADED_DISPATCH" ]
657 }
658 if (v8_enable_snapshot_compression) {
659 defines += [ "V8_SNAPSHOT_COMPRESSION" ]
660 }
661 if (v8_control_flow_integrity) {
662 defines += [ "V8_ENABLE_CONTROL_FLOW_INTEGRITY" ]
663 }
664 if (v8_enable_wasm_gdb_remote_debugging) {
665 defines += [ "V8_ENABLE_WASM_GDB_REMOTE_DEBUGGING" ]
666 }
667 if (v8_enable_precise_zone_stats) {
668 defines += [ "V8_ENABLE_PRECISE_ZONE_STATS" ]
669 }
670 if (v8_fuzzilli) {
671 defines += [ "V8_FUZZILLI" ]
672 }
673 if (v8_dict_mode_prototypes) {
674 defines += [ "V8_DICT_MODE_PROTOTYPES" ]
675 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000676}
677
678config("toolchain") {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000679 # Only targets in this file and its subdirs can depend on this.
680 visibility = [ "./*" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000681
682 defines = []
683 cflags = []
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100684 ldflags = []
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000685
Ben Murdochf91f0612016-11-29 16:50:11 +0000686 if (v8_current_cpu == "arm") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000687 defines += [ "V8_TARGET_ARCH_ARM" ]
Ben Murdochf3b273f2017-01-17 12:11:28 +0000688 if (arm_version >= 7) {
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100689 defines += [ "CAN_USE_ARMV7_INSTRUCTIONS" ]
690 }
691 if (arm_fpu == "vfpv3-d16") {
692 defines += [ "CAN_USE_VFP3_INSTRUCTIONS" ]
693 } else if (arm_fpu == "vfpv3") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000694 defines += [
Ben Murdoch014dc512016-03-22 12:00:34 +0000695 "CAN_USE_VFP3_INSTRUCTIONS",
696 "CAN_USE_VFP32DREGS",
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100697 ]
698 } else if (arm_fpu == "neon") {
699 defines += [
700 "CAN_USE_VFP3_INSTRUCTIONS",
701 "CAN_USE_VFP32DREGS",
702 "CAN_USE_NEON",
Ben Murdoch014dc512016-03-22 12:00:34 +0000703 ]
704 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100705
Ben Murdoch014dc512016-03-22 12:00:34 +0000706 # TODO(jochen): Add support for arm_test_noprobe.
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100707
708 if (current_cpu != "arm") {
709 # These defines ares used for the ARM simulator.
710 if (arm_float_abi == "hard") {
711 defines += [ "USE_EABI_HARDFLOAT=1" ]
712 } else if (arm_float_abi == "softfp") {
713 defines += [ "USE_EABI_HARDFLOAT=0" ]
714 }
715 }
Ben Murdoch014dc512016-03-22 12:00:34 +0000716 }
Ben Murdochf91f0612016-11-29 16:50:11 +0000717 if (v8_current_cpu == "arm64") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000718 defines += [ "V8_TARGET_ARCH_ARM64" ]
Rubin Xu7bc1b612021-02-16 09:38:50 +0000719 if (v8_control_flow_integrity) {
720 # TODO(v8:10026): Enable this in src/build.
721 if (current_cpu == "arm64") {
722 cflags += [ "-mbranch-protection=standard" ]
723 }
724 }
Ben Murdoch014dc512016-03-22 12:00:34 +0000725 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100726
Ben Murdochf3b273f2017-01-17 12:11:28 +0000727 # Mips64el/mipsel simulators.
Rubin Xu7bc1b612021-02-16 09:38:50 +0000728 if (target_is_simulator &&
Ben Murdochf3b273f2017-01-17 12:11:28 +0000729 (v8_current_cpu == "mipsel" || v8_current_cpu == "mips64el")) {
730 defines += [ "_MIPS_TARGET_SIMULATOR" ]
731 }
732
Rubin Xu7bc1b612021-02-16 09:38:50 +0000733 if (v8_current_cpu == "mipsel" || v8_current_cpu == "mips") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000734 defines += [ "V8_TARGET_ARCH_MIPS" ]
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100735 if (v8_can_use_fpu_instructions) {
736 defines += [ "CAN_USE_FPU_INSTRUCTIONS" ]
737 }
738 if (v8_use_mips_abi_hardfloat) {
739 defines += [
740 "__mips_hard_float=1",
741 "CAN_USE_FPU_INSTRUCTIONS",
742 ]
743 } else {
744 defines += [ "__mips_soft_float=1" ]
745 }
746 if (mips_arch_variant == "r6") {
747 defines += [
748 "_MIPS_ARCH_MIPS32R6",
749 "FPU_MODE_FP64",
750 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +0000751 if (mips_use_msa) {
752 defines += [ "_MIPS_MSA" ]
753 }
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100754 } else if (mips_arch_variant == "r2") {
755 defines += [ "_MIPS_ARCH_MIPS32R2" ]
756 if (mips_fpu_mode == "fp64") {
757 defines += [ "FPU_MODE_FP64" ]
758 } else if (mips_fpu_mode == "fpxx") {
759 defines += [ "FPU_MODE_FPXX" ]
760 } else if (mips_fpu_mode == "fp32") {
761 defines += [ "FPU_MODE_FP32" ]
762 }
763 } else if (mips_arch_variant == "r1") {
764 defines += [ "FPU_MODE_FP32" ]
765 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100766
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100767 # TODO(jochen): Add support for mips_arch_variant rx and loongson.
Ben Murdoch014dc512016-03-22 12:00:34 +0000768 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100769
Rubin Xu7bc1b612021-02-16 09:38:50 +0000770 if (v8_current_cpu == "mips64el" || v8_current_cpu == "mips64") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000771 defines += [ "V8_TARGET_ARCH_MIPS64" ]
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100772 if (v8_can_use_fpu_instructions) {
773 defines += [ "CAN_USE_FPU_INSTRUCTIONS" ]
774 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000775 if (mips_use_msa) {
776 defines += [ "_MIPS_MSA" ]
777 }
778 if (host_byteorder == "little") {
779 defines += [ "V8_TARGET_ARCH_MIPS64_LE" ]
780 } else if (host_byteorder == "big") {
781 defines += [ "V8_TARGET_ARCH_MIPS64_BE" ]
782 }
Ben Murdoch3b9bc312016-06-02 14:46:10 +0100783 if (v8_use_mips_abi_hardfloat) {
784 defines += [
785 "__mips_hard_float=1",
786 "CAN_USE_FPU_INSTRUCTIONS",
787 ]
788 } else {
789 defines += [ "__mips_soft_float=1" ]
790 }
791 if (mips_arch_variant == "r6") {
792 defines += [ "_MIPS_ARCH_MIPS64R6" ]
793 } else if (mips_arch_variant == "r2") {
794 defines += [ "_MIPS_ARCH_MIPS64R2" ]
795 }
Ben Murdoch014dc512016-03-22 12:00:34 +0000796 }
Ben Murdochf91f0612016-11-29 16:50:11 +0000797 if (v8_current_cpu == "s390" || v8_current_cpu == "s390x") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000798 defines += [ "V8_TARGET_ARCH_S390" ]
Rubin Xu7bc1b612021-02-16 09:38:50 +0000799 cflags += [ "-ffp-contract=off" ]
Ben Murdochf91f0612016-11-29 16:50:11 +0000800 if (v8_current_cpu == "s390x") {
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100801 defines += [ "V8_TARGET_ARCH_S390X" ]
802 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000803 if (host_byteorder == "little") {
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100804 defines += [ "V8_TARGET_ARCH_S390_LE_SIM" ]
Rubin Xu7bc1b612021-02-16 09:38:50 +0000805 } else {
806 cflags += [ "-march=z196" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100807 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100808 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000809 if (v8_current_cpu == "ppc" || v8_current_cpu == "ppc64") {
810 if (v8_current_cpu == "ppc") {
811 defines += [ "V8_TARGET_ARCH_PPC" ]
812 } else if (v8_current_cpu == "ppc64") {
813 defines += [ "V8_TARGET_ARCH_PPC64" ]
814 }
815 if (host_byteorder == "little") {
816 defines += [ "V8_TARGET_ARCH_PPC_LE" ]
817 } else if (host_byteorder == "big") {
818 defines += [ "V8_TARGET_ARCH_PPC_BE" ]
819 if (current_os == "aix") {
820 cflags += [
821 # Work around AIX ceil, trunc and round oddities.
822 "-mcpu=power5+",
823 "-mfprnd",
824
825 # Work around AIX assembler popcntb bug.
826 "-mno-popcntb",
827 ]
828 }
829 }
830 }
831
Ben Murdochf91f0612016-11-29 16:50:11 +0000832 if (v8_current_cpu == "x86") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000833 defines += [ "V8_TARGET_ARCH_IA32" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100834 if (is_win) {
835 # Ensure no surprising artifacts from 80bit double math with x86.
836 cflags += [ "/arch:SSE2" ]
837 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000838 }
Ben Murdochf91f0612016-11-29 16:50:11 +0000839 if (v8_current_cpu == "x64") {
Ben Murdoch014dc512016-03-22 12:00:34 +0000840 defines += [ "V8_TARGET_ARCH_X64" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100841 if (is_win) {
842 # Increase the initial stack size. The default is 1MB, this is 2MB. This
843 # applies only to executables and shared libraries produced by V8 since
844 # ldflags are not pushed to dependants.
845 ldflags += [ "/STACK:2097152" ]
846 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000847 }
Ben Murdochf91f0612016-11-29 16:50:11 +0000848 if (is_android && v8_android_log_stdout) {
849 defines += [ "V8_ANDROID_LOG_STDOUT" ]
850 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100851
Rubin Xu7bc1b612021-02-16 09:38:50 +0000852 # V8_TARGET_OS_ defines. The target OS may differ from host OS e.g. in
853 # mksnapshot. We additionally set V8_HAVE_TARGET_OS to determine that a
854 # target OS has in fact been set; otherwise we internally assume that target
855 # OS == host OS (see v8config.h).
856 if (target_os == "android") {
857 defines += [ "V8_HAVE_TARGET_OS" ]
858 defines += [ "V8_TARGET_OS_ANDROID" ]
859 } else if (target_os == "fuchsia") {
860 defines += [ "V8_HAVE_TARGET_OS" ]
861 defines += [ "V8_TARGET_OS_FUCHSIA" ]
862 } else if (target_os == "ios") {
863 defines += [ "V8_HAVE_TARGET_OS" ]
864 defines += [ "V8_TARGET_OS_IOS" ]
865 } else if (target_os == "linux") {
866 defines += [ "V8_HAVE_TARGET_OS" ]
867 defines += [ "V8_TARGET_OS_LINUX" ]
868 } else if (target_os == "mac") {
869 defines += [ "V8_HAVE_TARGET_OS" ]
870 defines += [ "V8_TARGET_OS_MACOSX" ]
871 } else if (target_os == "win") {
872 defines += [ "V8_HAVE_TARGET_OS" ]
873 defines += [ "V8_TARGET_OS_WIN" ]
874 }
875
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100876 # TODO(jochen): Support v8_enable_prof on Windows.
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000877 # TODO(jochen): Add support for compiling with simulators.
878
Rubin Xu7bc1b612021-02-16 09:38:50 +0000879 if (v8_enable_debugging_features) {
880 if ((is_linux || is_chromeos) && v8_enable_backtrace) {
Ben Murdochf91f0612016-11-29 16:50:11 +0000881 ldflags += [ "-rdynamic" ]
882 }
883
Ben Murdoch62ed6312017-06-06 11:06:27 +0100884 defines += [ "DEBUG" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100885 if (v8_enable_slow_dchecks) {
Ben Murdochbcf72ee2016-08-08 18:44:38 +0100886 defines += [ "ENABLE_SLOW_DCHECKS" ]
887 }
Ben Murdoch13e2dad2016-09-16 13:49:30 +0100888 } else if (dcheck_always_on) {
889 defines += [ "DEBUG" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000890 }
Ben Murdochf3b273f2017-01-17 12:11:28 +0000891
Ben Murdoch62ed6312017-06-06 11:06:27 +0100892 if (v8_enable_verify_csa) {
893 defines += [ "ENABLE_VERIFY_CSA" ]
894 }
895
Rubin Xu7bc1b612021-02-16 09:38:50 +0000896 if (!v8_untrusted_code_mitigations) {
897 defines += [ "DISABLE_UNTRUSTED_CODE_MITIGATIONS" ]
898 }
899
Ben Murdochf3b273f2017-01-17 12:11:28 +0000900 if (v8_no_inline) {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000901 if (is_win) {
902 cflags += [ "/Ob0" ]
903 } else {
904 cflags += [
905 "-fno-inline-functions",
906 "-fno-inline",
907 ]
908 }
Ben Murdochf3b273f2017-01-17 12:11:28 +0000909 }
Ben Murdochc8c1d9e2017-03-08 14:04:23 +0000910
911 if (is_clang) {
Rubin Xu7bc1b612021-02-16 09:38:50 +0000912 cflags += [ "-Wmissing-field-initializers" ]
Ben Murdochc8c1d9e2017-03-08 14:04:23 +0000913
Rubin Xu7bc1b612021-02-16 09:38:50 +0000914 if (v8_current_cpu != "mips" && v8_current_cpu != "mipsel") {
915 # We exclude MIPS because the IsMipsArchVariant macro causes trouble.
916 cflags += [ "-Wunreachable-code" ]
917 }
918
919 if (v8_current_cpu == "x64" || v8_current_cpu == "arm64" ||
920 v8_current_cpu == "mips64el") {
921 cflags += [ "-Wshorten-64-to-32" ]
922 }
Ben Murdochc8c1d9e2017-03-08 14:04:23 +0000923 }
Rubin Xu7bc1b612021-02-16 09:38:50 +0000924
925 if (is_win) {
926 cflags += [
927 "/wd4245", # Conversion with signed/unsigned mismatch.
928 "/wd4267", # Conversion with possible loss of data.
929 "/wd4324", # Padding structure due to alignment.
930 "/wd4701", # Potentially uninitialized local variable.
931 "/wd4702", # Unreachable code.
932 "/wd4703", # Potentially uninitialized local pointer variable.
933 "/wd4709", # Comma operator within array index expr (bugged).
934 "/wd4714", # Function marked forceinline not inlined.
935
936 # MSVC assumes that control can get past an exhaustive switch and then
937 # warns if there's no return there (see https://crbug.com/v8/7658)
938 "/wd4715", # Not all control paths return a value.
939
940 "/wd4718", # Recursive call has no side-effect.
941 "/wd4723", # https://crbug.com/v8/7771
942 "/wd4724", # https://crbug.com/v8/7771
943 "/wd4800", # Forcing value to bool.
944 ]
945 }
946
947 if (!is_clang && is_win) {
948 cflags += [ "/wd4506" ] # Benign "no definition for inline function"
949 }
950
951 if (!is_clang && !is_win) {
952 cflags += [
953 # Disable gcc warnings for optimizations based on the assumption that
954 # signed overflow does not occur. Generates false positives (see
955 # http://crbug.com/v8/6341).
956 "-Wno-strict-overflow",
957
958 # GCC assumes that control can get past an exhaustive switch and then
959 # warns if there's no return there (see https://crbug.com/v8/7658).
960 "-Wno-return-type",
961
962 # Disable gcc warnings for using enum constant in boolean context.
963 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97266
964 "-Wno-int-in-bool-context",
965 ]
966 }
967
968 # Chromium uses a hand-picked subset of UBSan coverage. We want everything.
969 if (is_ubsan) {
970 cflags += [ "-fsanitize=undefined" ]
971 }
972}
973
974# For code that is hot during mksnapshot. In fast-mksnapshot builds, we
975# optimize some files even in debug builds to speed up mksnapshot times.
976config("always_optimize") {
977 configs = [ ":internal_config" ]
978
979 # TODO(crbug.com/621335) Rework this so that we don't have the confusion
980 # between "optimize_speed" and "optimize_max".
981 if (((is_posix && !is_android) || is_fuchsia) && !using_sanitizer) {
982 configs += [ "//build/config/compiler:optimize_speed" ]
983 } else {
984 configs += [ "//build/config/compiler:optimize_max" ]
985 }
986}
987
988# Configs for code coverage with gcov. Separate configs for cflags and ldflags
989# to selectively influde cflags in non-test targets only.
990config("v8_gcov_coverage_cflags") {
991 cflags = [
992 "-fprofile-arcs",
993 "-ftest-coverage",
994 ]
995}
996
997config("v8_gcov_coverage_ldflags") {
998 ldflags = [ "-fprofile-arcs" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000999}
1000
1001###############################################################################
1002# Actions
1003#
1004
Rubin Xu7bc1b612021-02-16 09:38:50 +00001005# Only for Windows clang builds. Converts the embedded.S file produced by
1006# mksnapshot into an embedded.cc file with corresponding inline assembly.
1007template("asm_to_inline_asm") {
1008 name = target_name
1009 if (name == "default") {
1010 suffix = ""
1011 } else {
1012 suffix = "_$name"
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001013 }
1014
Rubin Xu7bc1b612021-02-16 09:38:50 +00001015 action("asm_to_inline_asm_" + name) {
1016 visibility = [ ":*" ] # Only targets in this file can depend on this.
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001017
Rubin Xu7bc1b612021-02-16 09:38:50 +00001018 assert(emit_builtins_as_inline_asm)
1019
1020 script = "tools/snapshot/asm_to_inline_asm.py"
1021 deps = [ ":run_mksnapshot_" + name ]
1022 sources = [ "$target_gen_dir/embedded${suffix}.S" ]
1023 outputs = [ "$target_gen_dir/embedded${suffix}.cc" ]
1024 args = invoker.args
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001025 args += [
Rubin Xu7bc1b612021-02-16 09:38:50 +00001026 rebase_path("$target_gen_dir/embedded${suffix}.S", root_build_dir),
1027 rebase_path("$target_gen_dir/embedded${suffix}.cc", root_build_dir),
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001028 ]
1029 }
1030}
1031
Ben Murdochf91f0612016-11-29 16:50:11 +00001032if (is_android && enable_java_templates) {
Ben Murdoch014dc512016-03-22 12:00:34 +00001033 android_assets("v8_external_startup_data_assets") {
1034 if (v8_use_external_startup_data) {
Rubin Xu7bc1b612021-02-16 09:38:50 +00001035 # We don't support side-by-side snapshots on Android within Chromium.
1036 assert(!v8_use_multi_snapshots)
1037 deps = [ "//v8" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01001038 renaming_sources = [ "$root_out_dir/snapshot_blob.bin" ]
1039 if (current_cpu == "arm" || current_cpu == "x86" ||
1040 current_cpu == "mipsel") {
1041 renaming_destinations = [ "snapshot_blob_32.bin" ]
1042 } else {
1043 renaming_destinations = [ "snapshot_blob_64.bin" ]
1044 }
Ben Murdoch014dc512016-03-22 12:00:34 +00001045 disable_compression = true
1046 }
1047 }
1048}
1049
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001050action("postmortem-metadata") {
Ben Murdoch014dc512016-03-22 12:00:34 +00001051 # Only targets in this file and the top-level visibility target can
1052 # depend on this.
1053 visibility = [
1054 ":*",
1055 "//:gn_visibility",
1056 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001057
1058 script = "tools/gen-postmortem-metadata.py"
1059
Ben Murdoch3b9bc312016-06-02 14:46:10 +01001060 # NOSORT
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001061 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00001062 "$target_gen_dir/torque-generated/instance-types.h",
1063 "src/objects/allocation-site.h",
1064 "src/objects/allocation-site-inl.h",
1065 "src/objects/cell.h",
1066 "src/objects/cell-inl.h",
1067 "src/objects/code.h",
1068 "src/objects/code-inl.h",
1069 "src/objects/data-handler.h",
1070 "src/objects/data-handler-inl.h",
1071 "src/objects/descriptor-array.h",
1072 "src/objects/descriptor-array-inl.h",
1073 "src/objects/feedback-cell.h",
1074 "src/objects/feedback-cell-inl.h",
1075 "src/objects/fixed-array.h",
1076 "src/objects/fixed-array-inl.h",
1077 "src/objects/heap-number.h",
1078 "src/objects/heap-number-inl.h",
1079 "src/objects/heap-object.h",
1080 "src/objects/heap-object-inl.h",
1081 "src/objects/instance-type.h",
1082 "src/objects/js-array-buffer.h",
1083 "src/objects/js-array-buffer-inl.h",
1084 "src/objects/js-array.h",
1085 "src/objects/js-array-inl.h",
1086 "src/objects/js-function-inl.h",
1087 "src/objects/js-function.cc",
1088 "src/objects/js-function.h",
1089 "src/objects/js-objects.cc",
1090 "src/objects/js-objects.h",
1091 "src/objects/js-objects-inl.h",
1092 "src/objects/js-promise.h",
1093 "src/objects/js-promise-inl.h",
1094 "src/objects/js-regexp.cc",
1095 "src/objects/js-regexp.h",
1096 "src/objects/js-regexp-inl.h",
1097 "src/objects/js-regexp-string-iterator.h",
1098 "src/objects/js-regexp-string-iterator-inl.h",
1099 "src/objects/map.cc",
1100 "src/objects/map.h",
1101 "src/objects/map-inl.h",
1102 "src/objects/name.h",
1103 "src/objects/name-inl.h",
1104 "src/objects/objects.h",
1105 "src/objects/objects-inl.h",
1106 "src/objects/oddball.h",
1107 "src/objects/oddball-inl.h",
1108 "src/objects/primitive-heap-object.h",
1109 "src/objects/primitive-heap-object-inl.h",
1110 "src/objects/scope-info.h",
1111 "src/objects/script.h",
1112 "src/objects/script-inl.h",
1113 "src/objects/shared-function-info.cc",
1114 "src/objects/shared-function-info.h",
1115 "src/objects/shared-function-info-inl.h",
1116 "src/objects/string.cc",
1117 "src/objects/string-comparator.cc",
1118 "src/objects/string-comparator.h",
1119 "src/objects/string.h",
1120 "src/objects/string-inl.h",
1121 "src/objects/struct.h",
1122 "src/objects/struct-inl.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001123 ]
1124
Rubin Xu7bc1b612021-02-16 09:38:50 +00001125 outputs = [ "$target_gen_dir/debug-support.cc" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001126
Ben Murdoch014dc512016-03-22 12:00:34 +00001127 args = rebase_path(outputs, root_build_dir) +
1128 rebase_path(sources, root_build_dir)
Rubin Xu7bc1b612021-02-16 09:38:50 +00001129
1130 deps = [ ":run_torque" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001131}
1132
Rubin Xu7bc1b612021-02-16 09:38:50 +00001133torque_files = [
1134 "src/builtins/aggregate-error.tq",
1135 "src/builtins/array-copywithin.tq",
1136 "src/builtins/array-every.tq",
1137 "src/builtins/array-filter.tq",
1138 "src/builtins/array-find.tq",
1139 "src/builtins/array-findindex.tq",
1140 "src/builtins/array-foreach.tq",
1141 "src/builtins/array-from.tq",
1142 "src/builtins/array-isarray.tq",
1143 "src/builtins/array-join.tq",
1144 "src/builtins/array-lastindexof.tq",
1145 "src/builtins/array-map.tq",
1146 "src/builtins/array-of.tq",
1147 "src/builtins/array-reduce-right.tq",
1148 "src/builtins/array-reduce.tq",
1149 "src/builtins/array-reverse.tq",
1150 "src/builtins/array-shift.tq",
1151 "src/builtins/array-slice.tq",
1152 "src/builtins/array-some.tq",
1153 "src/builtins/array-splice.tq",
1154 "src/builtins/array-unshift.tq",
1155 "src/builtins/array.tq",
1156 "src/builtins/arraybuffer.tq",
1157 "src/builtins/base.tq",
1158 "src/builtins/boolean.tq",
1159 "src/builtins/builtins-bigint.tq",
1160 "src/builtins/builtins-string.tq",
1161 "src/builtins/cast.tq",
1162 "src/builtins/collections.tq",
1163 "src/builtins/constructor.tq",
1164 "src/builtins/conversion.tq",
1165 "src/builtins/convert.tq",
1166 "src/builtins/console.tq",
1167 "src/builtins/data-view.tq",
1168 "src/builtins/finalization-registry.tq",
1169 "src/builtins/frames.tq",
1170 "src/builtins/frame-arguments.tq",
1171 "src/builtins/function.tq",
1172 "src/builtins/growable-fixed-array.tq",
1173 "src/builtins/ic-callable.tq",
1174 "src/builtins/ic-dynamic-map-checks.tq",
1175 "src/builtins/ic.tq",
1176 "src/builtins/internal-coverage.tq",
1177 "src/builtins/internal.tq",
1178 "src/builtins/iterator.tq",
1179 "src/builtins/math.tq",
1180 "src/builtins/number.tq",
1181 "src/builtins/object-fromentries.tq",
1182 "src/builtins/object.tq",
1183 "src/builtins/promise-abstract-operations.tq",
1184 "src/builtins/promise-all.tq",
1185 "src/builtins/promise-all-element-closure.tq",
1186 "src/builtins/promise-any.tq",
1187 "src/builtins/promise-constructor.tq",
1188 "src/builtins/promise-finally.tq",
1189 "src/builtins/promise-misc.tq",
1190 "src/builtins/promise-race.tq",
1191 "src/builtins/promise-reaction-job.tq",
1192 "src/builtins/promise-resolve.tq",
1193 "src/builtins/promise-then.tq",
1194 "src/builtins/promise-jobs.tq",
1195 "src/builtins/proxy-constructor.tq",
1196 "src/builtins/proxy-delete-property.tq",
1197 "src/builtins/proxy-get-property.tq",
1198 "src/builtins/proxy-get-prototype-of.tq",
1199 "src/builtins/proxy-has-property.tq",
1200 "src/builtins/proxy-is-extensible.tq",
1201 "src/builtins/proxy-prevent-extensions.tq",
1202 "src/builtins/proxy-revocable.tq",
1203 "src/builtins/proxy-revoke.tq",
1204 "src/builtins/proxy-set-property.tq",
1205 "src/builtins/proxy-set-prototype-of.tq",
1206 "src/builtins/proxy.tq",
1207 "src/builtins/reflect.tq",
1208 "src/builtins/regexp-exec.tq",
1209 "src/builtins/regexp-match-all.tq",
1210 "src/builtins/regexp-match.tq",
1211 "src/builtins/regexp-replace.tq",
1212 "src/builtins/regexp-search.tq",
1213 "src/builtins/regexp-source.tq",
1214 "src/builtins/regexp-split.tq",
1215 "src/builtins/regexp-test.tq",
1216 "src/builtins/regexp.tq",
1217 "src/builtins/string-endswith.tq",
1218 "src/builtins/string-html.tq",
1219 "src/builtins/string-iterator.tq",
1220 "src/builtins/string-pad.tq",
1221 "src/builtins/string-repeat.tq",
1222 "src/builtins/string-replaceall.tq",
1223 "src/builtins/string-slice.tq",
1224 "src/builtins/string-startswith.tq",
1225 "src/builtins/string-substr.tq",
1226 "src/builtins/string-substring.tq",
1227 "src/builtins/string-trim.tq",
1228 "src/builtins/symbol.tq",
1229 "src/builtins/torque-internal.tq",
1230 "src/builtins/typed-array-createtypedarray.tq",
1231 "src/builtins/typed-array-every.tq",
1232 "src/builtins/typed-array-entries.tq",
1233 "src/builtins/typed-array-filter.tq",
1234 "src/builtins/typed-array-find.tq",
1235 "src/builtins/typed-array-findindex.tq",
1236 "src/builtins/typed-array-foreach.tq",
1237 "src/builtins/typed-array-from.tq",
1238 "src/builtins/typed-array-keys.tq",
1239 "src/builtins/typed-array-of.tq",
1240 "src/builtins/typed-array-reduce.tq",
1241 "src/builtins/typed-array-reduceright.tq",
1242 "src/builtins/typed-array-set.tq",
1243 "src/builtins/typed-array-slice.tq",
1244 "src/builtins/typed-array-some.tq",
1245 "src/builtins/typed-array-sort.tq",
1246 "src/builtins/typed-array-subarray.tq",
1247 "src/builtins/typed-array-values.tq",
1248 "src/builtins/typed-array.tq",
1249 "src/builtins/wasm.tq",
1250 "src/builtins/weak-ref.tq",
1251 "src/ic/handler-configuration.tq",
1252 "src/objects/allocation-site.tq",
1253 "src/objects/api-callbacks.tq",
1254 "src/objects/arguments.tq",
1255 "src/objects/bigint.tq",
1256 "src/objects/cell.tq",
1257 "src/objects/code.tq",
1258 "src/objects/contexts.tq",
1259 "src/objects/data-handler.tq",
1260 "src/objects/debug-objects.tq",
1261 "src/objects/descriptor-array.tq",
1262 "src/objects/embedder-data-array.tq",
1263 "src/objects/feedback-cell.tq",
1264 "src/objects/feedback-vector.tq",
1265 "src/objects/fixed-array.tq",
1266 "src/objects/foreign.tq",
1267 "src/objects/free-space.tq",
1268 "src/objects/heap-number.tq",
1269 "src/objects/heap-object.tq",
1270 "src/objects/js-array-buffer.tq",
1271 "src/objects/js-array.tq",
1272 "src/objects/js-collection-iterator.tq",
1273 "src/objects/js-collection.tq",
1274 "src/objects/js-function.tq",
1275 "src/objects/js-generator.tq",
1276 "src/objects/js-objects.tq",
1277 "src/objects/js-promise.tq",
1278 "src/objects/js-proxy.tq",
1279 "src/objects/js-regexp-string-iterator.tq",
1280 "src/objects/js-regexp.tq",
1281 "src/objects/js-weak-refs.tq",
1282 "src/objects/literal-objects.tq",
1283 "src/objects/map.tq",
1284 "src/objects/microtask.tq",
1285 "src/objects/module.tq",
1286 "src/objects/name.tq",
1287 "src/objects/oddball.tq",
1288 "src/objects/ordered-hash-table.tq",
1289 "src/objects/primitive-heap-object.tq",
1290 "src/objects/promise.tq",
1291 "src/objects/property-array.tq",
1292 "src/objects/property-cell.tq",
1293 "src/objects/property-descriptor-object.tq",
1294 "src/objects/prototype-info.tq",
1295 "src/objects/regexp-match-info.tq",
1296 "src/objects/scope-info.tq",
1297 "src/objects/script.tq",
1298 "src/objects/shared-function-info.tq",
1299 "src/objects/source-text-module.tq",
1300 "src/objects/stack-frame-info.tq",
1301 "src/objects/string.tq",
1302 "src/objects/struct.tq",
1303 "src/objects/synthetic-module.tq",
1304 "src/objects/template-objects.tq",
1305 "src/objects/templates.tq",
1306 "src/objects/torque-defined-classes.tq",
1307 "src/wasm/wasm-objects.tq",
1308 "test/torque/test-torque.tq",
1309 "third_party/v8/builtins/array-sort.tq",
1310]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001311
Rubin Xu7bc1b612021-02-16 09:38:50 +00001312if (v8_enable_i18n_support) {
1313 torque_files += [
1314 "src/objects/intl-objects.tq",
1315 "src/objects/js-break-iterator.tq",
1316 "src/objects/js-collator.tq",
1317 "src/objects/js-date-time-format.tq",
1318 "src/objects/js-display-names.tq",
1319 "src/objects/js-list-format.tq",
1320 "src/objects/js-locale.tq",
1321 "src/objects/js-number-format.tq",
1322 "src/objects/js-plural-rules.tq",
1323 "src/objects/js-relative-time-format.tq",
1324 "src/objects/js-segment-iterator.tq",
1325 "src/objects/js-segmenter.tq",
1326 "src/objects/js-segments.tq",
Ben Murdoch014dc512016-03-22 12:00:34 +00001327 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00001328}
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001329
Rubin Xu7bc1b612021-02-16 09:38:50 +00001330# Template for running torque
1331# When building with v8_verify_torque_generation_invariance=true we need
1332# to be able to run torque for both 32 and 64 bits in the same build
1333template("run_torque") {
1334 if (target_name == "") {
1335 suffix = ""
1336 } else {
1337 suffix = "_$target_name"
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001338 }
1339
Rubin Xu7bc1b612021-02-16 09:38:50 +00001340 toolchain = invoker.toolchain
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00001341
Rubin Xu7bc1b612021-02-16 09:38:50 +00001342 action("run_torque" + suffix) {
1343 visibility = [
1344 ":*",
1345 "test/cctest/:*",
1346 "tools/debug_helper/:*",
1347 "tools/gcmole/:*",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001348 ]
Ben Murdochf91f0612016-11-29 16:50:11 +00001349
Rubin Xu7bc1b612021-02-16 09:38:50 +00001350 deps = [ ":torque($toolchain)" ]
1351
1352 script = "tools/run.py"
1353
1354 sources = torque_files
1355
1356 destination_folder = "$target_gen_dir/torque-generated$suffix"
1357
1358 files = [
1359 "$target_gen_dir/torque-generated/bit-fields.h",
1360 "$target_gen_dir/torque-generated/builtin-definitions.h",
1361 "$target_gen_dir/torque-generated/interface-descriptors.inc",
1362 "$target_gen_dir/torque-generated/factory.cc",
1363 "$target_gen_dir/torque-generated/factory.inc",
1364 "$target_gen_dir/torque-generated/field-offsets.h",
1365 "$target_gen_dir/torque-generated/class-verifiers.cc",
1366 "$target_gen_dir/torque-generated/class-verifiers.h",
1367 "$target_gen_dir/torque-generated/enum-verifiers.cc",
1368 "$target_gen_dir/torque-generated/objects-printer.cc",
1369 "$target_gen_dir/torque-generated/objects-body-descriptors-inl.inc",
1370 "$target_gen_dir/torque-generated/class-debug-readers.cc",
1371 "$target_gen_dir/torque-generated/class-debug-readers.h",
1372 "$target_gen_dir/torque-generated/exported-macros-assembler.cc",
1373 "$target_gen_dir/torque-generated/exported-macros-assembler.h",
1374 "$target_gen_dir/torque-generated/csa-types.h",
1375 "$target_gen_dir/torque-generated/instance-types.h",
1376 "$target_gen_dir/torque-generated/runtime-macros.cc",
1377 "$target_gen_dir/torque-generated/runtime-macros.h",
1378 "$target_gen_dir/torque-generated/class-forward-declarations.h",
1379 ]
1380
1381 outputs = []
1382 foreach(file, files) {
1383 outputs += [ string_replace(file,
1384 "$target_gen_dir/torque-generated",
1385 destination_folder) ]
1386 }
1387
1388 foreach(file, torque_files) {
1389 filetq = string_replace(file, ".tq", "-tq")
1390 outputs += [
1391 "$target_gen_dir/torque-generated/$filetq-csa.cc",
1392 "$target_gen_dir/torque-generated/$filetq-csa.h",
1393 "$target_gen_dir/torque-generated/$filetq-inl.inc",
1394 "$target_gen_dir/torque-generated/$filetq.cc",
1395 "$target_gen_dir/torque-generated/$filetq.inc",
1396 ]
1397 }
1398
1399 args = [
1400 "./" + rebase_path(
1401 get_label_info(":torque($toolchain)", "root_out_dir") + "/torque",
1402 root_build_dir),
1403 "-o",
1404 rebase_path("$destination_folder", root_build_dir),
1405 "-v8-root",
1406 rebase_path(".", root_build_dir),
1407 ]
1408 if (defined(invoker.args)) {
1409 args += invoker.args
1410 }
1411 args += torque_files
Ben Murdochf91f0612016-11-29 16:50:11 +00001412 }
1413}
1414
Rubin Xu7bc1b612021-02-16 09:38:50 +00001415# Default run_torque action
1416run_torque("") {
1417 toolchain = v8_generator_toolchain
1418}
1419
1420if (v8_verify_torque_generation_invariance) {
1421 run_torque("x86") {
1422 toolchain = "//build/toolchain/linux:clang_x86"
1423 }
1424
1425 run_torque("x64") {
1426 args = [ "-m32" ]
1427 toolchain = "//build/toolchain/linux:clang_x64"
1428 }
1429
1430 action("compare_torque_runs") {
1431 deps = [
1432 ":run_torque_x64",
1433 ":run_torque_x86",
1434 ]
1435 report_file = "$target_gen_dir/torque_comparison_results.txt"
1436 script = "tools/compare_torque_output.py"
1437 args = [
1438 rebase_path("$target_gen_dir/torque-generated_x64", root_build_dir),
1439 rebase_path("$target_gen_dir/torque-generated_x86", root_build_dir),
1440 rebase_path(report_file, root_build_dir),
1441 ]
1442 outputs = [ report_file ]
1443 }
1444}
1445
1446group("v8_maybe_icu") {
1447 if (v8_enable_i18n_support) {
1448 public_deps = [ "//third_party/icu" ]
1449 }
1450}
1451
1452v8_source_set("torque_generated_initializers") {
Ben Murdochf91f0612016-11-29 16:50:11 +00001453 visibility = [ ":*" ] # Only targets in this file can depend on this.
1454
1455 deps = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00001456 ":generate_bytecode_builtins_list",
1457 ":run_torque",
1458 ":v8_tracing",
Ben Murdochf91f0612016-11-29 16:50:11 +00001459 ]
1460
Rubin Xu7bc1b612021-02-16 09:38:50 +00001461 public_deps = [ ":v8_maybe_icu" ]
1462
1463 sources = [
1464 "$target_gen_dir/torque-generated/csa-types.h",
1465 "$target_gen_dir/torque-generated/enum-verifiers.cc",
1466 "$target_gen_dir/torque-generated/exported-macros-assembler.cc",
1467 "$target_gen_dir/torque-generated/exported-macros-assembler.h",
1468 "src/torque/runtime-support.h",
1469 ]
1470 foreach(file, torque_files) {
1471 filetq = string_replace(file, ".tq", "-tq")
1472 sources += [
1473 "$target_gen_dir/torque-generated/$filetq-csa.cc",
1474 "$target_gen_dir/torque-generated/$filetq-csa.h",
1475 ]
1476 }
1477
1478 configs = [ ":internal_config" ]
1479}
1480
1481v8_source_set("torque_generated_definitions") {
1482 visibility = [ ":*" ] # Only targets in this file can depend on this.
1483
1484 deps = [
1485 ":generate_bytecode_builtins_list",
1486 ":run_torque",
1487 ":v8_tracing",
Ben Murdochf91f0612016-11-29 16:50:11 +00001488 ]
1489
Rubin Xu7bc1b612021-02-16 09:38:50 +00001490 public_deps = [ ":v8_maybe_icu" ]
Ben Murdochf91f0612016-11-29 16:50:11 +00001491
Rubin Xu7bc1b612021-02-16 09:38:50 +00001492 sources = [
1493 "$target_gen_dir/torque-generated/class-forward-declarations.h",
1494 "$target_gen_dir/torque-generated/class-verifiers.cc",
1495 "$target_gen_dir/torque-generated/class-verifiers.h",
1496 "$target_gen_dir/torque-generated/factory.cc",
1497 "$target_gen_dir/torque-generated/objects-printer.cc",
1498 "$target_gen_dir/torque-generated/runtime-macros.cc",
1499 ]
1500 foreach(file, torque_files) {
1501 filetq = string_replace(file, ".tq", "-tq")
1502 sources += [
1503 "$target_gen_dir/torque-generated/$filetq-inl.inc",
1504 "$target_gen_dir/torque-generated/$filetq.cc",
1505 "$target_gen_dir/torque-generated/$filetq.inc",
1506 ]
1507 }
1508
1509 configs = [ ":internal_config" ]
1510}
1511
1512action("generate_bytecode_builtins_list") {
Ben Murdochf91f0612016-11-29 16:50:11 +00001513 script = "tools/run.py"
Rubin Xu7bc1b612021-02-16 09:38:50 +00001514 outputs = [ "$target_gen_dir/builtins-generated/bytecodes-builtins-list.h" ]
1515 deps = [ ":bytecode_builtins_list_generator($v8_generator_toolchain)" ]
Ben Murdochf91f0612016-11-29 16:50:11 +00001516 args = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00001517 "./" + rebase_path(
1518 get_label_info(
1519 ":bytecode_builtins_list_generator($v8_generator_toolchain)",
1520 "root_out_dir") + "/bytecode_builtins_list_generator",
1521 root_build_dir),
1522 rebase_path("$target_gen_dir/builtins-generated/bytecodes-builtins-list.h",
1523 root_build_dir),
Ben Murdochf91f0612016-11-29 16:50:11 +00001524 ]
1525}
1526
Rubin Xu7bc1b612021-02-16 09:38:50 +00001527# Template to generate different V8 snapshots based on different runtime flags.
1528# Can be invoked with run_mksnapshot(<name>). The target will resolve to
1529# run_mksnapshot_<name>. If <name> is "default", no file suffixes will be used.
1530# Otherwise files are suffixed, e.g. embedded_<name>.S and
1531# snapshot_blob_<name>.bin.
1532#
1533# The template exposes the variables:
1534# args: additional flags for mksnapshots
1535# embedded_suffix: a camel case suffix for method names in the embedded
1536# snapshot.
1537template("run_mksnapshot") {
1538 name = target_name
1539 if (name == "default") {
1540 suffix = ""
1541 } else {
1542 suffix = "_$name"
1543 }
1544 action("run_mksnapshot_" + name) {
1545 # Only targets in this file and running mkgrokdump can depend on this.
1546 visibility = [
1547 ":*",
1548 "tools/debug_helper:run_mkgrokdump",
1549 ]
1550
1551 deps = [ ":mksnapshot($v8_snapshot_toolchain)" ]
1552
1553 script = "tools/run.py"
1554
1555 sources = []
1556
1557 outputs = []
1558
1559 data = []
1560
1561 args = [
1562 "./" + rebase_path(get_label_info(":mksnapshot($v8_snapshot_toolchain)",
1563 "root_out_dir") + "/mksnapshot",
1564 root_build_dir),
1565 "--turbo_instruction_scheduling",
1566
1567 # In cross builds, the snapshot may be generated for both the host and
1568 # target toolchains. The same host binary is used to generate both, so
1569 # mksnapshot needs to know which target OS to use at runtime. It's weird,
1570 # but the target OS is really |current_os|.
1571 "--target_os=$current_os",
1572 "--target_arch=$current_cpu",
1573
1574 "--embedded_src",
1575 rebase_path("$target_gen_dir/embedded${suffix}.S", root_build_dir),
1576 ]
1577
1578 if (v8_enable_builtins_profiling) {
1579 args += [ "--turbo-profiling" ]
1580 }
1581 if (v8_enable_builtins_profiling_verbose) {
1582 args += [ "--turbo-profiling-verbose" ]
1583 }
1584 if (v8_builtins_profiling_log_file != "") {
1585 sources += [ v8_builtins_profiling_log_file ]
1586 args += [
1587 "--turbo-profiling-log-file",
1588 rebase_path(v8_builtins_profiling_log_file, root_build_dir),
1589 ]
1590 }
1591
1592 # This is needed to distinguish between generating code for the simulator
1593 # and cross-compiling. The latter may need to run code on the host with the
1594 # simulator but cannot use simulator-specific instructions.
1595 if (target_is_simulator) {
1596 args += [ "--target_is_simulator" ]
1597 }
1598
1599 args += invoker.args
1600
1601 outputs += [ "$target_gen_dir/embedded${suffix}.S" ]
1602 if (invoker.embedded_variant != "") {
1603 args += [
1604 "--embedded_variant",
1605 invoker.embedded_variant,
1606 ]
1607 }
1608
1609 if (v8_random_seed != "0") {
1610 args += [
1611 "--random-seed",
1612 v8_random_seed,
1613 ]
1614 }
1615
1616 if (v8_os_page_size != "0") {
1617 args += [
1618 "--v8_os_page_size",
1619 v8_os_page_size,
1620 ]
1621 }
1622
1623 if (v8_use_external_startup_data) {
1624 outputs += [ "$root_out_dir/snapshot_blob${suffix}.bin" ]
1625 data += [ "$root_out_dir/snapshot_blob${suffix}.bin" ]
1626 args += [
1627 "--startup_blob",
1628 rebase_path("$root_out_dir/snapshot_blob${suffix}.bin", root_build_dir),
1629 ]
1630 } else {
1631 outputs += [ "$target_gen_dir/snapshot${suffix}.cc" ]
1632 args += [
1633 "--startup_src",
1634 rebase_path("$target_gen_dir/snapshot${suffix}.cc", root_build_dir),
1635 ]
1636 }
1637
1638 if (v8_embed_script != "") {
1639 sources += [ v8_embed_script ]
1640 args += [ rebase_path(v8_embed_script, root_build_dir) ]
1641 }
1642
1643 if (v8_enable_snapshot_code_comments) {
1644 args += [ "--code-comments" ]
1645 }
1646
1647 if (v8_enable_snapshot_native_code_counters) {
1648 args += [ "--native-code-counters" ]
1649 } else {
1650 # --native-code-counters is the default in debug mode so make sure we can
1651 # unset it.
1652 args += [ "--no-native-code-counters" ]
1653 }
1654
1655 if (v8_enable_fast_mksnapshot) {
1656 args += [
1657 "--no-turbo-rewrite-far-jumps",
1658 "--no-turbo-verify-allocation",
1659 ]
1660
1661 if (v8_enable_debugging_features && v8_enable_slow_dchecks) {
1662 # mksnapshot only accepts this flag if ENABLE_SLOW_DCHECKS is defined.
1663 args += [ "--no-enable-slow-asserts" ]
1664 }
1665 }
1666
1667 if (v8_enable_verify_heap) {
1668 args += [ "--verify-heap" ]
1669 }
1670 }
1671}
1672
1673run_mksnapshot("default") {
1674 args = []
1675 embedded_variant = "Default"
1676}
1677if (emit_builtins_as_inline_asm) {
1678 asm_to_inline_asm("default") {
1679 args = []
1680 }
1681}
1682if (v8_use_multi_snapshots) {
1683 run_mksnapshot("trusted") {
1684 args = [ "--no-untrusted-code-mitigations" ]
1685 embedded_variant = "Trusted"
1686 }
1687 if (emit_builtins_as_inline_asm) {
1688 asm_to_inline_asm("trusted") {
1689 args = []
1690 }
1691 }
1692}
1693
Ben Murdochf91f0612016-11-29 16:50:11 +00001694action("v8_dump_build_config") {
1695 script = "tools/testrunner/utils/dump_build_config.py"
Rubin Xu7bc1b612021-02-16 09:38:50 +00001696 outputs = [ "$root_out_dir/v8_build_config.json" ]
1697 is_gcov_coverage = v8_code_coverage && !is_clang
1698 is_full_debug = v8_enable_debugging_features && !v8_optimized_debug
Ben Murdochf91f0612016-11-29 16:50:11 +00001699 args = [
1700 rebase_path("$root_out_dir/v8_build_config.json", root_build_dir),
Ben Murdoch62ed6312017-06-06 11:06:27 +01001701 "current_cpu=\"$current_cpu\"",
Ben Murdochf91f0612016-11-29 16:50:11 +00001702 "dcheck_always_on=$dcheck_always_on",
Rubin Xu7bc1b612021-02-16 09:38:50 +00001703 "is_android=$is_android",
Ben Murdochf91f0612016-11-29 16:50:11 +00001704 "is_asan=$is_asan",
1705 "is_cfi=$is_cfi",
Rubin Xu7bc1b612021-02-16 09:38:50 +00001706 "is_clang=$is_clang",
Ben Murdochf91f0612016-11-29 16:50:11 +00001707 "is_component_build=$is_component_build",
Rubin Xu7bc1b612021-02-16 09:38:50 +00001708 "is_debug=$v8_enable_debugging_features",
1709 "is_full_debug=$is_full_debug",
1710 "is_gcov_coverage=$is_gcov_coverage",
Ben Murdochf91f0612016-11-29 16:50:11 +00001711 "is_msan=$is_msan",
1712 "is_tsan=$is_tsan",
Rubin Xu7bc1b612021-02-16 09:38:50 +00001713 "is_ubsan_vptr=$is_ubsan_vptr",
Ben Murdochf91f0612016-11-29 16:50:11 +00001714 "target_cpu=\"$target_cpu\"",
Ben Murdoch62ed6312017-06-06 11:06:27 +01001715 "v8_current_cpu=\"$v8_current_cpu\"",
Rubin Xu7bc1b612021-02-16 09:38:50 +00001716 "v8_enable_atomic_marking_state=$v8_enable_atomic_marking_state",
1717 "v8_enable_atomic_object_field_writes=" +
1718 "$v8_enable_atomic_object_field_writes",
1719 "v8_enable_concurrent_marking=$v8_enable_concurrent_marking",
Ben Murdochf91f0612016-11-29 16:50:11 +00001720 "v8_enable_i18n_support=$v8_enable_i18n_support",
Rubin Xu7bc1b612021-02-16 09:38:50 +00001721 "v8_enable_verify_predictable=$v8_enable_verify_predictable",
1722 "v8_enable_verify_csa=$v8_enable_verify_csa",
1723 "v8_enable_lite_mode=$v8_enable_lite_mode",
1724 "v8_enable_pointer_compression=$v8_enable_pointer_compression",
Ben Murdochf91f0612016-11-29 16:50:11 +00001725 "v8_target_cpu=\"$v8_target_cpu\"",
Ben Murdochf91f0612016-11-29 16:50:11 +00001726 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00001727
1728 if (v8_current_cpu == "mips" || v8_current_cpu == "mipsel" ||
1729 v8_current_cpu == "mips64" || v8_current_cpu == "mips64el") {
1730 args += [
1731 "mips_arch_variant=\"$mips_arch_variant\"",
1732 "mips_use_msa=$mips_use_msa",
1733 ]
1734 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001735}
1736
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001737###############################################################################
1738# Source Sets (aka static libraries)
1739#
1740
Ben Murdochbcf72ee2016-08-08 18:44:38 +01001741v8_source_set("v8_snapshot") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00001742 visibility = [ ":*" ] # Targets in this file can depend on this.
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001743
Rubin Xu7bc1b612021-02-16 09:38:50 +00001744 deps = []
Ben Murdoch014dc512016-03-22 12:00:34 +00001745 public_deps = [
1746 # This should be public so downstream targets can declare the snapshot
1747 # output file as their inputs.
Rubin Xu7bc1b612021-02-16 09:38:50 +00001748 ":run_mksnapshot_default",
1749 ]
1750
1751 # Do not publicize any header to remove build dependency.
1752 public = []
1753
1754 sources = [ "src/init/setup-isolate-deserialize.cc" ]
1755 if (v8_control_flow_integrity) {
1756 sources += [ "src/deoptimizer/deoptimizer-cfi-builtins.cc" ]
1757 }
1758 if (emit_builtins_as_inline_asm) {
1759 deps += [ ":asm_to_inline_asm_default" ]
1760 sources += [ "$target_gen_dir/embedded.cc" ]
1761 } else {
1762 sources += [ "$target_gen_dir/embedded.S" ]
1763 }
1764
1765 configs = [ ":internal_config" ]
1766
1767 if (v8_use_external_startup_data) {
1768 deps += [ ":v8_base" ]
1769
1770 sources += [ "src/snapshot/snapshot-external.cc" ]
1771
1772 if (v8_use_multi_snapshots) {
1773 public_deps += [ ":run_mksnapshot_trusted" ]
1774 if (emit_builtins_as_inline_asm) {
1775 deps += [ ":asm_to_inline_asm_trusted" ]
1776 sources += [ "$target_gen_dir/embedded_trusted.cc" ]
1777 } else {
1778 sources += [ "$target_gen_dir/embedded_trusted.S" ]
1779 }
1780 }
1781 } else {
1782 # Also top-level visibility targets can depend on this.
1783 visibility += [ "//:gn_visibility" ]
1784
1785 public_deps += [ ":v8_maybe_icu" ]
1786
1787 sources += [ "$target_gen_dir/snapshot.cc" ]
1788 }
1789}
1790
1791v8_source_set("v8_initializers") {
1792 visibility = [
1793 ":*",
1794 "test/cctest:*",
1795 ]
1796
1797 deps = [
1798 ":torque_generated_initializers",
1799 ":v8_tracing",
Ben Murdoch014dc512016-03-22 12:00:34 +00001800 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001801
1802 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00001803 ### gcmole(all) ###
1804 "src/builtins/builtins-array-gen.cc",
1805 "src/builtins/builtins-array-gen.h",
1806 "src/builtins/builtins-async-function-gen.cc",
1807 "src/builtins/builtins-async-gen.cc",
1808 "src/builtins/builtins-async-gen.h",
1809 "src/builtins/builtins-async-generator-gen.cc",
1810 "src/builtins/builtins-async-iterator-gen.cc",
1811 "src/builtins/builtins-bigint-gen.cc",
1812 "src/builtins/builtins-bigint-gen.h",
1813 "src/builtins/builtins-call-gen.cc",
1814 "src/builtins/builtins-call-gen.h",
1815 "src/builtins/builtins-collections-gen.cc",
1816 "src/builtins/builtins-constructor-gen.cc",
1817 "src/builtins/builtins-constructor-gen.h",
1818 "src/builtins/builtins-constructor.h",
1819 "src/builtins/builtins-conversion-gen.cc",
1820 "src/builtins/builtins-data-view-gen.h",
1821 "src/builtins/builtins-date-gen.cc",
1822 "src/builtins/builtins-debug-gen.cc",
1823 "src/builtins/builtins-generator-gen.cc",
1824 "src/builtins/builtins-global-gen.cc",
1825 "src/builtins/builtins-handler-gen.cc",
1826 "src/builtins/builtins-ic-gen.cc",
1827 "src/builtins/builtins-internal-gen.cc",
1828 "src/builtins/builtins-interpreter-gen.cc",
1829 "src/builtins/builtins-intl-gen.cc",
1830 "src/builtins/builtins-iterator-gen.cc",
1831 "src/builtins/builtins-iterator-gen.h",
1832 "src/builtins/builtins-lazy-gen.cc",
1833 "src/builtins/builtins-lazy-gen.h",
1834 "src/builtins/builtins-microtask-queue-gen.cc",
1835 "src/builtins/builtins-number-gen.cc",
1836 "src/builtins/builtins-object-gen.cc",
1837 "src/builtins/builtins-promise-gen.cc",
1838 "src/builtins/builtins-promise-gen.h",
1839 "src/builtins/builtins-proxy-gen.cc",
1840 "src/builtins/builtins-proxy-gen.h",
1841 "src/builtins/builtins-regexp-gen.cc",
1842 "src/builtins/builtins-regexp-gen.h",
1843 "src/builtins/builtins-sharedarraybuffer-gen.cc",
1844 "src/builtins/builtins-string-gen.cc",
1845 "src/builtins/builtins-string-gen.h",
1846 "src/builtins/builtins-typed-array-gen.cc",
1847 "src/builtins/builtins-typed-array-gen.h",
1848 "src/builtins/builtins-utils-gen.h",
1849 "src/builtins/builtins-wasm-gen.cc",
1850 "src/builtins/builtins-wasm-gen.h",
1851 "src/builtins/growable-fixed-array-gen.cc",
1852 "src/builtins/growable-fixed-array-gen.h",
1853 "src/builtins/profile-data-reader.cc",
1854 "src/builtins/profile-data-reader.h",
1855 "src/builtins/setup-builtins-internal.cc",
1856 "src/builtins/torque-csa-header-includes.h",
1857 "src/codegen/code-stub-assembler.cc",
1858 "src/codegen/code-stub-assembler.h",
1859 "src/heap/setup-heap-internal.cc",
1860 "src/ic/accessor-assembler.cc",
1861 "src/ic/accessor-assembler.h",
1862 "src/ic/binary-op-assembler.cc",
1863 "src/ic/binary-op-assembler.h",
1864 "src/ic/keyed-store-generic.cc",
1865 "src/ic/keyed-store-generic.h",
1866 "src/ic/unary-op-assembler.cc",
1867 "src/ic/unary-op-assembler.h",
1868 "src/interpreter/interpreter-assembler.cc",
1869 "src/interpreter/interpreter-assembler.h",
1870 "src/interpreter/interpreter-generator.cc",
1871 "src/interpreter/interpreter-generator.h",
1872 "src/interpreter/interpreter-intrinsics-generator.cc",
1873 "src/interpreter/interpreter-intrinsics-generator.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001874 ]
1875
Rubin Xu7bc1b612021-02-16 09:38:50 +00001876 if (v8_current_cpu == "x86") {
1877 sources += [
1878 ### gcmole(arch:ia32) ###
1879 "src/builtins/ia32/builtins-ia32.cc",
1880 ]
1881 } else if (v8_current_cpu == "x64") {
1882 sources += [
1883 ### gcmole(arch:x64) ###
1884 "src/builtins/x64/builtins-x64.cc",
1885 ]
1886 } else if (v8_current_cpu == "arm") {
1887 sources += [
1888 ### gcmole(arch:arm) ###
1889 "src/builtins/arm/builtins-arm.cc",
1890 ]
1891 } else if (v8_current_cpu == "arm64") {
1892 sources += [
1893 ### gcmole(arch:arm64) ###
1894 "src/builtins/arm64/builtins-arm64.cc",
1895 ]
1896 } else if (v8_current_cpu == "mips" || v8_current_cpu == "mipsel") {
1897 sources += [
1898 ### gcmole(arch:mipsel) ###
1899 "src/builtins/mips/builtins-mips.cc",
1900 ]
1901 } else if (v8_current_cpu == "mips64" || v8_current_cpu == "mips64el") {
1902 sources += [
1903 ### gcmole(arch:mips64el) ###
1904 "src/builtins/mips64/builtins-mips64.cc",
1905 ]
1906 } else if (v8_current_cpu == "ppc") {
1907 sources += [
1908 ### gcmole(arch:ppc) ###
1909 "src/builtins/ppc/builtins-ppc.cc",
1910 ]
1911 } else if (v8_current_cpu == "ppc64") {
1912 sources += [
1913 ### gcmole(arch:ppc64) ###
1914 "src/builtins/ppc/builtins-ppc.cc",
1915 ]
1916 } else if (v8_current_cpu == "s390" || v8_current_cpu == "s390x") {
1917 sources += [
1918 ### gcmole(arch:s390) ###
1919 "src/builtins/s390/builtins-s390.cc",
1920 ]
1921 }
1922
1923 if (!v8_enable_i18n_support) {
1924 sources -= [ "src/builtins/builtins-intl-gen.cc" ]
1925 }
1926
Ben Murdochbcf72ee2016-08-08 18:44:38 +01001927 configs = [ ":internal_config" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001928}
1929
Rubin Xu7bc1b612021-02-16 09:38:50 +00001930v8_source_set("v8_init") {
1931 visibility = [ ":*" ] # Only targets in this file can depend on this.
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001932
Rubin Xu7bc1b612021-02-16 09:38:50 +00001933 deps = [
1934 ":v8_initializers",
1935 ":v8_tracing",
1936 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001937
Rubin Xu7bc1b612021-02-16 09:38:50 +00001938 sources = [
1939 ### gcmole(all) ###
1940 "src/init/setup-isolate-full.cc",
1941 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001942
Rubin Xu7bc1b612021-02-16 09:38:50 +00001943 public_deps = [ ":v8_maybe_icu" ]
1944
1945 configs = [ ":internal_config" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001946}
1947
Ben Murdoch62ed6312017-06-06 11:06:27 +01001948# This is split out to be a non-code containing target that the Chromium browser
1949# DLL can depend upon to get only a version string.
1950v8_header_set("v8_version") {
1951 configs = [ ":internal_config" ]
1952
1953 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00001954 "include/v8-value-serializer-version.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01001955 "include/v8-version-string.h",
1956 "include/v8-version.h",
1957 ]
1958}
1959
Rubin Xu7bc1b612021-02-16 09:38:50 +00001960# This is split out to be a non-code containing target that the Chromium browser
1961# can depend upon to get basic v8 types.
1962v8_header_set("v8_headers") {
1963 configs = [ ":internal_config" ]
1964 public_configs = [ ":v8_header_features" ]
1965
1966 sources = [
1967 "include/v8-cppgc.h",
1968 "include/v8-fast-api-calls.h",
1969 "include/v8-internal.h",
1970 "include/v8.h",
1971 "include/v8config.h",
1972 ]
1973
1974 sources += [
1975 # The following headers cannot be platform-specific. The include validation
1976 # of `gn gen $dir --check` requires all header files to be available on all
1977 # platforms.
1978 "include/v8-wasm-trap-handler-posix.h",
1979 "include/v8-wasm-trap-handler-win.h",
1980 ]
1981
1982 deps = [ ":v8_version" ]
1983}
1984
1985# This is split out to share basic headers with Torque.
1986v8_header_set("v8_shared_internal_headers") {
Ben Murdochb8a8cc12014-11-26 15:28:44 +00001987 visibility = [ ":*" ] # Only targets in this file can depend on this.
Rubin Xu7bc1b612021-02-16 09:38:50 +00001988 configs = [ ":internal_config" ]
1989
1990 sources = [ "src/common/globals.h" ]
1991
1992 deps = [ ":v8_headers" ]
1993}
1994
1995v8_compiler_sources = [
1996 ### gcmole(all) ###
1997 "src/builtins/profile-data-reader.h",
1998 "src/compiler/access-builder.cc",
1999 "src/compiler/access-builder.h",
2000 "src/compiler/access-info.cc",
2001 "src/compiler/access-info.h",
2002 "src/compiler/add-type-assertions-reducer.cc",
2003 "src/compiler/add-type-assertions-reducer.h",
2004 "src/compiler/all-nodes.cc",
2005 "src/compiler/all-nodes.h",
2006 "src/compiler/allocation-builder-inl.h",
2007 "src/compiler/allocation-builder.h",
2008 "src/compiler/backend/code-generator-impl.h",
2009 "src/compiler/backend/code-generator.cc",
2010 "src/compiler/backend/code-generator.h",
2011 "src/compiler/backend/frame-elider.cc",
2012 "src/compiler/backend/frame-elider.h",
2013 "src/compiler/backend/gap-resolver.cc",
2014 "src/compiler/backend/gap-resolver.h",
2015 "src/compiler/backend/instruction-codes.h",
2016 "src/compiler/backend/instruction-scheduler.cc",
2017 "src/compiler/backend/instruction-scheduler.h",
2018 "src/compiler/backend/instruction-selector-impl.h",
2019 "src/compiler/backend/instruction-selector.cc",
2020 "src/compiler/backend/instruction-selector.h",
2021 "src/compiler/backend/instruction.cc",
2022 "src/compiler/backend/instruction.h",
2023 "src/compiler/backend/jump-threading.cc",
2024 "src/compiler/backend/jump-threading.h",
2025 "src/compiler/backend/mid-tier-register-allocator.cc",
2026 "src/compiler/backend/mid-tier-register-allocator.h",
2027 "src/compiler/backend/move-optimizer.cc",
2028 "src/compiler/backend/move-optimizer.h",
2029 "src/compiler/backend/register-allocation.h",
2030 "src/compiler/backend/register-allocator-verifier.cc",
2031 "src/compiler/backend/register-allocator-verifier.h",
2032 "src/compiler/backend/register-allocator.cc",
2033 "src/compiler/backend/register-allocator.h",
2034 "src/compiler/backend/spill-placer.cc",
2035 "src/compiler/backend/spill-placer.h",
2036 "src/compiler/backend/unwinding-info-writer.h",
2037 "src/compiler/basic-block-instrumentor.cc",
2038 "src/compiler/basic-block-instrumentor.h",
2039 "src/compiler/branch-elimination.cc",
2040 "src/compiler/branch-elimination.h",
2041 "src/compiler/bytecode-analysis.cc",
2042 "src/compiler/bytecode-analysis.h",
2043 "src/compiler/bytecode-graph-builder.cc",
2044 "src/compiler/bytecode-graph-builder.h",
2045 "src/compiler/bytecode-liveness-map.cc",
2046 "src/compiler/bytecode-liveness-map.h",
2047 "src/compiler/c-linkage.cc",
2048 "src/compiler/checkpoint-elimination.cc",
2049 "src/compiler/checkpoint-elimination.h",
2050 "src/compiler/code-assembler.cc",
2051 "src/compiler/code-assembler.h",
2052 "src/compiler/common-node-cache.cc",
2053 "src/compiler/common-node-cache.h",
2054 "src/compiler/common-operator-reducer.cc",
2055 "src/compiler/common-operator-reducer.h",
2056 "src/compiler/common-operator.cc",
2057 "src/compiler/common-operator.h",
2058 "src/compiler/compilation-dependencies.cc",
2059 "src/compiler/compilation-dependencies.h",
2060 "src/compiler/compiler-source-position-table.cc",
2061 "src/compiler/compiler-source-position-table.h",
2062 "src/compiler/constant-folding-reducer.cc",
2063 "src/compiler/constant-folding-reducer.h",
2064 "src/compiler/control-equivalence.cc",
2065 "src/compiler/control-equivalence.h",
2066 "src/compiler/control-flow-optimizer.cc",
2067 "src/compiler/control-flow-optimizer.h",
2068 "src/compiler/csa-load-elimination.cc",
2069 "src/compiler/csa-load-elimination.h",
2070 "src/compiler/dead-code-elimination.cc",
2071 "src/compiler/dead-code-elimination.h",
2072 "src/compiler/decompression-optimizer.cc",
2073 "src/compiler/decompression-optimizer.h",
2074 "src/compiler/diamond.h",
2075 "src/compiler/effect-control-linearizer.cc",
2076 "src/compiler/effect-control-linearizer.h",
2077 "src/compiler/escape-analysis-reducer.cc",
2078 "src/compiler/escape-analysis-reducer.h",
2079 "src/compiler/escape-analysis.cc",
2080 "src/compiler/escape-analysis.h",
2081 "src/compiler/feedback-source.cc",
2082 "src/compiler/feedback-source.h",
2083 "src/compiler/frame-states.cc",
2084 "src/compiler/frame-states.h",
2085 "src/compiler/frame.cc",
2086 "src/compiler/frame.h",
2087 "src/compiler/functional-list.h",
2088 "src/compiler/globals.h",
2089 "src/compiler/graph-assembler.cc",
2090 "src/compiler/graph-assembler.h",
2091 "src/compiler/graph-reducer.cc",
2092 "src/compiler/graph-reducer.h",
2093 "src/compiler/graph-trimmer.cc",
2094 "src/compiler/graph-trimmer.h",
2095 "src/compiler/graph-visualizer.cc",
2096 "src/compiler/graph-visualizer.h",
2097 "src/compiler/graph-zone-traits.h",
2098 "src/compiler/graph.cc",
2099 "src/compiler/graph.h",
2100 "src/compiler/int64-lowering.cc",
2101 "src/compiler/int64-lowering.h",
2102 "src/compiler/js-call-reducer.cc",
2103 "src/compiler/js-call-reducer.h",
2104 "src/compiler/js-context-specialization.cc",
2105 "src/compiler/js-context-specialization.h",
2106 "src/compiler/js-create-lowering.cc",
2107 "src/compiler/js-create-lowering.h",
2108 "src/compiler/js-generic-lowering.cc",
2109 "src/compiler/js-generic-lowering.h",
2110 "src/compiler/js-graph.cc",
2111 "src/compiler/js-graph.h",
2112 "src/compiler/js-heap-broker.cc",
2113 "src/compiler/js-heap-broker.h",
2114 "src/compiler/js-heap-copy-reducer.cc",
2115 "src/compiler/js-heap-copy-reducer.h",
2116 "src/compiler/js-inlining-heuristic.cc",
2117 "src/compiler/js-inlining-heuristic.h",
2118 "src/compiler/js-inlining.cc",
2119 "src/compiler/js-inlining.h",
2120 "src/compiler/js-intrinsic-lowering.cc",
2121 "src/compiler/js-intrinsic-lowering.h",
2122 "src/compiler/js-native-context-specialization.cc",
2123 "src/compiler/js-native-context-specialization.h",
2124 "src/compiler/js-operator.cc",
2125 "src/compiler/js-operator.h",
2126 "src/compiler/js-type-hint-lowering.cc",
2127 "src/compiler/js-type-hint-lowering.h",
2128 "src/compiler/js-typed-lowering.cc",
2129 "src/compiler/js-typed-lowering.h",
2130 "src/compiler/linkage.cc",
2131 "src/compiler/linkage.h",
2132 "src/compiler/load-elimination.cc",
2133 "src/compiler/load-elimination.h",
2134 "src/compiler/loop-analysis.cc",
2135 "src/compiler/loop-analysis.h",
2136 "src/compiler/loop-peeling.cc",
2137 "src/compiler/loop-peeling.h",
2138 "src/compiler/loop-variable-optimizer.cc",
2139 "src/compiler/loop-variable-optimizer.h",
2140 "src/compiler/machine-graph-verifier.cc",
2141 "src/compiler/machine-graph-verifier.h",
2142 "src/compiler/machine-graph.cc",
2143 "src/compiler/machine-graph.h",
2144 "src/compiler/machine-operator-reducer.cc",
2145 "src/compiler/machine-operator-reducer.h",
2146 "src/compiler/machine-operator.cc",
2147 "src/compiler/machine-operator.h",
2148 "src/compiler/map-inference.cc",
2149 "src/compiler/map-inference.h",
2150 "src/compiler/memory-lowering.cc",
2151 "src/compiler/memory-lowering.h",
2152 "src/compiler/memory-optimizer.cc",
2153 "src/compiler/memory-optimizer.h",
2154 "src/compiler/node-aux-data.h",
2155 "src/compiler/node-cache.h",
2156 "src/compiler/node-marker.cc",
2157 "src/compiler/node-marker.h",
2158 "src/compiler/node-matchers.cc",
2159 "src/compiler/node-matchers.h",
2160 "src/compiler/node-origin-table.cc",
2161 "src/compiler/node-origin-table.h",
2162 "src/compiler/node-properties.cc",
2163 "src/compiler/node-properties.h",
2164 "src/compiler/node.cc",
2165 "src/compiler/node.h",
2166 "src/compiler/opcodes.cc",
2167 "src/compiler/opcodes.h",
2168 "src/compiler/operation-typer.cc",
2169 "src/compiler/operation-typer.h",
2170 "src/compiler/operator-properties.cc",
2171 "src/compiler/operator-properties.h",
2172 "src/compiler/operator.cc",
2173 "src/compiler/operator.h",
2174 "src/compiler/osr.cc",
2175 "src/compiler/osr.h",
2176 "src/compiler/per-isolate-compiler-cache.h",
2177 "src/compiler/persistent-map.h",
2178 "src/compiler/pipeline-statistics.cc",
2179 "src/compiler/pipeline-statistics.h",
2180 "src/compiler/pipeline.cc",
2181 "src/compiler/pipeline.h",
2182 "src/compiler/property-access-builder.cc",
2183 "src/compiler/property-access-builder.h",
2184 "src/compiler/raw-machine-assembler.cc",
2185 "src/compiler/raw-machine-assembler.h",
2186 "src/compiler/redundancy-elimination.cc",
2187 "src/compiler/redundancy-elimination.h",
2188 "src/compiler/refs-map.cc",
2189 "src/compiler/refs-map.h",
2190 "src/compiler/representation-change.cc",
2191 "src/compiler/representation-change.h",
2192 "src/compiler/schedule.cc",
2193 "src/compiler/schedule.h",
2194 "src/compiler/scheduled-machine-lowering.cc",
2195 "src/compiler/scheduled-machine-lowering.h",
2196 "src/compiler/scheduler.cc",
2197 "src/compiler/scheduler.h",
2198 "src/compiler/select-lowering.cc",
2199 "src/compiler/select-lowering.h",
2200 "src/compiler/serializer-for-background-compilation.cc",
2201 "src/compiler/serializer-for-background-compilation.h",
2202 "src/compiler/serializer-hints.h",
2203 "src/compiler/simd-scalar-lowering.cc",
2204 "src/compiler/simd-scalar-lowering.h",
2205 "src/compiler/simplified-lowering.cc",
2206 "src/compiler/simplified-lowering.h",
2207 "src/compiler/simplified-operator-reducer.cc",
2208 "src/compiler/simplified-operator-reducer.h",
2209 "src/compiler/simplified-operator.cc",
2210 "src/compiler/simplified-operator.h",
2211 "src/compiler/state-values-utils.cc",
2212 "src/compiler/state-values-utils.h",
2213 "src/compiler/store-store-elimination.cc",
2214 "src/compiler/store-store-elimination.h",
2215 "src/compiler/type-cache.cc",
2216 "src/compiler/type-cache.h",
2217 "src/compiler/type-narrowing-reducer.cc",
2218 "src/compiler/type-narrowing-reducer.h",
2219 "src/compiler/typed-optimization.cc",
2220 "src/compiler/typed-optimization.h",
2221 "src/compiler/typer.cc",
2222 "src/compiler/typer.h",
2223 "src/compiler/types.cc",
2224 "src/compiler/types.h",
2225 "src/compiler/value-numbering-reducer.cc",
2226 "src/compiler/value-numbering-reducer.h",
2227 "src/compiler/verifier.cc",
2228 "src/compiler/verifier.h",
2229 "src/compiler/wasm-compiler.cc",
2230 "src/compiler/wasm-compiler.h",
2231 "src/compiler/write-barrier-kind.h",
2232 "src/compiler/zone-stats.cc",
2233 "src/compiler/zone-stats.h",
2234]
2235
2236# The src/compiler files with optimizations.
2237v8_source_set("v8_compiler_opt") {
2238 visibility = [ ":*" ] # Only targets in this file can depend on this.
2239
2240 sources = v8_compiler_sources
2241
2242 public_deps = [
2243 ":generate_bytecode_builtins_list",
2244 ":run_torque",
2245 ":v8_maybe_icu",
2246 ":v8_tracing",
2247 ]
2248
2249 if (is_debug && !v8_optimized_debug && v8_enable_fast_mksnapshot) {
2250 # The :no_optimize config is added to v8_add_configs in v8.gni.
2251 remove_configs = [ "//build/config/compiler:no_optimize" ]
2252 configs = [ ":always_optimize" ]
2253 } else {
2254 # Without this else branch, gn fails to generate build files for non-debug
2255 # builds (because we try to remove a config that is not present).
2256 # So we include it, even if this config is not used outside of debug builds.
2257 configs = [ ":internal_config" ]
2258 }
2259}
2260
2261# The src/compiler files with default optimization behavior.
2262v8_source_set("v8_compiler") {
2263 visibility = [ ":*" ] # Only targets in this file can depend on this.
2264
2265 sources = v8_compiler_sources
2266
2267 public_deps = [
2268 ":generate_bytecode_builtins_list",
2269 ":run_torque",
2270 ":v8_maybe_icu",
2271 ":v8_tracing",
2272 ]
2273
2274 configs = [ ":internal_config" ]
2275}
2276
2277group("v8_compiler_for_mksnapshot") {
2278 if (is_debug && !v8_optimized_debug && v8_enable_fast_mksnapshot) {
2279 deps = [ ":v8_compiler_opt" ]
2280 } else {
2281 deps = [ ":v8_compiler" ]
2282 }
2283}
2284
2285# Any target using trace events must directly or indirectly depend on
2286# v8_tracing.
2287group("v8_tracing") {
2288 if (v8_use_perfetto) {
2289 if (build_with_chromium) {
2290 public_deps = [ "//third_party/perfetto:libperfetto" ]
2291 } else {
2292 public_deps = [ ":v8_libperfetto" ]
2293 }
2294 }
2295}
2296
2297v8_source_set("v8_base_without_compiler") {
2298 visibility = [ ":*" ] # Only targets in this file can depend on this.
2299
2300 # Split static libraries on windows into two.
2301 split_count = 2
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002302
2303 sources = [
Ben Murdoch13e2dad2016-09-16 13:49:30 +01002304 "//base/trace_event/common/trace_event_common.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00002305
2306 ### gcmole(all) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00002307 "$target_gen_dir/builtins-generated/bytecodes-builtins-list.h",
2308 "include/cppgc/common.h",
2309 "include/v8-cppgc.h",
2310 "include/v8-fast-api-calls.h",
2311 "include/v8-inspector-protocol.h",
2312 "include/v8-inspector.h",
2313 "include/v8-internal.h",
2314 "include/v8-metrics.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002315 "include/v8-platform.h",
2316 "include/v8-profiler.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002317 "include/v8-unwinder-state.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002318 "include/v8-util.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002319 "include/v8-wasm-trap-handler-posix.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002320 "include/v8.h",
2321 "include/v8config.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002322 "src/api/api-arguments-inl.h",
2323 "src/api/api-arguments.cc",
2324 "src/api/api-arguments.h",
2325 "src/api/api-natives.cc",
2326 "src/api/api-natives.h",
2327 "src/api/api.cc",
2328 "src/api/api.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002329 "src/asmjs/asm-js.cc",
2330 "src/asmjs/asm-js.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002331 "src/asmjs/asm-names.h",
2332 "src/asmjs/asm-parser.cc",
2333 "src/asmjs/asm-parser.h",
2334 "src/asmjs/asm-scanner.cc",
2335 "src/asmjs/asm-scanner.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002336 "src/asmjs/asm-types.cc",
2337 "src/asmjs/asm-types.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002338 "src/ast/ast-function-literal-id-reindexer.cc",
2339 "src/ast/ast-function-literal-id-reindexer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002340 "src/ast/ast-source-ranges.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002341 "src/ast/ast-traversal-visitor.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002342 "src/ast/ast-value-factory.cc",
2343 "src/ast/ast-value-factory.h",
2344 "src/ast/ast.cc",
2345 "src/ast/ast.h",
2346 "src/ast/modules.cc",
2347 "src/ast/modules.h",
2348 "src/ast/prettyprinter.cc",
2349 "src/ast/prettyprinter.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002350 "src/ast/scopes.cc",
2351 "src/ast/scopes.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002352 "src/ast/source-range-ast-visitor.cc",
2353 "src/ast/source-range-ast-visitor.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002354 "src/ast/variables.cc",
2355 "src/ast/variables.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002356 "src/builtins/accessors.cc",
2357 "src/builtins/accessors.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002358 "src/builtins/builtins-api.cc",
2359 "src/builtins/builtins-array.cc",
2360 "src/builtins/builtins-arraybuffer.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002361 "src/builtins/builtins-async-module.cc",
2362 "src/builtins/builtins-bigint.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002363 "src/builtins/builtins-callsite.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002364 "src/builtins/builtins-collections.cc",
2365 "src/builtins/builtins-console.cc",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002366 "src/builtins/builtins-constructor.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002367 "src/builtins/builtins-dataview.cc",
2368 "src/builtins/builtins-date.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002369 "src/builtins/builtins-definitions.h",
2370 "src/builtins/builtins-descriptors.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002371 "src/builtins/builtins-error.cc",
2372 "src/builtins/builtins-function.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002373 "src/builtins/builtins-global.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002374 "src/builtins/builtins-internal.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002375 "src/builtins/builtins-intl.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002376 "src/builtins/builtins-json.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002377 "src/builtins/builtins-number.cc",
2378 "src/builtins/builtins-object.cc",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002379 "src/builtins/builtins-promise.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002380 "src/builtins/builtins-reflect.cc",
Ben Murdochf3b273f2017-01-17 12:11:28 +00002381 "src/builtins/builtins-regexp.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002382 "src/builtins/builtins-sharedarraybuffer.cc",
2383 "src/builtins/builtins-string.cc",
2384 "src/builtins/builtins-symbol.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002385 "src/builtins/builtins-trace.cc",
2386 "src/builtins/builtins-typed-array.cc",
2387 "src/builtins/builtins-utils-inl.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002388 "src/builtins/builtins-utils.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002389 "src/builtins/builtins-weak-refs.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002390 "src/builtins/builtins.cc",
2391 "src/builtins/builtins.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002392 "src/builtins/constants-table-builder.cc",
2393 "src/builtins/constants-table-builder.h",
2394 "src/builtins/profile-data-reader.h",
2395 "src/codegen/assembler-arch.h",
2396 "src/codegen/assembler-inl.h",
2397 "src/codegen/assembler.cc",
2398 "src/codegen/assembler.h",
2399 "src/codegen/bailout-reason.cc",
2400 "src/codegen/bailout-reason.h",
2401 "src/codegen/callable.h",
2402 "src/codegen/code-comments.cc",
2403 "src/codegen/code-comments.h",
2404 "src/codegen/code-desc.cc",
2405 "src/codegen/code-desc.h",
2406 "src/codegen/code-factory.cc",
2407 "src/codegen/code-factory.h",
2408 "src/codegen/code-reference.cc",
2409 "src/codegen/code-reference.h",
2410 "src/codegen/compilation-cache.cc",
2411 "src/codegen/compilation-cache.h",
2412 "src/codegen/compiler.cc",
2413 "src/codegen/compiler.h",
2414 "src/codegen/constant-pool.cc",
2415 "src/codegen/constant-pool.h",
2416 "src/codegen/constants-arch.h",
2417 "src/codegen/cpu-features.h",
2418 "src/codegen/external-reference-encoder.cc",
2419 "src/codegen/external-reference-encoder.h",
2420 "src/codegen/external-reference-table.cc",
2421 "src/codegen/external-reference-table.h",
2422 "src/codegen/external-reference.cc",
2423 "src/codegen/external-reference.h",
2424 "src/codegen/flush-instruction-cache.cc",
2425 "src/codegen/flush-instruction-cache.h",
2426 "src/codegen/handler-table.cc",
2427 "src/codegen/handler-table.h",
2428 "src/codegen/interface-descriptors.cc",
2429 "src/codegen/interface-descriptors.h",
2430 "src/codegen/label.h",
2431 "src/codegen/machine-type.cc",
2432 "src/codegen/machine-type.h",
2433 "src/codegen/macro-assembler-inl.h",
2434 "src/codegen/macro-assembler.h",
2435 "src/codegen/optimized-compilation-info.cc",
2436 "src/codegen/optimized-compilation-info.h",
2437 "src/codegen/pending-optimization-table.cc",
2438 "src/codegen/pending-optimization-table.h",
2439 "src/codegen/register-arch.h",
2440 "src/codegen/register-configuration.cc",
2441 "src/codegen/register-configuration.h",
2442 "src/codegen/register.cc",
2443 "src/codegen/register.h",
2444 "src/codegen/reglist.h",
2445 "src/codegen/reloc-info.cc",
2446 "src/codegen/reloc-info.h",
2447 "src/codegen/safepoint-table.cc",
2448 "src/codegen/safepoint-table.h",
2449 "src/codegen/signature.h",
2450 "src/codegen/source-position-table.cc",
2451 "src/codegen/source-position-table.h",
2452 "src/codegen/source-position.cc",
2453 "src/codegen/source-position.h",
2454 "src/codegen/string-constants.cc",
2455 "src/codegen/string-constants.h",
2456 "src/codegen/tick-counter.cc",
2457 "src/codegen/tick-counter.h",
2458 "src/codegen/tnode.cc",
2459 "src/codegen/tnode.h",
2460 "src/codegen/turbo-assembler.cc",
2461 "src/codegen/turbo-assembler.h",
2462 "src/codegen/unoptimized-compilation-info.cc",
2463 "src/codegen/unoptimized-compilation-info.h",
2464 "src/common/assert-scope.cc",
2465 "src/common/assert-scope.h",
2466 "src/common/checks.h",
2467 "src/common/external-pointer-inl.h",
2468 "src/common/external-pointer.h",
2469 "src/common/message-template.h",
2470 "src/common/ptr-compr-inl.h",
2471 "src/common/ptr-compr.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002472 "src/compiler-dispatcher/compiler-dispatcher.cc",
2473 "src/compiler-dispatcher/compiler-dispatcher.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002474 "src/compiler-dispatcher/optimizing-compile-dispatcher.cc",
2475 "src/compiler-dispatcher/optimizing-compile-dispatcher.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002476 "src/date/date.cc",
2477 "src/date/date.h",
2478 "src/date/dateparser-inl.h",
2479 "src/date/dateparser.cc",
2480 "src/date/dateparser.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002481 "src/debug/debug-coverage.cc",
2482 "src/debug/debug-coverage.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002483 "src/debug/debug-evaluate.cc",
2484 "src/debug/debug-evaluate.h",
2485 "src/debug/debug-frames.cc",
2486 "src/debug/debug-frames.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00002487 "src/debug/debug-interface.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002488 "src/debug/debug-property-iterator.cc",
2489 "src/debug/debug-property-iterator.h",
2490 "src/debug/debug-scope-iterator.cc",
2491 "src/debug/debug-scope-iterator.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002492 "src/debug/debug-scopes.cc",
2493 "src/debug/debug-scopes.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002494 "src/debug/debug-stack-trace-iterator.cc",
2495 "src/debug/debug-stack-trace-iterator.h",
2496 "src/debug/debug-type-profile.cc",
2497 "src/debug/debug-type-profile.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002498 "src/debug/debug.cc",
2499 "src/debug/debug.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002500 "src/debug/interface-types.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002501 "src/debug/liveedit.cc",
2502 "src/debug/liveedit.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002503 "src/deoptimizer/deoptimize-reason.cc",
2504 "src/deoptimizer/deoptimize-reason.h",
2505 "src/deoptimizer/deoptimizer.cc",
2506 "src/deoptimizer/deoptimizer.h",
2507 "src/diagnostics/basic-block-profiler.cc",
2508 "src/diagnostics/basic-block-profiler.h",
2509 "src/diagnostics/code-tracer.h",
2510 "src/diagnostics/compilation-statistics.cc",
2511 "src/diagnostics/compilation-statistics.h",
2512 "src/diagnostics/disasm.h",
2513 "src/diagnostics/disassembler.cc",
2514 "src/diagnostics/disassembler.h",
2515 "src/diagnostics/eh-frame.cc",
2516 "src/diagnostics/eh-frame.h",
2517 "src/diagnostics/gdb-jit.cc",
2518 "src/diagnostics/gdb-jit.h",
2519 "src/diagnostics/objects-debug.cc",
2520 "src/diagnostics/objects-printer.cc",
2521 "src/diagnostics/perf-jit.cc",
2522 "src/diagnostics/perf-jit.h",
2523 "src/diagnostics/unwinder.cc",
2524 "src/diagnostics/unwinder.h",
2525 "src/execution/arguments-inl.h",
2526 "src/execution/arguments.cc",
2527 "src/execution/arguments.h",
2528 "src/execution/execution.cc",
2529 "src/execution/execution.h",
2530 "src/execution/external-pointer-table.cc",
2531 "src/execution/external-pointer-table.h",
2532 "src/execution/frame-constants.h",
2533 "src/execution/frames-inl.h",
2534 "src/execution/frames.cc",
2535 "src/execution/frames.h",
2536 "src/execution/futex-emulation.cc",
2537 "src/execution/futex-emulation.h",
2538 "src/execution/interrupts-scope.cc",
2539 "src/execution/interrupts-scope.h",
2540 "src/execution/isolate-data.h",
2541 "src/execution/isolate-inl.h",
2542 "src/execution/isolate-utils.h",
2543 "src/execution/isolate.cc",
2544 "src/execution/isolate.h",
2545 "src/execution/local-isolate-inl.h",
2546 "src/execution/local-isolate.cc",
2547 "src/execution/local-isolate.h",
2548 "src/execution/messages.cc",
2549 "src/execution/messages.h",
2550 "src/execution/microtask-queue.cc",
2551 "src/execution/microtask-queue.h",
2552 "src/execution/pointer-authentication.h",
2553 "src/execution/protectors-inl.h",
2554 "src/execution/protectors.cc",
2555 "src/execution/protectors.h",
2556 "src/execution/runtime-profiler.cc",
2557 "src/execution/runtime-profiler.h",
2558 "src/execution/simulator-base.cc",
2559 "src/execution/simulator-base.h",
2560 "src/execution/simulator.h",
2561 "src/execution/stack-guard.cc",
2562 "src/execution/stack-guard.h",
2563 "src/execution/thread-id.cc",
2564 "src/execution/thread-id.h",
2565 "src/execution/thread-local-top.cc",
2566 "src/execution/thread-local-top.h",
2567 "src/execution/v8threads.cc",
2568 "src/execution/v8threads.h",
2569 "src/execution/vm-state-inl.h",
2570 "src/execution/vm-state.h",
2571 "src/extensions/cputracemark-extension.cc",
2572 "src/extensions/cputracemark-extension.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002573 "src/extensions/externalize-string-extension.cc",
2574 "src/extensions/externalize-string-extension.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002575 "src/extensions/gc-extension.cc",
2576 "src/extensions/gc-extension.h",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01002577 "src/extensions/ignition-statistics-extension.cc",
2578 "src/extensions/ignition-statistics-extension.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002579 "src/extensions/statistics-extension.cc",
2580 "src/extensions/statistics-extension.h",
2581 "src/extensions/trigger-failure-extension.cc",
2582 "src/extensions/trigger-failure-extension.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002583 "src/flags/flag-definitions.h",
2584 "src/flags/flags.cc",
2585 "src/flags/flags.h",
2586 "src/handles/global-handles.cc",
2587 "src/handles/global-handles.h",
2588 "src/handles/handles-inl.h",
2589 "src/handles/handles.cc",
2590 "src/handles/handles.h",
2591 "src/handles/local-handles-inl.h",
2592 "src/handles/local-handles.cc",
2593 "src/handles/local-handles.h",
2594 "src/handles/maybe-handles-inl.h",
2595 "src/handles/maybe-handles.h",
2596 "src/handles/persistent-handles.cc",
2597 "src/handles/persistent-handles.h",
2598 "src/heap/allocation-observer.cc",
2599 "src/heap/allocation-observer.h",
2600 "src/heap/allocation-stats.h",
2601 "src/heap/array-buffer-sweeper.cc",
2602 "src/heap/array-buffer-sweeper.h",
2603 "src/heap/barrier.h",
2604 "src/heap/base-space.cc",
2605 "src/heap/base-space.h",
2606 "src/heap/basic-memory-chunk.cc",
2607 "src/heap/basic-memory-chunk.h",
2608 "src/heap/code-object-registry.cc",
2609 "src/heap/code-object-registry.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002610 "src/heap/code-stats.cc",
2611 "src/heap/code-stats.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002612 "src/heap/collection-barrier.cc",
2613 "src/heap/collection-barrier.h",
2614 "src/heap/combined-heap.cc",
2615 "src/heap/combined-heap.h",
2616 "src/heap/concurrent-allocator-inl.h",
2617 "src/heap/concurrent-allocator.cc",
2618 "src/heap/concurrent-allocator.h",
2619 "src/heap/concurrent-marking.cc",
2620 "src/heap/concurrent-marking.h",
2621 "src/heap/cppgc-js/cpp-heap.cc",
2622 "src/heap/cppgc-js/cpp-heap.h",
2623 "src/heap/cppgc-js/cpp-snapshot.cc",
2624 "src/heap/cppgc-js/cpp-snapshot.h",
2625 "src/heap/cppgc-js/unified-heap-marking-state.h",
2626 "src/heap/cppgc-js/unified-heap-marking-verifier.cc",
2627 "src/heap/cppgc-js/unified-heap-marking-verifier.h",
2628 "src/heap/cppgc-js/unified-heap-marking-visitor.cc",
2629 "src/heap/cppgc-js/unified-heap-marking-visitor.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002630 "src/heap/embedder-tracing.cc",
2631 "src/heap/embedder-tracing.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002632 "src/heap/factory-base.cc",
2633 "src/heap/factory-base.h",
2634 "src/heap/factory-inl.h",
2635 "src/heap/factory.cc",
2636 "src/heap/factory.h",
2637 "src/heap/finalization-registry-cleanup-task.cc",
2638 "src/heap/finalization-registry-cleanup-task.h",
2639 "src/heap/free-list-inl.h",
2640 "src/heap/free-list.cc",
2641 "src/heap/free-list.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002642 "src/heap/gc-idle-time-handler.cc",
2643 "src/heap/gc-idle-time-handler.h",
2644 "src/heap/gc-tracer.cc",
2645 "src/heap/gc-tracer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002646 "src/heap/heap-controller.cc",
2647 "src/heap/heap-controller.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002648 "src/heap/heap-inl.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002649 "src/heap/heap-write-barrier-inl.h",
2650 "src/heap/heap-write-barrier.cc",
2651 "src/heap/heap-write-barrier.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002652 "src/heap/heap.cc",
2653 "src/heap/heap.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00002654 "src/heap/incremental-marking-inl.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002655 "src/heap/incremental-marking-job.cc",
2656 "src/heap/incremental-marking-job.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002657 "src/heap/incremental-marking.cc",
2658 "src/heap/incremental-marking.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002659 "src/heap/index-generator.cc",
2660 "src/heap/index-generator.h",
2661 "src/heap/invalidated-slots-inl.h",
2662 "src/heap/invalidated-slots.cc",
2663 "src/heap/invalidated-slots.h",
2664 "src/heap/item-parallel-job.cc",
2665 "src/heap/item-parallel-job.h",
2666 "src/heap/large-spaces.cc",
2667 "src/heap/large-spaces.h",
2668 "src/heap/list.h",
2669 "src/heap/local-allocator-inl.h",
2670 "src/heap/local-allocator.h",
2671 "src/heap/local-factory.cc",
2672 "src/heap/local-factory.h",
2673 "src/heap/local-heap-inl.h",
2674 "src/heap/local-heap.cc",
2675 "src/heap/local-heap.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002676 "src/heap/mark-compact-inl.h",
2677 "src/heap/mark-compact.cc",
2678 "src/heap/mark-compact.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002679 "src/heap/marking-barrier.cc",
2680 "src/heap/marking-barrier.h",
2681 "src/heap/marking-visitor-inl.h",
2682 "src/heap/marking-visitor.h",
2683 "src/heap/marking-worklist-inl.h",
2684 "src/heap/marking-worklist.cc",
2685 "src/heap/marking-worklist.h",
2686 "src/heap/marking.cc",
Ben Murdochf91f0612016-11-29 16:50:11 +00002687 "src/heap/marking.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002688 "src/heap/memory-allocator.cc",
2689 "src/heap/memory-allocator.h",
2690 "src/heap/memory-chunk-inl.h",
2691 "src/heap/memory-chunk-layout.cc",
2692 "src/heap/memory-chunk-layout.h",
2693 "src/heap/memory-chunk.cc",
2694 "src/heap/memory-chunk.h",
2695 "src/heap/memory-measurement-inl.h",
2696 "src/heap/memory-measurement.cc",
2697 "src/heap/memory-measurement.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002698 "src/heap/memory-reducer.cc",
2699 "src/heap/memory-reducer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002700 "src/heap/new-spaces-inl.h",
2701 "src/heap/new-spaces.cc",
2702 "src/heap/new-spaces.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002703 "src/heap/object-stats.cc",
2704 "src/heap/object-stats.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002705 "src/heap/objects-visiting-inl.h",
2706 "src/heap/objects-visiting.cc",
2707 "src/heap/objects-visiting.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002708 "src/heap/paged-spaces-inl.h",
2709 "src/heap/paged-spaces.cc",
2710 "src/heap/paged-spaces.h",
2711 "src/heap/parallel-work-item.h",
2712 "src/heap/read-only-heap-inl.h",
2713 "src/heap/read-only-heap.cc",
2714 "src/heap/read-only-heap.h",
2715 "src/heap/read-only-spaces.cc",
2716 "src/heap/read-only-spaces.h",
2717 "src/heap/remembered-set-inl.h",
Ben Murdoch109988c2016-05-18 11:27:45 +01002718 "src/heap/remembered-set.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002719 "src/heap/safepoint.cc",
2720 "src/heap/safepoint.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002721 "src/heap/scavenge-job.cc",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01002722 "src/heap/scavenge-job.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002723 "src/heap/scavenger-inl.h",
2724 "src/heap/scavenger.cc",
2725 "src/heap/scavenger.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002726 "src/heap/slot-set.cc",
Ben Murdoch109988c2016-05-18 11:27:45 +01002727 "src/heap/slot-set.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002728 "src/heap/spaces-inl.h",
2729 "src/heap/spaces.cc",
2730 "src/heap/spaces.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002731 "src/heap/stress-marking-observer.cc",
2732 "src/heap/stress-marking-observer.h",
2733 "src/heap/stress-scavenge-observer.cc",
2734 "src/heap/stress-scavenge-observer.h",
2735 "src/heap/sweeper.cc",
2736 "src/heap/sweeper.h",
2737 "src/heap/weak-object-worklists.cc",
2738 "src/heap/weak-object-worklists.h",
2739 "src/heap/worklist.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002740 "src/ic/call-optimization.cc",
2741 "src/ic/call-optimization.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00002742 "src/ic/handler-configuration-inl.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002743 "src/ic/handler-configuration.cc",
Ben Murdochf3b273f2017-01-17 12:11:28 +00002744 "src/ic/handler-configuration.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002745 "src/ic/ic-inl.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002746 "src/ic/ic-stats.cc",
2747 "src/ic/ic-stats.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002748 "src/ic/ic.cc",
2749 "src/ic/ic.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00002750 "src/ic/stub-cache.cc",
2751 "src/ic/stub-cache.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002752 "src/init/bootstrapper.cc",
2753 "src/init/bootstrapper.h",
2754 "src/init/heap-symbols.h",
2755 "src/init/icu_util.cc",
2756 "src/init/icu_util.h",
2757 "src/init/isolate-allocator.cc",
2758 "src/init/isolate-allocator.h",
2759 "src/init/setup-isolate.h",
2760 "src/init/startup-data-util.cc",
2761 "src/init/startup-data-util.h",
2762 "src/init/v8.cc",
2763 "src/init/v8.h",
2764 "src/interpreter/block-coverage-builder.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002765 "src/interpreter/bytecode-array-accessor.cc",
2766 "src/interpreter/bytecode-array-accessor.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002767 "src/interpreter/bytecode-array-builder.cc",
2768 "src/interpreter/bytecode-array-builder.h",
2769 "src/interpreter/bytecode-array-iterator.cc",
2770 "src/interpreter/bytecode-array-iterator.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002771 "src/interpreter/bytecode-array-random-iterator.cc",
2772 "src/interpreter/bytecode-array-random-iterator.h",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01002773 "src/interpreter/bytecode-array-writer.cc",
2774 "src/interpreter/bytecode-array-writer.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002775 "src/interpreter/bytecode-decoder.cc",
2776 "src/interpreter/bytecode-decoder.h",
2777 "src/interpreter/bytecode-flags.cc",
2778 "src/interpreter/bytecode-flags.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002779 "src/interpreter/bytecode-generator.cc",
2780 "src/interpreter/bytecode-generator.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002781 "src/interpreter/bytecode-jump-table.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002782 "src/interpreter/bytecode-label.cc",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01002783 "src/interpreter/bytecode-label.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002784 "src/interpreter/bytecode-node.cc",
2785 "src/interpreter/bytecode-node.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00002786 "src/interpreter/bytecode-operands.cc",
2787 "src/interpreter/bytecode-operands.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002788 "src/interpreter/bytecode-register-allocator.h",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01002789 "src/interpreter/bytecode-register-optimizer.cc",
2790 "src/interpreter/bytecode-register-optimizer.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00002791 "src/interpreter/bytecode-register.cc",
2792 "src/interpreter/bytecode-register.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002793 "src/interpreter/bytecode-source-info.cc",
2794 "src/interpreter/bytecode-source-info.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002795 "src/interpreter/bytecode-traits.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01002796 "src/interpreter/bytecodes.cc",
2797 "src/interpreter/bytecodes.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00002798 "src/interpreter/constant-array-builder.cc",
2799 "src/interpreter/constant-array-builder.h",
2800 "src/interpreter/control-flow-builders.cc",
2801 "src/interpreter/control-flow-builders.h",
Ben Murdoch109988c2016-05-18 11:27:45 +01002802 "src/interpreter/handler-table-builder.cc",
2803 "src/interpreter/handler-table-builder.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002804 "src/interpreter/interpreter-generator.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01002805 "src/interpreter/interpreter-intrinsics.cc",
2806 "src/interpreter/interpreter-intrinsics.h",
2807 "src/interpreter/interpreter.cc",
2808 "src/interpreter/interpreter.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00002809 "src/json/json-parser.cc",
2810 "src/json/json-parser.h",
2811 "src/json/json-stringifier.cc",
2812 "src/json/json-stringifier.h",
2813 "src/logging/code-events.h",
2814 "src/logging/counters-definitions.h",
2815 "src/logging/counters-inl.h",
2816 "src/logging/counters.cc",
2817 "src/logging/counters.h",
2818 "src/logging/local-logger.cc",
2819 "src/logging/local-logger.h",
2820 "src/logging/log-inl.h",
2821 "src/logging/log-utils.cc",
2822 "src/logging/log-utils.h",
2823 "src/logging/log.cc",
2824 "src/logging/log.h",
2825 "src/logging/metrics.cc",
2826 "src/logging/metrics.h",
2827 "src/logging/tracing-flags.cc",
2828 "src/logging/tracing-flags.h",
2829 "src/numbers/bignum-dtoa.cc",
2830 "src/numbers/bignum-dtoa.h",
2831 "src/numbers/bignum.cc",
2832 "src/numbers/bignum.h",
2833 "src/numbers/cached-powers.cc",
2834 "src/numbers/cached-powers.h",
2835 "src/numbers/conversions-inl.h",
2836 "src/numbers/conversions.cc",
2837 "src/numbers/conversions.h",
2838 "src/numbers/diy-fp.cc",
2839 "src/numbers/diy-fp.h",
2840 "src/numbers/double.h",
2841 "src/numbers/dtoa.cc",
2842 "src/numbers/dtoa.h",
2843 "src/numbers/fast-dtoa.cc",
2844 "src/numbers/fast-dtoa.h",
2845 "src/numbers/fixed-dtoa.cc",
2846 "src/numbers/fixed-dtoa.h",
2847 "src/numbers/hash-seed-inl.h",
2848 "src/numbers/math-random.cc",
2849 "src/numbers/math-random.h",
2850 "src/numbers/strtod.cc",
2851 "src/numbers/strtod.h",
2852 "src/objects/all-objects-inl.h",
2853 "src/objects/allocation-site-inl.h",
2854 "src/objects/allocation-site-scopes-inl.h",
2855 "src/objects/allocation-site-scopes.h",
2856 "src/objects/allocation-site.h",
2857 "src/objects/api-callbacks-inl.h",
2858 "src/objects/api-callbacks.h",
2859 "src/objects/arguments-inl.h",
2860 "src/objects/arguments.h",
2861 "src/objects/backing-store.cc",
2862 "src/objects/backing-store.h",
2863 "src/objects/bigint-inl.h",
2864 "src/objects/bigint.cc",
2865 "src/objects/bigint.h",
2866 "src/objects/cell-inl.h",
2867 "src/objects/cell.h",
2868 "src/objects/code-inl.h",
2869 "src/objects/code-kind.cc",
2870 "src/objects/code-kind.h",
2871 "src/objects/code.cc",
2872 "src/objects/code.h",
2873 "src/objects/compilation-cache-table-inl.h",
2874 "src/objects/compilation-cache-table.cc",
2875 "src/objects/compilation-cache-table.h",
2876 "src/objects/compressed-slots-inl.h",
2877 "src/objects/compressed-slots.h",
2878 "src/objects/contexts-inl.h",
2879 "src/objects/contexts.cc",
2880 "src/objects/contexts.h",
2881 "src/objects/data-handler-inl.h",
2882 "src/objects/data-handler.h",
2883 "src/objects/debug-objects-inl.h",
2884 "src/objects/debug-objects.cc",
2885 "src/objects/debug-objects.h",
2886 "src/objects/descriptor-array-inl.h",
2887 "src/objects/descriptor-array.h",
2888 "src/objects/dictionary-inl.h",
2889 "src/objects/dictionary.h",
2890 "src/objects/elements-inl.h",
2891 "src/objects/elements-kind.cc",
2892 "src/objects/elements-kind.h",
2893 "src/objects/elements.cc",
2894 "src/objects/elements.h",
2895 "src/objects/embedder-data-array-inl.h",
2896 "src/objects/embedder-data-array.cc",
2897 "src/objects/embedder-data-array.h",
2898 "src/objects/embedder-data-slot-inl.h",
2899 "src/objects/embedder-data-slot.h",
2900 "src/objects/feedback-cell-inl.h",
2901 "src/objects/feedback-cell.h",
2902 "src/objects/feedback-vector-inl.h",
2903 "src/objects/feedback-vector.cc",
2904 "src/objects/feedback-vector.h",
2905 "src/objects/field-index-inl.h",
2906 "src/objects/field-index.h",
2907 "src/objects/field-type.cc",
2908 "src/objects/field-type.h",
2909 "src/objects/fixed-array-inl.h",
2910 "src/objects/fixed-array.h",
2911 "src/objects/foreign-inl.h",
2912 "src/objects/foreign.h",
2913 "src/objects/frame-array-inl.h",
2914 "src/objects/frame-array.h",
2915 "src/objects/free-space-inl.h",
2916 "src/objects/free-space.h",
2917 "src/objects/function-kind.h",
2918 "src/objects/hash-table-inl.h",
2919 "src/objects/hash-table.h",
2920 "src/objects/heap-number-inl.h",
2921 "src/objects/heap-number.h",
2922 "src/objects/heap-object-inl.h",
2923 "src/objects/heap-object.h",
2924 "src/objects/instance-type-inl.h",
2925 "src/objects/instance-type.h",
2926 "src/objects/internal-index.h",
2927 "src/objects/intl-objects.cc",
2928 "src/objects/intl-objects.h",
2929 "src/objects/js-array-buffer-inl.h",
2930 "src/objects/js-array-buffer.cc",
2931 "src/objects/js-array-buffer.h",
2932 "src/objects/js-array-inl.h",
2933 "src/objects/js-array.h",
2934 "src/objects/js-break-iterator-inl.h",
2935 "src/objects/js-break-iterator.cc",
2936 "src/objects/js-break-iterator.h",
2937 "src/objects/js-collator-inl.h",
2938 "src/objects/js-collator.cc",
2939 "src/objects/js-collator.h",
2940 "src/objects/js-collection-inl.h",
2941 "src/objects/js-collection-iterator.h",
2942 "src/objects/js-collection.h",
2943 "src/objects/js-date-time-format-inl.h",
2944 "src/objects/js-date-time-format.cc",
2945 "src/objects/js-date-time-format.h",
2946 "src/objects/js-display-names-inl.h",
2947 "src/objects/js-display-names.cc",
2948 "src/objects/js-display-names.h",
2949 "src/objects/js-function-inl.h",
2950 "src/objects/js-function.cc",
2951 "src/objects/js-function.h",
2952 "src/objects/js-generator-inl.h",
2953 "src/objects/js-generator.h",
2954 "src/objects/js-list-format-inl.h",
2955 "src/objects/js-list-format.cc",
2956 "src/objects/js-list-format.h",
2957 "src/objects/js-locale-inl.h",
2958 "src/objects/js-locale.cc",
2959 "src/objects/js-locale.h",
2960 "src/objects/js-number-format-inl.h",
2961 "src/objects/js-number-format.cc",
2962 "src/objects/js-number-format.h",
2963 "src/objects/js-objects-inl.h",
2964 "src/objects/js-objects.cc",
2965 "src/objects/js-objects.h",
2966 "src/objects/js-plural-rules-inl.h",
2967 "src/objects/js-plural-rules.cc",
2968 "src/objects/js-plural-rules.h",
2969 "src/objects/js-promise-inl.h",
2970 "src/objects/js-promise.h",
2971 "src/objects/js-proxy-inl.h",
2972 "src/objects/js-proxy.h",
2973 "src/objects/js-regexp-inl.h",
2974 "src/objects/js-regexp-string-iterator-inl.h",
2975 "src/objects/js-regexp-string-iterator.h",
2976 "src/objects/js-regexp.cc",
2977 "src/objects/js-regexp.h",
2978 "src/objects/js-relative-time-format-inl.h",
2979 "src/objects/js-relative-time-format.cc",
2980 "src/objects/js-relative-time-format.h",
2981 "src/objects/js-segment-iterator-inl.h",
2982 "src/objects/js-segment-iterator.cc",
2983 "src/objects/js-segment-iterator.h",
2984 "src/objects/js-segmenter-inl.h",
2985 "src/objects/js-segmenter.cc",
2986 "src/objects/js-segmenter.h",
2987 "src/objects/js-segments-inl.h",
2988 "src/objects/js-segments.cc",
2989 "src/objects/js-segments.h",
2990 "src/objects/js-weak-refs-inl.h",
2991 "src/objects/js-weak-refs.h",
2992 "src/objects/keys.cc",
2993 "src/objects/keys.h",
2994 "src/objects/layout-descriptor-inl.h",
2995 "src/objects/layout-descriptor.cc",
2996 "src/objects/layout-descriptor.h",
2997 "src/objects/literal-objects-inl.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01002998 "src/objects/literal-objects.cc",
2999 "src/objects/literal-objects.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003000 "src/objects/lookup-cache-inl.h",
3001 "src/objects/lookup-cache.cc",
3002 "src/objects/lookup-cache.h",
3003 "src/objects/lookup-inl.h",
3004 "src/objects/lookup.cc",
3005 "src/objects/lookup.h",
3006 "src/objects/managed.cc",
3007 "src/objects/managed.h",
3008 "src/objects/map-inl.h",
3009 "src/objects/map-updater.cc",
3010 "src/objects/map-updater.h",
3011 "src/objects/map.cc",
3012 "src/objects/map.h",
3013 "src/objects/maybe-object-inl.h",
3014 "src/objects/maybe-object.h",
3015 "src/objects/microtask-inl.h",
3016 "src/objects/microtask.h",
3017 "src/objects/module-inl.h",
3018 "src/objects/module.cc",
3019 "src/objects/module.h",
3020 "src/objects/name-inl.h",
3021 "src/objects/name.h",
3022 "src/objects/object-list-macros.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003023 "src/objects/object-macros-undef.h",
3024 "src/objects/object-macros.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003025 "src/objects/objects-body-descriptors-inl.h",
3026 "src/objects/objects-body-descriptors.h",
3027 "src/objects/objects-inl.h",
3028 "src/objects/objects.cc",
3029 "src/objects/objects.h",
3030 "src/objects/oddball-inl.h",
3031 "src/objects/oddball.h",
3032 "src/objects/ordered-hash-table-inl.h",
3033 "src/objects/ordered-hash-table.cc",
3034 "src/objects/ordered-hash-table.h",
3035 "src/objects/osr-optimized-code-cache-inl.h",
3036 "src/objects/osr-optimized-code-cache.cc",
3037 "src/objects/osr-optimized-code-cache.h",
3038 "src/objects/primitive-heap-object-inl.h",
3039 "src/objects/primitive-heap-object.h",
3040 "src/objects/promise-inl.h",
3041 "src/objects/promise.h",
3042 "src/objects/property-array-inl.h",
3043 "src/objects/property-array.h",
3044 "src/objects/property-cell-inl.h",
3045 "src/objects/property-cell.h",
3046 "src/objects/property-descriptor-object-inl.h",
3047 "src/objects/property-descriptor-object.h",
3048 "src/objects/property-descriptor.cc",
3049 "src/objects/property-descriptor.h",
3050 "src/objects/property-details.h",
3051 "src/objects/property.cc",
3052 "src/objects/property.h",
3053 "src/objects/prototype-info-inl.h",
3054 "src/objects/prototype-info.h",
3055 "src/objects/prototype.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003056 "src/objects/regexp-match-info.h",
3057 "src/objects/scope-info.cc",
3058 "src/objects/scope-info.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003059 "src/objects/script-inl.h",
3060 "src/objects/script.h",
3061 "src/objects/shared-function-info-inl.h",
3062 "src/objects/shared-function-info.cc",
3063 "src/objects/shared-function-info.h",
3064 "src/objects/slots-atomic-inl.h",
3065 "src/objects/slots-inl.h",
3066 "src/objects/slots.h",
3067 "src/objects/source-text-module.cc",
3068 "src/objects/source-text-module.h",
3069 "src/objects/stack-frame-info-inl.h",
3070 "src/objects/stack-frame-info.cc",
3071 "src/objects/stack-frame-info.h",
3072 "src/objects/string-comparator.cc",
3073 "src/objects/string-comparator.h",
3074 "src/objects/string-inl.h",
3075 "src/objects/string-set-inl.h",
3076 "src/objects/string-set.h",
3077 "src/objects/string-table-inl.h",
3078 "src/objects/string-table.cc",
3079 "src/objects/string-table.h",
3080 "src/objects/string.cc",
3081 "src/objects/string.h",
3082 "src/objects/struct-inl.h",
3083 "src/objects/struct.h",
3084 "src/objects/synthetic-module-inl.h",
3085 "src/objects/synthetic-module.cc",
3086 "src/objects/synthetic-module.h",
3087 "src/objects/tagged-field-inl.h",
3088 "src/objects/tagged-field.h",
3089 "src/objects/tagged-impl-inl.h",
3090 "src/objects/tagged-impl.cc",
3091 "src/objects/tagged-impl.h",
3092 "src/objects/tagged-index.h",
3093 "src/objects/tagged-value-inl.h",
3094 "src/objects/tagged-value.h",
3095 "src/objects/template-objects-inl.h",
3096 "src/objects/template-objects.cc",
3097 "src/objects/template-objects.h",
3098 "src/objects/templates-inl.h",
3099 "src/objects/templates.h",
3100 "src/objects/torque-defined-classes-inl.h",
3101 "src/objects/torque-defined-classes.h",
3102 "src/objects/transitions-inl.h",
3103 "src/objects/transitions.cc",
3104 "src/objects/transitions.h",
3105 "src/objects/type-hints.cc",
3106 "src/objects/type-hints.h",
3107 "src/objects/value-serializer.cc",
3108 "src/objects/value-serializer.h",
3109 "src/objects/visitors.cc",
3110 "src/objects/visitors.h",
3111 "src/parsing/expression-scope.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003112 "src/parsing/func-name-inferrer.cc",
3113 "src/parsing/func-name-inferrer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003114 "src/parsing/literal-buffer.cc",
3115 "src/parsing/literal-buffer.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00003116 "src/parsing/parse-info.cc",
3117 "src/parsing/parse-info.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003118 "src/parsing/parser-base.h",
3119 "src/parsing/parser.cc",
3120 "src/parsing/parser.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003121 "src/parsing/parsing.cc",
3122 "src/parsing/parsing.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003123 "src/parsing/pending-compilation-error-handler.cc",
3124 "src/parsing/pending-compilation-error-handler.h",
3125 "src/parsing/preparse-data-impl.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003126 "src/parsing/preparse-data.cc",
3127 "src/parsing/preparse-data.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003128 "src/parsing/preparser-logger.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003129 "src/parsing/preparser.cc",
3130 "src/parsing/preparser.h",
3131 "src/parsing/rewriter.cc",
3132 "src/parsing/rewriter.h",
3133 "src/parsing/scanner-character-streams.cc",
3134 "src/parsing/scanner-character-streams.h",
3135 "src/parsing/scanner.cc",
3136 "src/parsing/scanner.h",
3137 "src/parsing/token.cc",
3138 "src/parsing/token.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003139 "src/profiler/allocation-tracker.cc",
3140 "src/profiler/allocation-tracker.h",
3141 "src/profiler/circular-queue-inl.h",
3142 "src/profiler/circular-queue.h",
3143 "src/profiler/cpu-profiler-inl.h",
3144 "src/profiler/cpu-profiler.cc",
3145 "src/profiler/cpu-profiler.h",
3146 "src/profiler/heap-profiler.cc",
3147 "src/profiler/heap-profiler.h",
3148 "src/profiler/heap-snapshot-generator-inl.h",
3149 "src/profiler/heap-snapshot-generator.cc",
3150 "src/profiler/heap-snapshot-generator.h",
3151 "src/profiler/profile-generator-inl.h",
3152 "src/profiler/profile-generator.cc",
3153 "src/profiler/profile-generator.h",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01003154 "src/profiler/profiler-listener.cc",
3155 "src/profiler/profiler-listener.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003156 "src/profiler/profiler-stats.cc",
3157 "src/profiler/profiler-stats.h",
Ben Murdoch109988c2016-05-18 11:27:45 +01003158 "src/profiler/sampling-heap-profiler.cc",
3159 "src/profiler/sampling-heap-profiler.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003160 "src/profiler/strings-storage.cc",
3161 "src/profiler/strings-storage.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003162 "src/profiler/symbolizer.cc",
3163 "src/profiler/symbolizer.h",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01003164 "src/profiler/tick-sample.cc",
3165 "src/profiler/tick-sample.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003166 "src/profiler/tracing-cpu-profiler.cc",
3167 "src/profiler/tracing-cpu-profiler.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003168 "src/regexp/experimental/experimental-bytecode.cc",
3169 "src/regexp/experimental/experimental-bytecode.h",
3170 "src/regexp/experimental/experimental-compiler.cc",
3171 "src/regexp/experimental/experimental-compiler.h",
3172 "src/regexp/experimental/experimental-interpreter.cc",
3173 "src/regexp/experimental/experimental-interpreter.h",
3174 "src/regexp/experimental/experimental.cc",
3175 "src/regexp/experimental/experimental.h",
3176 "src/regexp/property-sequences.cc",
3177 "src/regexp/property-sequences.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003178 "src/regexp/regexp-ast.cc",
3179 "src/regexp/regexp-ast.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003180 "src/regexp/regexp-bytecode-generator-inl.h",
3181 "src/regexp/regexp-bytecode-generator.cc",
3182 "src/regexp/regexp-bytecode-generator.h",
3183 "src/regexp/regexp-bytecode-peephole.cc",
3184 "src/regexp/regexp-bytecode-peephole.h",
3185 "src/regexp/regexp-bytecodes.cc",
3186 "src/regexp/regexp-bytecodes.h",
3187 "src/regexp/regexp-compiler-tonode.cc",
3188 "src/regexp/regexp-compiler.cc",
3189 "src/regexp/regexp-compiler.h",
3190 "src/regexp/regexp-dotprinter.cc",
3191 "src/regexp/regexp-dotprinter.h",
3192 "src/regexp/regexp-error.cc",
3193 "src/regexp/regexp-error.h",
3194 "src/regexp/regexp-interpreter.cc",
3195 "src/regexp/regexp-interpreter.h",
3196 "src/regexp/regexp-macro-assembler-arch.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003197 "src/regexp/regexp-macro-assembler-tracer.cc",
3198 "src/regexp/regexp-macro-assembler-tracer.h",
3199 "src/regexp/regexp-macro-assembler.cc",
3200 "src/regexp/regexp-macro-assembler.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003201 "src/regexp/regexp-nodes.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003202 "src/regexp/regexp-parser.cc",
3203 "src/regexp/regexp-parser.h",
3204 "src/regexp/regexp-stack.cc",
3205 "src/regexp/regexp-stack.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00003206 "src/regexp/regexp-utils.cc",
3207 "src/regexp/regexp-utils.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003208 "src/regexp/regexp.cc",
3209 "src/regexp/regexp.h",
3210 "src/regexp/special-case.h",
3211 "src/roots/roots-inl.h",
3212 "src/roots/roots.cc",
3213 "src/roots/roots.h",
Emily Bernier958fae72015-03-24 16:35:39 -04003214 "src/runtime/runtime-array.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003215 "src/runtime/runtime-atomics.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003216 "src/runtime/runtime-bigint.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003217 "src/runtime/runtime-classes.cc",
3218 "src/runtime/runtime-collections.cc",
3219 "src/runtime/runtime-compiler.cc",
3220 "src/runtime/runtime-date.cc",
3221 "src/runtime/runtime-debug.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003222 "src/runtime/runtime-forin.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003223 "src/runtime/runtime-function.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003224 "src/runtime/runtime-futex.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003225 "src/runtime/runtime-generator.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003226 "src/runtime/runtime-internal.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003227 "src/runtime/runtime-interpreter.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003228 "src/runtime/runtime-intl.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003229 "src/runtime/runtime-literals.cc",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00003230 "src/runtime/runtime-module.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003231 "src/runtime/runtime-numbers.cc",
3232 "src/runtime/runtime-object.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003233 "src/runtime/runtime-operators.cc",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00003234 "src/runtime/runtime-promise.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003235 "src/runtime/runtime-proxy.cc",
3236 "src/runtime/runtime-regexp.cc",
3237 "src/runtime/runtime-scopes.cc",
3238 "src/runtime/runtime-strings.cc",
3239 "src/runtime/runtime-symbol.cc",
3240 "src/runtime/runtime-test.cc",
3241 "src/runtime/runtime-typedarray.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003242 "src/runtime/runtime-utils.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00003243 "src/runtime/runtime-wasm.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003244 "src/runtime/runtime-weak-refs.cc",
Emily Bernier958fae72015-03-24 16:35:39 -04003245 "src/runtime/runtime.cc",
3246 "src/runtime/runtime.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003247 "src/sanitizer/asan.h",
3248 "src/sanitizer/lsan-page-allocator.cc",
3249 "src/sanitizer/lsan-page-allocator.h",
3250 "src/sanitizer/msan.h",
3251 "src/sanitizer/tsan.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01003252 "src/snapshot/code-serializer.cc",
3253 "src/snapshot/code-serializer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003254 "src/snapshot/context-deserializer.cc",
3255 "src/snapshot/context-deserializer.h",
3256 "src/snapshot/context-serializer.cc",
3257 "src/snapshot/context-serializer.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01003258 "src/snapshot/deserializer.cc",
3259 "src/snapshot/deserializer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003260 "src/snapshot/embedded/embedded-data.cc",
3261 "src/snapshot/embedded/embedded-data.h",
3262 "src/snapshot/object-deserializer.cc",
3263 "src/snapshot/object-deserializer.h",
3264 "src/snapshot/read-only-deserializer.cc",
3265 "src/snapshot/read-only-deserializer.h",
3266 "src/snapshot/read-only-serializer.cc",
3267 "src/snapshot/read-only-serializer.h",
3268 "src/snapshot/references.h",
3269 "src/snapshot/roots-serializer.cc",
3270 "src/snapshot/roots-serializer.h",
3271 "src/snapshot/serializer-deserializer.cc",
3272 "src/snapshot/serializer-deserializer.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01003273 "src/snapshot/serializer.cc",
3274 "src/snapshot/serializer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003275 "src/snapshot/snapshot-compression.cc",
3276 "src/snapshot/snapshot-compression.h",
3277 "src/snapshot/snapshot-data.cc",
3278 "src/snapshot/snapshot-data.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003279 "src/snapshot/snapshot-source-sink.cc",
3280 "src/snapshot/snapshot-source-sink.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003281 "src/snapshot/snapshot-utils.cc",
3282 "src/snapshot/snapshot-utils.h",
3283 "src/snapshot/snapshot.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003284 "src/snapshot/snapshot.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003285 "src/snapshot/startup-deserializer.cc",
3286 "src/snapshot/startup-deserializer.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01003287 "src/snapshot/startup-serializer.cc",
3288 "src/snapshot/startup-serializer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003289 "src/strings/char-predicates-inl.h",
3290 "src/strings/char-predicates.cc",
3291 "src/strings/char-predicates.h",
3292 "src/strings/string-builder-inl.h",
3293 "src/strings/string-builder.cc",
3294 "src/strings/string-case.cc",
3295 "src/strings/string-case.h",
3296 "src/strings/string-hasher-inl.h",
3297 "src/strings/string-hasher.h",
3298 "src/strings/string-search.h",
3299 "src/strings/string-stream.cc",
3300 "src/strings/string-stream.h",
3301 "src/strings/unicode-decoder.cc",
3302 "src/strings/unicode-decoder.h",
3303 "src/strings/unicode-inl.h",
3304 "src/strings/unicode.cc",
3305 "src/strings/unicode.h",
3306 "src/strings/uri.cc",
3307 "src/strings/uri.h",
3308 "src/tasks/cancelable-task.cc",
3309 "src/tasks/cancelable-task.h",
3310 "src/tasks/task-utils.cc",
3311 "src/tasks/task-utils.h",
3312 "src/third_party/siphash/halfsiphash.cc",
3313 "src/third_party/siphash/halfsiphash.h",
3314 "src/third_party/utf8-decoder/utf8-decoder.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003315 "src/tracing/trace-event.cc",
3316 "src/tracing/trace-event.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00003317 "src/tracing/traced-value.cc",
3318 "src/tracing/traced-value.h",
3319 "src/tracing/tracing-category-observer.cc",
3320 "src/tracing/tracing-category-observer.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003321 "src/trap-handler/handler-inside.cc",
3322 "src/trap-handler/handler-outside.cc",
3323 "src/trap-handler/handler-shared.cc",
3324 "src/trap-handler/trap-handler-internal.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003325 "src/trap-handler/trap-handler.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003326 "src/utils/address-map.cc",
3327 "src/utils/address-map.h",
3328 "src/utils/allocation.cc",
3329 "src/utils/allocation.h",
3330 "src/utils/bit-vector.cc",
3331 "src/utils/bit-vector.h",
3332 "src/utils/boxed-float.h",
3333 "src/utils/detachable-vector.cc",
3334 "src/utils/detachable-vector.h",
3335 "src/utils/identity-map.cc",
3336 "src/utils/identity-map.h",
3337 "src/utils/locked-queue-inl.h",
3338 "src/utils/locked-queue.h",
3339 "src/utils/memcopy.cc",
3340 "src/utils/memcopy.h",
3341 "src/utils/ostreams.cc",
3342 "src/utils/ostreams.h",
3343 "src/utils/pointer-with-payload.h",
3344 "src/utils/scoped-list.h",
3345 "src/utils/utils-inl.h",
3346 "src/utils/utils.cc",
3347 "src/utils/utils.h",
3348 "src/utils/vector.h",
3349 "src/utils/version.cc",
3350 "src/utils/version.h",
3351 "src/wasm/baseline/liftoff-assembler-defs.h",
3352 "src/wasm/baseline/liftoff-assembler.cc",
3353 "src/wasm/baseline/liftoff-assembler.h",
3354 "src/wasm/baseline/liftoff-compiler.cc",
3355 "src/wasm/baseline/liftoff-compiler.h",
3356 "src/wasm/baseline/liftoff-register.h",
3357 "src/wasm/code-space-access.h",
3358 "src/wasm/compilation-environment.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003359 "src/wasm/decoder.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003360 "src/wasm/function-body-decoder-impl.h",
3361 "src/wasm/function-body-decoder.cc",
3362 "src/wasm/function-body-decoder.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003363 "src/wasm/function-compiler.cc",
3364 "src/wasm/function-compiler.h",
3365 "src/wasm/graph-builder-interface.cc",
3366 "src/wasm/graph-builder-interface.h",
3367 "src/wasm/jump-table-assembler.cc",
3368 "src/wasm/jump-table-assembler.h",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01003369 "src/wasm/leb-helper.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003370 "src/wasm/local-decl-encoder.cc",
3371 "src/wasm/local-decl-encoder.h",
3372 "src/wasm/memory-tracing.cc",
3373 "src/wasm/memory-tracing.h",
3374 "src/wasm/module-compiler.cc",
3375 "src/wasm/module-compiler.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003376 "src/wasm/module-decoder.cc",
3377 "src/wasm/module-decoder.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003378 "src/wasm/module-instantiate.cc",
3379 "src/wasm/module-instantiate.h",
3380 "src/wasm/object-access.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00003381 "src/wasm/signature-map.cc",
3382 "src/wasm/signature-map.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003383 "src/wasm/simd-shuffle.cc",
3384 "src/wasm/simd-shuffle.h",
3385 "src/wasm/streaming-decoder.cc",
3386 "src/wasm/streaming-decoder.h",
3387 "src/wasm/struct-types.h",
3388 "src/wasm/sync-streaming-decoder.cc",
3389 "src/wasm/value-type.h",
3390 "src/wasm/wasm-arguments.h",
3391 "src/wasm/wasm-code-manager.cc",
3392 "src/wasm/wasm-code-manager.h",
3393 "src/wasm/wasm-constants.h",
3394 "src/wasm/wasm-debug-evaluate.cc",
3395 "src/wasm/wasm-debug-evaluate.h",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01003396 "src/wasm/wasm-debug.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003397 "src/wasm/wasm-engine.cc",
3398 "src/wasm/wasm-engine.h",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01003399 "src/wasm/wasm-external-refs.cc",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01003400 "src/wasm/wasm-external-refs.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003401 "src/wasm/wasm-feature-flags.h",
3402 "src/wasm/wasm-features.cc",
3403 "src/wasm/wasm-features.h",
3404 "src/wasm/wasm-import-wrapper-cache.cc",
3405 "src/wasm/wasm-import-wrapper-cache.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003406 "src/wasm/wasm-js.cc",
3407 "src/wasm/wasm-js.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003408 "src/wasm/wasm-limits.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003409 "src/wasm/wasm-linkage.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003410 "src/wasm/wasm-module-builder.cc",
3411 "src/wasm/wasm-module-builder.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003412 "src/wasm/wasm-module-sourcemap.cc",
3413 "src/wasm/wasm-module-sourcemap.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003414 "src/wasm/wasm-module.cc",
3415 "src/wasm/wasm-module.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003416 "src/wasm/wasm-objects-inl.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00003417 "src/wasm/wasm-objects.cc",
3418 "src/wasm/wasm-objects.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003419 "src/wasm/wasm-opcodes.cc",
3420 "src/wasm/wasm-opcodes.h",
3421 "src/wasm/wasm-result.cc",
3422 "src/wasm/wasm-result.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003423 "src/wasm/wasm-serialization.cc",
3424 "src/wasm/wasm-serialization.h",
3425 "src/wasm/wasm-subtyping.cc",
3426 "src/wasm/wasm-subtyping.h",
3427 "src/wasm/wasm-tier.h",
3428 "src/wasm/wasm-value.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003429 "src/zone/accounting-allocator.cc",
3430 "src/zone/accounting-allocator.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003431 "src/zone/compressed-zone-ptr.h",
3432 "src/zone/type-stats.cc",
3433 "src/zone/type-stats.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003434 "src/zone/zone-allocator.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00003435 "src/zone/zone-chunk-list.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003436 "src/zone/zone-compression.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003437 "src/zone/zone-containers.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003438 "src/zone/zone-handle-set.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003439 "src/zone/zone-hashmap.h",
3440 "src/zone/zone-list-inl.h",
3441 "src/zone/zone-list.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003442 "src/zone/zone-segment.cc",
3443 "src/zone/zone-segment.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003444 "src/zone/zone-type-traits.h",
3445 "src/zone/zone-utils.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003446 "src/zone/zone.cc",
3447 "src/zone/zone.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003448 ]
3449
Rubin Xu7bc1b612021-02-16 09:38:50 +00003450 if (!v8_control_flow_integrity) {
3451 sources += [ "src/execution/pointer-authentication-dummy.h" ]
3452 }
3453
3454 if (v8_enable_third_party_heap) {
3455 sources += v8_third_party_heap_files
3456 } else {
3457 sources += [ "src/heap/third-party/heap-api-stub.cc" ]
3458 }
3459
3460 if (v8_enable_conservative_stack_scanning) {
3461 sources += [
3462 "src/heap/conservative-stack-visitor.cc",
3463 "src/heap/conservative-stack-visitor.h",
3464 "src/heap/object-start-bitmap.h",
3465 ]
3466 }
3467
3468 if (v8_enable_wasm_gdb_remote_debugging) {
3469 sources += [
3470 "src/debug/wasm/gdb-server/gdb-remote-util.cc",
3471 "src/debug/wasm/gdb-server/gdb-remote-util.h",
3472 "src/debug/wasm/gdb-server/gdb-server-thread.cc",
3473 "src/debug/wasm/gdb-server/gdb-server-thread.h",
3474 "src/debug/wasm/gdb-server/gdb-server.cc",
3475 "src/debug/wasm/gdb-server/gdb-server.h",
3476 "src/debug/wasm/gdb-server/packet.cc",
3477 "src/debug/wasm/gdb-server/packet.h",
3478 "src/debug/wasm/gdb-server/session.cc",
3479 "src/debug/wasm/gdb-server/session.h",
3480 "src/debug/wasm/gdb-server/target.cc",
3481 "src/debug/wasm/gdb-server/target.h",
3482 "src/debug/wasm/gdb-server/transport.cc",
3483 "src/debug/wasm/gdb-server/transport.h",
3484 "src/debug/wasm/gdb-server/wasm-module-debug.cc",
3485 "src/debug/wasm/gdb-server/wasm-module-debug.h",
3486 ]
3487 }
3488
3489 if (v8_check_header_includes) {
3490 # This file will be generated by tools/generate-header-include-checks.py
3491 # if the "check_v8_header_includes" gclient variable is set.
3492 import("check-header-includes/sources.gni")
3493 sources += check_header_includes_sources
3494 }
3495
Ben Murdochf91f0612016-11-29 16:50:11 +00003496 if (v8_current_cpu == "x86") {
Ben Murdochf3b273f2017-01-17 12:11:28 +00003497 sources += [ ### gcmole(arch:ia32) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003498 "src/codegen/ia32/assembler-ia32-inl.h",
3499 "src/codegen/ia32/assembler-ia32.cc",
3500 "src/codegen/ia32/assembler-ia32.h",
3501 "src/codegen/ia32/constants-ia32.h",
3502 "src/codegen/ia32/cpu-ia32.cc",
3503 "src/codegen/ia32/interface-descriptors-ia32.cc",
3504 "src/codegen/ia32/macro-assembler-ia32.cc",
3505 "src/codegen/ia32/macro-assembler-ia32.h",
3506 "src/codegen/ia32/register-ia32.h",
3507 "src/codegen/ia32/sse-instr.h",
3508 "src/compiler/backend/ia32/code-generator-ia32.cc",
3509 "src/compiler/backend/ia32/instruction-codes-ia32.h",
3510 "src/compiler/backend/ia32/instruction-scheduler-ia32.cc",
3511 "src/compiler/backend/ia32/instruction-selector-ia32.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003512 "src/debug/ia32/debug-ia32.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003513 "src/deoptimizer/ia32/deoptimizer-ia32.cc",
3514 "src/diagnostics/ia32/disasm-ia32.cc",
3515 "src/diagnostics/ia32/unwinder-ia32.cc",
3516 "src/execution/ia32/frame-constants-ia32.cc",
3517 "src/execution/ia32/frame-constants-ia32.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003518 "src/regexp/ia32/regexp-macro-assembler-ia32.cc",
3519 "src/regexp/ia32/regexp-macro-assembler-ia32.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003520 "src/wasm/baseline/ia32/liftoff-assembler-ia32.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003521 ]
Ben Murdochf91f0612016-11-29 16:50:11 +00003522 } else if (v8_current_cpu == "x64") {
Ben Murdochf3b273f2017-01-17 12:11:28 +00003523 sources += [ ### gcmole(arch:x64) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003524 "src/codegen/x64/assembler-x64-inl.h",
3525 "src/codegen/x64/assembler-x64.cc",
3526 "src/codegen/x64/assembler-x64.h",
3527 "src/codegen/x64/constants-x64.h",
3528 "src/codegen/x64/cpu-x64.cc",
3529 "src/codegen/x64/fma-instr.h",
3530 "src/codegen/x64/interface-descriptors-x64.cc",
3531 "src/codegen/x64/macro-assembler-x64.cc",
3532 "src/codegen/x64/macro-assembler-x64.h",
3533 "src/codegen/x64/register-x64.h",
3534 "src/codegen/x64/sse-instr.h",
3535 "src/compiler/backend/x64/code-generator-x64.cc",
3536 "src/compiler/backend/x64/instruction-codes-x64.h",
3537 "src/compiler/backend/x64/instruction-scheduler-x64.cc",
3538 "src/compiler/backend/x64/instruction-selector-x64.cc",
3539 "src/compiler/backend/x64/unwinding-info-writer-x64.cc",
3540 "src/compiler/backend/x64/unwinding-info-writer-x64.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003541 "src/debug/x64/debug-x64.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003542 "src/deoptimizer/x64/deoptimizer-x64.cc",
3543 "src/diagnostics/x64/disasm-x64.cc",
3544 "src/diagnostics/x64/eh-frame-x64.cc",
3545 "src/diagnostics/x64/unwinder-x64.cc",
3546 "src/execution/x64/frame-constants-x64.cc",
3547 "src/execution/x64/frame-constants-x64.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003548 "src/regexp/x64/regexp-macro-assembler-x64.cc",
3549 "src/regexp/x64/regexp-macro-assembler-x64.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003550 "src/third_party/valgrind/valgrind.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003551 "src/wasm/baseline/x64/liftoff-assembler-x64.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003552 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00003553
3554 # iOS Xcode simulator builds run on an x64 target. iOS and macOS are both
3555 # based on Darwin and thus POSIX-compliant to a similar degree.
3556 if (is_linux || is_chromeos || is_mac || is_ios || target_os == "freebsd") {
3557 sources += [
3558 "src/trap-handler/handler-inside-posix.cc",
3559 "src/trap-handler/handler-inside-posix.h",
3560 "src/trap-handler/handler-outside-posix.cc",
3561 ]
3562 }
3563 if (is_win) {
3564 sources += [
3565 "src/diagnostics/unwinding-info-win64.cc",
3566 "src/diagnostics/unwinding-info-win64.h",
3567 "src/trap-handler/handler-inside-win.cc",
3568 "src/trap-handler/handler-inside-win.h",
3569 "src/trap-handler/handler-outside-win.cc",
3570 ]
3571 }
Ben Murdochf91f0612016-11-29 16:50:11 +00003572 } else if (v8_current_cpu == "arm") {
Ben Murdochf3b273f2017-01-17 12:11:28 +00003573 sources += [ ### gcmole(arch:arm) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003574 "src/codegen/arm/assembler-arm-inl.h",
3575 "src/codegen/arm/assembler-arm.cc",
3576 "src/codegen/arm/assembler-arm.h",
3577 "src/codegen/arm/constants-arm.cc",
3578 "src/codegen/arm/constants-arm.h",
3579 "src/codegen/arm/cpu-arm.cc",
3580 "src/codegen/arm/interface-descriptors-arm.cc",
3581 "src/codegen/arm/macro-assembler-arm.cc",
3582 "src/codegen/arm/macro-assembler-arm.h",
3583 "src/codegen/arm/register-arm.h",
3584 "src/compiler/backend/arm/code-generator-arm.cc",
3585 "src/compiler/backend/arm/instruction-codes-arm.h",
3586 "src/compiler/backend/arm/instruction-scheduler-arm.cc",
3587 "src/compiler/backend/arm/instruction-selector-arm.cc",
3588 "src/compiler/backend/arm/unwinding-info-writer-arm.cc",
3589 "src/compiler/backend/arm/unwinding-info-writer-arm.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003590 "src/debug/arm/debug-arm.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003591 "src/deoptimizer/arm/deoptimizer-arm.cc",
3592 "src/diagnostics/arm/disasm-arm.cc",
3593 "src/diagnostics/arm/eh-frame-arm.cc",
3594 "src/diagnostics/arm/unwinder-arm.cc",
3595 "src/execution/arm/frame-constants-arm.cc",
3596 "src/execution/arm/frame-constants-arm.h",
3597 "src/execution/arm/simulator-arm.cc",
3598 "src/execution/arm/simulator-arm.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003599 "src/regexp/arm/regexp-macro-assembler-arm.cc",
3600 "src/regexp/arm/regexp-macro-assembler-arm.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003601 "src/wasm/baseline/arm/liftoff-assembler-arm.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003602 ]
Ben Murdochf91f0612016-11-29 16:50:11 +00003603 } else if (v8_current_cpu == "arm64") {
Ben Murdochf3b273f2017-01-17 12:11:28 +00003604 sources += [ ### gcmole(arch:arm64) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003605 "src/codegen/arm64/assembler-arm64-inl.h",
3606 "src/codegen/arm64/assembler-arm64.cc",
3607 "src/codegen/arm64/assembler-arm64.h",
3608 "src/codegen/arm64/constants-arm64.h",
3609 "src/codegen/arm64/cpu-arm64.cc",
3610 "src/codegen/arm64/decoder-arm64-inl.h",
3611 "src/codegen/arm64/decoder-arm64.cc",
3612 "src/codegen/arm64/decoder-arm64.h",
3613 "src/codegen/arm64/instructions-arm64-constants.cc",
3614 "src/codegen/arm64/instructions-arm64.cc",
3615 "src/codegen/arm64/instructions-arm64.h",
3616 "src/codegen/arm64/interface-descriptors-arm64.cc",
3617 "src/codegen/arm64/macro-assembler-arm64-inl.h",
3618 "src/codegen/arm64/macro-assembler-arm64.cc",
3619 "src/codegen/arm64/macro-assembler-arm64.h",
3620 "src/codegen/arm64/register-arm64.cc",
3621 "src/codegen/arm64/register-arm64.h",
3622 "src/codegen/arm64/utils-arm64.cc",
3623 "src/codegen/arm64/utils-arm64.h",
3624 "src/compiler/backend/arm64/code-generator-arm64.cc",
3625 "src/compiler/backend/arm64/instruction-codes-arm64.h",
3626 "src/compiler/backend/arm64/instruction-scheduler-arm64.cc",
3627 "src/compiler/backend/arm64/instruction-selector-arm64.cc",
3628 "src/compiler/backend/arm64/unwinding-info-writer-arm64.cc",
3629 "src/compiler/backend/arm64/unwinding-info-writer-arm64.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003630 "src/debug/arm64/debug-arm64.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003631 "src/deoptimizer/arm64/deoptimizer-arm64.cc",
3632 "src/diagnostics/arm64/disasm-arm64.cc",
3633 "src/diagnostics/arm64/disasm-arm64.h",
3634 "src/diagnostics/arm64/eh-frame-arm64.cc",
3635 "src/diagnostics/arm64/unwinder-arm64.cc",
3636 "src/execution/arm64/frame-constants-arm64.cc",
3637 "src/execution/arm64/frame-constants-arm64.h",
3638 "src/execution/arm64/pointer-auth-arm64.cc",
3639 "src/execution/arm64/simulator-arm64.cc",
3640 "src/execution/arm64/simulator-arm64.h",
3641 "src/execution/arm64/simulator-logic-arm64.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003642 "src/regexp/arm64/regexp-macro-assembler-arm64.cc",
3643 "src/regexp/arm64/regexp-macro-assembler-arm64.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003644 "src/wasm/baseline/arm64/liftoff-assembler-arm64.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003645 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00003646 if (v8_control_flow_integrity) {
3647 sources += [ "src/execution/arm64/pointer-authentication-arm64.h" ]
3648 }
3649 if (is_win) {
3650 sources += [
3651 "src/diagnostics/unwinding-info-win64.cc",
3652 "src/diagnostics/unwinding-info-win64.h",
3653 ]
3654 }
Ben Murdochf3b273f2017-01-17 12:11:28 +00003655 } else if (v8_current_cpu == "mips" || v8_current_cpu == "mipsel") {
3656 sources += [ ### gcmole(arch:mipsel) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003657 "src/codegen/mips/assembler-mips-inl.h",
3658 "src/codegen/mips/assembler-mips.cc",
3659 "src/codegen/mips/assembler-mips.h",
3660 "src/codegen/mips/constants-mips.cc",
3661 "src/codegen/mips/constants-mips.h",
3662 "src/codegen/mips/cpu-mips.cc",
3663 "src/codegen/mips/interface-descriptors-mips.cc",
3664 "src/codegen/mips/macro-assembler-mips.cc",
3665 "src/codegen/mips/macro-assembler-mips.h",
3666 "src/codegen/mips/register-mips.h",
3667 "src/compiler/backend/mips/code-generator-mips.cc",
3668 "src/compiler/backend/mips/instruction-codes-mips.h",
3669 "src/compiler/backend/mips/instruction-scheduler-mips.cc",
3670 "src/compiler/backend/mips/instruction-selector-mips.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003671 "src/debug/mips/debug-mips.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003672 "src/deoptimizer/mips/deoptimizer-mips.cc",
3673 "src/diagnostics/mips/disasm-mips.cc",
3674 "src/diagnostics/mips/unwinder-mips.cc",
3675 "src/execution/mips/frame-constants-mips.cc",
3676 "src/execution/mips/frame-constants-mips.h",
3677 "src/execution/mips/simulator-mips.cc",
3678 "src/execution/mips/simulator-mips.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003679 "src/regexp/mips/regexp-macro-assembler-mips.cc",
3680 "src/regexp/mips/regexp-macro-assembler-mips.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003681 "src/wasm/baseline/mips/liftoff-assembler-mips.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003682 ]
Ben Murdochf3b273f2017-01-17 12:11:28 +00003683 } else if (v8_current_cpu == "mips64" || v8_current_cpu == "mips64el") {
3684 sources += [ ### gcmole(arch:mips64el) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003685 "src/codegen/mips64/assembler-mips64-inl.h",
3686 "src/codegen/mips64/assembler-mips64.cc",
3687 "src/codegen/mips64/assembler-mips64.h",
3688 "src/codegen/mips64/constants-mips64.cc",
3689 "src/codegen/mips64/constants-mips64.h",
3690 "src/codegen/mips64/cpu-mips64.cc",
3691 "src/codegen/mips64/interface-descriptors-mips64.cc",
3692 "src/codegen/mips64/macro-assembler-mips64.cc",
3693 "src/codegen/mips64/macro-assembler-mips64.h",
3694 "src/codegen/mips64/register-mips64.h",
3695 "src/compiler/backend/mips64/code-generator-mips64.cc",
3696 "src/compiler/backend/mips64/instruction-codes-mips64.h",
3697 "src/compiler/backend/mips64/instruction-scheduler-mips64.cc",
3698 "src/compiler/backend/mips64/instruction-selector-mips64.cc",
Ben Murdoch014dc512016-03-22 12:00:34 +00003699 "src/debug/mips64/debug-mips64.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003700 "src/deoptimizer/mips64/deoptimizer-mips64.cc",
3701 "src/diagnostics/mips64/disasm-mips64.cc",
3702 "src/diagnostics/mips64/unwinder-mips64.cc",
3703 "src/execution/mips64/frame-constants-mips64.cc",
3704 "src/execution/mips64/frame-constants-mips64.h",
3705 "src/execution/mips64/simulator-mips64.cc",
3706 "src/execution/mips64/simulator-mips64.h",
Ben Murdoch014dc512016-03-22 12:00:34 +00003707 "src/regexp/mips64/regexp-macro-assembler-mips64.cc",
3708 "src/regexp/mips64/regexp-macro-assembler-mips64.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003709 "src/wasm/baseline/mips64/liftoff-assembler-mips64.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003710 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00003711 } else if (v8_current_cpu == "ppc") {
Ben Murdochf3b273f2017-01-17 12:11:28 +00003712 sources += [ ### gcmole(arch:ppc) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003713 "src/codegen/ppc/assembler-ppc-inl.h",
3714 "src/codegen/ppc/assembler-ppc.cc",
3715 "src/codegen/ppc/assembler-ppc.h",
3716 "src/codegen/ppc/constants-ppc.cc",
3717 "src/codegen/ppc/constants-ppc.h",
3718 "src/codegen/ppc/cpu-ppc.cc",
3719 "src/codegen/ppc/interface-descriptors-ppc.cc",
3720 "src/codegen/ppc/macro-assembler-ppc.cc",
3721 "src/codegen/ppc/macro-assembler-ppc.h",
3722 "src/codegen/ppc/register-ppc.h",
3723 "src/compiler/backend/ppc/code-generator-ppc.cc",
3724 "src/compiler/backend/ppc/instruction-codes-ppc.h",
3725 "src/compiler/backend/ppc/instruction-scheduler-ppc.cc",
3726 "src/compiler/backend/ppc/instruction-selector-ppc.cc",
3727 "src/compiler/backend/ppc/unwinding-info-writer-ppc.cc",
3728 "src/compiler/backend/ppc/unwinding-info-writer-ppc.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003729 "src/debug/ppc/debug-ppc.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003730 "src/deoptimizer/ppc/deoptimizer-ppc.cc",
3731 "src/diagnostics/ppc/disasm-ppc.cc",
3732 "src/diagnostics/ppc/eh-frame-ppc.cc",
3733 "src/diagnostics/ppc/unwinder-ppc.cc",
3734 "src/execution/ppc/frame-constants-ppc.cc",
3735 "src/execution/ppc/frame-constants-ppc.h",
3736 "src/execution/ppc/simulator-ppc.cc",
3737 "src/execution/ppc/simulator-ppc.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003738 "src/regexp/ppc/regexp-macro-assembler-ppc.cc",
3739 "src/regexp/ppc/regexp-macro-assembler-ppc.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003740 "src/wasm/baseline/ppc/liftoff-assembler-ppc.h",
3741 ]
3742 } else if (v8_current_cpu == "ppc64") {
3743 sources += [ ### gcmole(arch:ppc64) ###
3744 "src/codegen/ppc/assembler-ppc-inl.h",
3745 "src/codegen/ppc/assembler-ppc.cc",
3746 "src/codegen/ppc/assembler-ppc.h",
3747 "src/codegen/ppc/constants-ppc.cc",
3748 "src/codegen/ppc/constants-ppc.h",
3749 "src/codegen/ppc/cpu-ppc.cc",
3750 "src/codegen/ppc/interface-descriptors-ppc.cc",
3751 "src/codegen/ppc/macro-assembler-ppc.cc",
3752 "src/codegen/ppc/macro-assembler-ppc.h",
3753 "src/codegen/ppc/register-ppc.h",
3754 "src/compiler/backend/ppc/code-generator-ppc.cc",
3755 "src/compiler/backend/ppc/instruction-codes-ppc.h",
3756 "src/compiler/backend/ppc/instruction-scheduler-ppc.cc",
3757 "src/compiler/backend/ppc/instruction-selector-ppc.cc",
3758 "src/compiler/backend/ppc/unwinding-info-writer-ppc.cc",
3759 "src/compiler/backend/ppc/unwinding-info-writer-ppc.h",
3760 "src/debug/ppc/debug-ppc.cc",
3761 "src/deoptimizer/ppc/deoptimizer-ppc.cc",
3762 "src/diagnostics/ppc/disasm-ppc.cc",
3763 "src/diagnostics/ppc/eh-frame-ppc.cc",
3764 "src/diagnostics/ppc/unwinder-ppc.cc",
3765 "src/execution/ppc/frame-constants-ppc.cc",
3766 "src/execution/ppc/frame-constants-ppc.h",
3767 "src/execution/ppc/simulator-ppc.cc",
3768 "src/execution/ppc/simulator-ppc.h",
3769 "src/regexp/ppc/regexp-macro-assembler-ppc.cc",
3770 "src/regexp/ppc/regexp-macro-assembler-ppc.h",
3771 "src/wasm/baseline/ppc/liftoff-assembler-ppc.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003772 ]
Ben Murdochf91f0612016-11-29 16:50:11 +00003773 } else if (v8_current_cpu == "s390" || v8_current_cpu == "s390x") {
Ben Murdochf3b273f2017-01-17 12:11:28 +00003774 sources += [ ### gcmole(arch:s390) ###
Rubin Xu7bc1b612021-02-16 09:38:50 +00003775 "src/codegen/s390/assembler-s390-inl.h",
3776 "src/codegen/s390/assembler-s390.cc",
3777 "src/codegen/s390/assembler-s390.h",
3778 "src/codegen/s390/constants-s390.cc",
3779 "src/codegen/s390/constants-s390.h",
3780 "src/codegen/s390/cpu-s390.cc",
3781 "src/codegen/s390/interface-descriptors-s390.cc",
3782 "src/codegen/s390/macro-assembler-s390.cc",
3783 "src/codegen/s390/macro-assembler-s390.h",
3784 "src/codegen/s390/register-s390.h",
3785 "src/compiler/backend/s390/code-generator-s390.cc",
3786 "src/compiler/backend/s390/instruction-codes-s390.h",
3787 "src/compiler/backend/s390/instruction-scheduler-s390.cc",
3788 "src/compiler/backend/s390/instruction-selector-s390.cc",
3789 "src/compiler/backend/s390/unwinding-info-writer-s390.cc",
3790 "src/compiler/backend/s390/unwinding-info-writer-s390.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01003791 "src/debug/s390/debug-s390.cc",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003792 "src/deoptimizer/s390/deoptimizer-s390.cc",
3793 "src/diagnostics/s390/disasm-s390.cc",
3794 "src/diagnostics/s390/eh-frame-s390.cc",
3795 "src/diagnostics/s390/unwinder-s390.cc",
3796 "src/execution/s390/frame-constants-s390.cc",
3797 "src/execution/s390/frame-constants-s390.h",
3798 "src/execution/s390/simulator-s390.cc",
3799 "src/execution/s390/simulator-s390.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01003800 "src/regexp/s390/regexp-macro-assembler-s390.cc",
3801 "src/regexp/s390/regexp-macro-assembler-s390.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003802 "src/wasm/baseline/s390/liftoff-assembler-s390.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00003803 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003804 }
3805
Rubin Xu7bc1b612021-02-16 09:38:50 +00003806 configs = [
3807 ":internal_config",
3808 ":cppgc_base_config",
3809 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003810
3811 defines = []
Ben Murdoch014dc512016-03-22 12:00:34 +00003812 deps = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00003813 ":cppgc_base",
3814 ":torque_generated_definitions",
3815 ":v8_cppgc_shared",
3816 ":v8_headers",
Ben Murdoch014dc512016-03-22 12:00:34 +00003817 ":v8_libbase",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01003818 ":v8_libsampler",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003819 ":v8_shared_internal_headers",
3820 ":v8_tracing",
Ben Murdoch62ed6312017-06-06 11:06:27 +01003821 ":v8_version",
Rubin Xu7bc1b612021-02-16 09:38:50 +00003822 "src/inspector:inspector",
Ben Murdoch014dc512016-03-22 12:00:34 +00003823 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003824
Rubin Xu7bc1b612021-02-16 09:38:50 +00003825 public_deps = [
3826 ":generate_bytecode_builtins_list",
3827 ":run_torque",
3828 ":v8_maybe_icu",
3829 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003830
3831 if (v8_enable_i18n_support) {
Rubin Xu7bc1b612021-02-16 09:38:50 +00003832 deps += [ ":run_gen-regexp-special-case" ]
3833 sources += [ "$target_gen_dir/src/regexp/special-case.cc" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003834 if (is_win) {
3835 deps += [ "//third_party/icu:icudata" ]
3836 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003837 } else {
3838 sources -= [
Rubin Xu7bc1b612021-02-16 09:38:50 +00003839 "src/builtins/builtins-intl.cc",
3840 "src/objects/intl-objects.cc",
3841 "src/objects/intl-objects.h",
3842 "src/objects/js-break-iterator-inl.h",
3843 "src/objects/js-break-iterator.cc",
3844 "src/objects/js-break-iterator.h",
3845 "src/objects/js-collator-inl.h",
3846 "src/objects/js-collator.cc",
3847 "src/objects/js-collator.h",
3848 "src/objects/js-date-time-format-inl.h",
3849 "src/objects/js-date-time-format.cc",
3850 "src/objects/js-date-time-format.h",
3851 "src/objects/js-display-names-inl.h",
3852 "src/objects/js-display-names.cc",
3853 "src/objects/js-display-names.h",
3854 "src/objects/js-list-format-inl.h",
3855 "src/objects/js-list-format.cc",
3856 "src/objects/js-list-format.h",
3857 "src/objects/js-locale-inl.h",
3858 "src/objects/js-locale.cc",
3859 "src/objects/js-locale.h",
3860 "src/objects/js-number-format-inl.h",
3861 "src/objects/js-number-format.cc",
3862 "src/objects/js-number-format.h",
3863 "src/objects/js-plural-rules-inl.h",
3864 "src/objects/js-plural-rules.cc",
3865 "src/objects/js-plural-rules.h",
3866 "src/objects/js-relative-time-format-inl.h",
3867 "src/objects/js-relative-time-format.cc",
3868 "src/objects/js-relative-time-format.h",
3869 "src/objects/js-segment-iterator-inl.h",
3870 "src/objects/js-segment-iterator.cc",
3871 "src/objects/js-segment-iterator.h",
3872 "src/objects/js-segmenter-inl.h",
3873 "src/objects/js-segmenter.cc",
3874 "src/objects/js-segmenter.h",
3875 "src/objects/js-segments-inl.h",
3876 "src/objects/js-segments.cc",
3877 "src/objects/js-segments.h",
3878 "src/runtime/runtime-intl.cc",
3879 "src/strings/char-predicates.cc",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003880 ]
3881 }
3882
Rubin Xu7bc1b612021-02-16 09:38:50 +00003883 deps += [
3884 "//third_party/zlib",
3885 "//third_party/zlib/google:compression_utils_portable",
3886 ]
3887
Ben Murdochb8a8cc12014-11-26 15:28:44 +00003888 if (v8_postmortem_support) {
3889 sources += [ "$target_gen_dir/debug-support.cc" ]
3890 deps += [ ":postmortem-metadata" ]
3891 }
Ben Murdochf3b273f2017-01-17 12:11:28 +00003892
Rubin Xu7bc1b612021-02-16 09:38:50 +00003893 libs = []
3894
3895 if (v8_enable_third_party_heap) {
3896 libs += v8_third_party_heap_libs
3897 }
3898
3899 # Platforms that don't have CAS support need to link atomic library
3900 # to implement atomic memory access
3901 if (v8_current_cpu == "mips" || v8_current_cpu == "mipsel" ||
3902 v8_current_cpu == "mips64" || v8_current_cpu == "mips64el" ||
3903 v8_current_cpu == "ppc" || v8_current_cpu == "ppc64" ||
3904 v8_current_cpu == "s390" || v8_current_cpu == "s390x") {
3905 libs += [ "atomic" ]
3906 }
3907
3908 if (v8_enable_vtunetracemark && (is_linux || is_chromeos || is_win)) {
3909 sources += [
3910 "src/extensions/vtunedomain-support-extension.cc",
3911 "src/extensions/vtunedomain-support-extension.h",
3912 ]
3913 deps += [ "src/third_party/vtune:v8_vtune_trace_mark" ]
3914 }
3915
3916 if (v8_use_perfetto) {
3917 sources -= [ "//base/trace_event/common/trace_event_common.h" ]
3918 sources += [
3919 "src/tracing/trace-categories.cc",
3920 "src/tracing/trace-categories.h",
3921 ]
3922 }
3923}
3924
3925group("v8_base") {
3926 public_deps = [
3927 ":v8_base_without_compiler",
3928 ":v8_compiler",
3929 ]
3930}
3931
3932v8_source_set("torque_base") {
3933 visibility = [ ":*" ] # Only targets in this file can depend on this.
3934
3935 sources = [
3936 "src/torque/ast.h",
3937 "src/torque/cc-generator.cc",
3938 "src/torque/cc-generator.h",
3939 "src/torque/cfg.cc",
3940 "src/torque/cfg.h",
3941 "src/torque/class-debug-reader-generator.cc",
3942 "src/torque/constants.h",
3943 "src/torque/contextual.h",
3944 "src/torque/csa-generator.cc",
3945 "src/torque/csa-generator.h",
3946 "src/torque/declarable.cc",
3947 "src/torque/declarable.h",
3948 "src/torque/declaration-visitor.cc",
3949 "src/torque/declaration-visitor.h",
3950 "src/torque/declarations.cc",
3951 "src/torque/declarations.h",
3952 "src/torque/earley-parser.cc",
3953 "src/torque/earley-parser.h",
3954 "src/torque/global-context.cc",
3955 "src/torque/global-context.h",
3956 "src/torque/implementation-visitor.cc",
3957 "src/torque/implementation-visitor.h",
3958 "src/torque/instance-type-generator.cc",
3959 "src/torque/instructions.cc",
3960 "src/torque/instructions.h",
3961 "src/torque/parameter-difference.h",
3962 "src/torque/server-data.cc",
3963 "src/torque/server-data.h",
3964 "src/torque/source-positions.cc",
3965 "src/torque/source-positions.h",
3966 "src/torque/torque-code-generator.cc",
3967 "src/torque/torque-code-generator.h",
3968 "src/torque/torque-compiler.cc",
3969 "src/torque/torque-compiler.h",
3970 "src/torque/torque-parser.cc",
3971 "src/torque/torque-parser.h",
3972 "src/torque/type-inference.cc",
3973 "src/torque/type-inference.h",
3974 "src/torque/type-oracle.cc",
3975 "src/torque/type-oracle.h",
3976 "src/torque/type-visitor.cc",
3977 "src/torque/type-visitor.h",
3978 "src/torque/types.cc",
3979 "src/torque/types.h",
3980 "src/torque/utils.cc",
3981 "src/torque/utils.h",
3982 ]
3983
3984 deps = [ ":v8_shared_internal_headers" ]
3985
3986 public_deps = [ ":v8_libbase" ]
3987
3988 # The use of exceptions for Torque in violation of the Chromium style-guide
3989 # is justified by the fact that it is only used from the non-essential
3990 # language server and can be removed anytime if it causes problems.
3991 configs = [
3992 ":internal_config",
3993 "//build/config/compiler:exceptions",
3994 "//build/config/compiler:rtti",
3995 ]
3996
3997 remove_configs = [
3998 "//build/config/compiler:no_exceptions",
3999 "//build/config/compiler:no_rtti",
4000 ]
4001
4002 if (is_win && is_asan) {
4003 # Due to a bug in ASAN on Windows (chromium:893437), we disable ASAN for
4004 # Torque on Windows.
4005 remove_configs += [ "//build/config/sanitizers:default_sanitizer_flags" ]
4006 }
4007
4008 if (is_debug && !v8_optimized_debug && v8_enable_fast_torque) {
4009 # The :no_optimize config is added to v8_add_configs in v8.gni.
4010 remove_configs += [ "//build/config/compiler:no_optimize" ]
4011 configs += [ ":always_optimize" ]
4012 }
4013}
4014
4015v8_source_set("torque_ls_base") {
4016 sources = [
4017 "src/torque/ls/globals.h",
4018 "src/torque/ls/json-parser.cc",
4019 "src/torque/ls/json-parser.h",
4020 "src/torque/ls/json.cc",
4021 "src/torque/ls/json.h",
4022 "src/torque/ls/message-handler.cc",
4023 "src/torque/ls/message-handler.h",
4024 "src/torque/ls/message-macros.h",
4025 "src/torque/ls/message-pipe.h",
4026 "src/torque/ls/message.h",
4027 ]
4028
4029 public_deps = [ ":torque_base" ]
4030
4031 # The use of exceptions for Torque in violation of the Chromium style-guide
4032 # is justified by the fact that it is only used from the non-essential
4033 # language server and can be removed anytime if it causes problems.
4034 configs = [
4035 ":internal_config",
4036 "//build/config/compiler:exceptions",
4037 "//build/config/compiler:rtti",
4038 ]
4039
4040 remove_configs = [
4041 "//build/config/compiler:no_exceptions",
4042 "//build/config/compiler:no_rtti",
4043 ]
4044
4045 if (is_win && is_asan) {
4046 remove_configs += [ "//build/config/sanitizers:default_sanitizer_flags" ]
Ben Murdochf3b273f2017-01-17 12:11:28 +00004047 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004048}
4049
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004050v8_component("v8_libbase") {
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004051 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00004052 "src/base/address-region.h",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004053 "src/base/atomic-utils.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004054 "src/base/atomicops.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004055 "src/base/atomicops_internals_atomicword_compat.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004056 "src/base/atomicops_internals_portable.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004057 "src/base/atomicops_internals_std.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004058 "src/base/base-export.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004059 "src/base/bit-field.h",
4060 "src/base/bits-iterator.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004061 "src/base/bits.cc",
4062 "src/base/bits.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004063 "src/base/bounded-page-allocator.cc",
4064 "src/base/bounded-page-allocator.h",
4065 "src/base/bounds.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004066 "src/base/build_config.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00004067 "src/base/compiler-specific.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004068 "src/base/cpu.cc",
4069 "src/base/cpu.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00004070 "src/base/debug/stack_trace.cc",
4071 "src/base/debug/stack_trace.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004072 "src/base/division-by-constant.cc",
4073 "src/base/division-by-constant.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004074 "src/base/enum-set.h",
4075 "src/base/export-template.h",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004076 "src/base/file-utils.cc",
4077 "src/base/file-utils.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004078 "src/base/flags.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00004079 "src/base/free_deleter.h",
Emily Bernier958fae72015-03-24 16:35:39 -04004080 "src/base/functional.cc",
4081 "src/base/functional.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00004082 "src/base/hashmap-entry.h",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004083 "src/base/hashmap.h",
4084 "src/base/ieee754.cc",
4085 "src/base/ieee754.h",
Emily Bernier958fae72015-03-24 16:35:39 -04004086 "src/base/iterator.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004087 "src/base/lazy-instance.h",
4088 "src/base/logging.cc",
4089 "src/base/logging.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004090 "src/base/lsan.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004091 "src/base/macros.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004092 "src/base/memory.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004093 "src/base/once.cc",
4094 "src/base/once.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004095 "src/base/optional.h",
4096 "src/base/overflowing-math.h",
4097 "src/base/page-allocator.cc",
4098 "src/base/page-allocator.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004099 "src/base/platform/condition-variable.cc",
4100 "src/base/platform/condition-variable.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01004101 "src/base/platform/elapsed-timer.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004102 "src/base/platform/mutex.cc",
4103 "src/base/platform/mutex.h",
4104 "src/base/platform/platform.h",
4105 "src/base/platform/semaphore.cc",
4106 "src/base/platform/semaphore.h",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01004107 "src/base/platform/time.cc",
4108 "src/base/platform/time.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004109 "src/base/platform/wrappers.h",
4110 "src/base/platform/wrappers_std.cc",
4111 "src/base/region-allocator.cc",
4112 "src/base/region-allocator.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004113 "src/base/ring-buffer.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004114 "src/base/safe_conversions.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004115 "src/base/safe_conversions_arm_impl.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004116 "src/base/safe_conversions_impl.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004117 "src/base/small-vector.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004118 "src/base/sys-info.cc",
4119 "src/base/sys-info.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004120 "src/base/template-utils.h",
4121 "src/base/timezone-cache.h",
4122 "src/base/type-traits.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004123 "src/base/utils/random-number-generator.cc",
4124 "src/base/utils/random-number-generator.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004125 "src/base/vlq-base64.cc",
4126 "src/base/vlq-base64.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004127 ]
4128
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004129 configs = [ ":internal_config_base" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004130
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004131 public_configs = [ ":libbase_config" ]
4132
Rubin Xu7bc1b612021-02-16 09:38:50 +00004133 deps = [ ":v8_headers" ]
4134
4135 public_deps = []
4136
4137 data = []
4138
4139 data_deps = []
4140
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004141 defines = []
4142
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004143 if (is_component_build) {
4144 defines = [ "BUILDING_V8_BASE_SHARED" ]
4145 }
4146
Rubin Xu7bc1b612021-02-16 09:38:50 +00004147 if (is_posix || is_fuchsia) {
4148 sources += [
4149 "src/base/platform/platform-posix.cc",
4150 "src/base/platform/platform-posix.h",
4151 ]
4152 if (current_os != "aix") {
4153 sources += [
4154 "src/base/platform/platform-posix-time.cc",
4155 "src/base/platform/platform-posix-time.h",
4156 ]
4157 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004158 }
4159
Rubin Xu7bc1b612021-02-16 09:38:50 +00004160 if (is_linux || is_chromeos) {
Ben Murdochf91f0612016-11-29 16:50:11 +00004161 sources += [
4162 "src/base/debug/stack_trace_posix.cc",
4163 "src/base/platform/platform-linux.cc",
4164 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004165
Ben Murdoch3b9bc312016-06-02 14:46:10 +01004166 libs = [
4167 "dl",
4168 "rt",
4169 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00004170 } else if (current_os == "aix") {
4171 sources += [
4172 "src/base/debug/stack_trace_posix.cc",
4173 "src/base/platform/platform-aix.cc",
4174 ]
4175
4176 libs = [
4177 "dl",
4178 "rt",
4179 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004180 } else if (is_android) {
Ben Murdoch014dc512016-03-22 12:00:34 +00004181 if (current_toolchain == host_toolchain) {
Ben Murdoch3b9bc312016-06-02 14:46:10 +01004182 libs = [
4183 "dl",
4184 "rt",
4185 ]
Ben Murdoch014dc512016-03-22 12:00:34 +00004186 if (host_os == "mac") {
Ben Murdochf91f0612016-11-29 16:50:11 +00004187 sources += [
4188 "src/base/debug/stack_trace_posix.cc",
4189 "src/base/platform/platform-macos.cc",
4190 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004191 } else {
Ben Murdochf91f0612016-11-29 16:50:11 +00004192 sources += [
4193 "src/base/debug/stack_trace_posix.cc",
4194 "src/base/platform/platform-linux.cc",
4195 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004196 }
4197 } else {
Ben Murdochf91f0612016-11-29 16:50:11 +00004198 sources += [
4199 "src/base/debug/stack_trace_android.cc",
4200 "src/base/platform/platform-linux.cc",
4201 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004202 }
Rubin Xu7bc1b612021-02-16 09:38:50 +00004203 } else if (is_fuchsia) {
4204 sources += [
4205 "src/base/debug/stack_trace_fuchsia.cc",
4206 "src/base/platform/platform-fuchsia.cc",
4207 ]
4208 } else if (is_mac || is_ios) {
Ben Murdochf91f0612016-11-29 16:50:11 +00004209 sources += [
4210 "src/base/debug/stack_trace_posix.cc",
4211 "src/base/platform/platform-macos.cc",
4212 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004213 } else if (is_win) {
4214 # TODO(jochen): Add support for cygwin.
4215 sources += [
Ben Murdochf91f0612016-11-29 16:50:11 +00004216 "src/base/debug/stack_trace_win.cc",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004217 "src/base/platform/platform-win32.cc",
4218 "src/base/win32-headers.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004219 ]
4220
4221 defines += [ "_CRT_RAND_S" ] # for rand_s()
4222
Ben Murdoch014dc512016-03-22 12:00:34 +00004223 libs = [
Ben Murdochf91f0612016-11-29 16:50:11 +00004224 "dbghelp.lib",
Ben Murdoch014dc512016-03-22 12:00:34 +00004225 "winmm.lib",
4226 "ws2_32.lib",
4227 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00004228
4229 data_deps += [ "//build/win:runtime_libs" ]
4230 }
4231
4232 if (v8_current_cpu == "mips" || v8_current_cpu == "mips64") {
4233 # Add runtime libs for mips.
4234 data += [
4235 "tools/mips_toolchain/sysroot/usr/lib/",
4236 "tools/mips_toolchain/mips-mti-linux-gnu/lib",
4237 ]
4238 }
4239
4240 if (is_ubsan && (v8_current_cpu == "x86" || v8_current_cpu == "arm" ||
4241 v8_current_cpu == "mips")) {
4242 # Special UBSan 32-bit requirement.
4243 sources += [ "src/base/ubsan.cc" ]
4244 }
4245
4246 if (is_tsan && !build_with_chromium) {
4247 data += [ "tools/sanitizers/tsan_suppressions.txt" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004248 }
4249
4250 # TODO(jochen): Add support for qnx, freebsd, openbsd, netbsd, and solaris.
4251}
4252
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004253v8_component("v8_libplatform") {
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004254 sources = [
Ben Murdochf91f0612016-11-29 16:50:11 +00004255 "//base/trace_event/common/trace_event_common.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004256 "include/libplatform/libplatform-export.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004257 "include/libplatform/libplatform.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00004258 "include/libplatform/v8-tracing.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004259 "src/libplatform/default-foreground-task-runner.cc",
4260 "src/libplatform/default-foreground-task-runner.h",
4261 "src/libplatform/default-job.cc",
4262 "src/libplatform/default-job.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004263 "src/libplatform/default-platform.cc",
4264 "src/libplatform/default-platform.h",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004265 "src/libplatform/default-worker-threads-task-runner.cc",
4266 "src/libplatform/default-worker-threads-task-runner.h",
4267 "src/libplatform/delayed-task-queue.cc",
4268 "src/libplatform/delayed-task-queue.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004269 "src/libplatform/task-queue.cc",
4270 "src/libplatform/task-queue.h",
Ben Murdochf91f0612016-11-29 16:50:11 +00004271 "src/libplatform/tracing/trace-buffer.cc",
4272 "src/libplatform/tracing/trace-buffer.h",
4273 "src/libplatform/tracing/trace-config.cc",
4274 "src/libplatform/tracing/trace-object.cc",
4275 "src/libplatform/tracing/trace-writer.cc",
4276 "src/libplatform/tracing/trace-writer.h",
4277 "src/libplatform/tracing/tracing-controller.cc",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004278 "src/libplatform/worker-thread.cc",
4279 "src/libplatform/worker-thread.h",
4280 ]
4281
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004282 configs = [ ":internal_config_base" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004283
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004284 if (is_component_build) {
4285 defines = [ "BUILDING_V8_PLATFORM_SHARED" ]
4286 }
4287
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004288 public_configs = [ ":libplatform_config" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004289
4290 deps = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00004291 ":v8_headers",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004292 ":v8_libbase",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004293 ":v8_tracing",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004294 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00004295
4296 if (v8_use_perfetto) {
4297 sources -= [
4298 "//base/trace_event/common/trace_event_common.h",
4299 "src/libplatform/tracing/trace-buffer.cc",
4300 "src/libplatform/tracing/trace-buffer.h",
4301 "src/libplatform/tracing/trace-object.cc",
4302 "src/libplatform/tracing/trace-writer.cc",
4303 "src/libplatform/tracing/trace-writer.h",
4304 ]
4305 sources += [
4306 "src/libplatform/tracing/trace-event-listener.cc",
4307 "src/libplatform/tracing/trace-event-listener.h",
4308 ]
4309 deps += [
4310 # TODO(skyostil): Switch TraceEventListener to protozero.
4311 "//third_party/perfetto/protos/perfetto/trace:lite",
4312 ]
4313 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004314}
4315
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004316v8_source_set("v8_libsampler") {
4317 sources = [
Ben Murdochf91f0612016-11-29 16:50:11 +00004318 "src/libsampler/sampler.cc",
4319 "src/libsampler/sampler.h",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004320 ]
4321
Rubin Xu7bc1b612021-02-16 09:38:50 +00004322 configs = [ ":internal_config" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004323
4324 public_configs = [ ":libsampler_config" ]
4325
Rubin Xu7bc1b612021-02-16 09:38:50 +00004326 deps = [ ":v8_libbase" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004327}
4328
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004329v8_source_set("fuzzer_support") {
Ben Murdoch109988c2016-05-18 11:27:45 +01004330 visibility = [ ":*" ] # Only targets in this file can depend on this.
4331
4332 sources = [
4333 "test/fuzzer/fuzzer-support.cc",
4334 "test/fuzzer/fuzzer-support.h",
4335 ]
4336
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004337 configs = [ ":internal_config_base" ]
Ben Murdoch109988c2016-05-18 11:27:45 +01004338
Rubin Xu7bc1b612021-02-16 09:38:50 +00004339 public_deps = [
Ben Murdochf3b273f2017-01-17 12:11:28 +00004340 ":v8",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004341 ":v8_libbase",
4342 ":v8_libplatform",
4343 ":v8_maybe_icu",
4344 ]
4345}
4346
4347v8_source_set("v8_cppgc_shared") {
4348 sources = [
4349 "src/heap/base/stack.cc",
4350 "src/heap/base/stack.h",
4351 "src/heap/base/worklist.cc",
4352 "src/heap/base/worklist.h",
4353 ]
4354
4355 if (is_clang || !is_win) {
4356 if (current_cpu == "x64") {
4357 sources += [ "src/heap/base/asm/x64/push_registers_asm.cc" ]
4358 } else if (current_cpu == "x86") {
4359 sources += [ "src/heap/base/asm/ia32/push_registers_asm.cc" ]
4360 } else if (current_cpu == "arm") {
4361 sources += [ "src/heap/base/asm/arm/push_registers_asm.cc" ]
4362 } else if (current_cpu == "arm64") {
4363 sources += [ "src/heap/base/asm/arm64/push_registers_asm.cc" ]
4364 } else if (current_cpu == "ppc64") {
4365 sources += [ "src/heap/base/asm/ppc/push_registers_asm.cc" ]
4366 } else if (current_cpu == "s390x") {
4367 sources += [ "src/heap/base/asm/s390/push_registers_asm.cc" ]
4368 } else if (current_cpu == "mipsel") {
4369 sources += [ "src/heap/base/asm/mips/push_registers_asm.cc" ]
4370 } else if (current_cpu == "mips64el") {
4371 sources += [ "src/heap/base/asm/mips64/push_registers_asm.cc" ]
4372 }
4373 } else if (is_win) {
4374 if (current_cpu == "x64") {
4375 sources += [ "src/heap/base/asm/x64/push_registers_masm.S" ]
4376 } else if (current_cpu == "x86") {
4377 sources += [ "src/heap/base/asm/ia32/push_registers_masm.S" ]
4378 } else if (current_cpu == "arm64") {
4379 sources += [ "src/heap/base/asm/arm64/push_registers_masm.S" ]
4380 }
4381 }
4382
4383 configs = [ ":internal_config" ]
4384
4385 public_deps = [ ":v8_libbase" ]
4386}
4387
4388v8_source_set("cppgc_base") {
4389 visibility = [ ":*" ]
4390
4391 sources = [
4392 "include/cppgc/allocation.h",
4393 "include/cppgc/common.h",
4394 "include/cppgc/custom-space.h",
4395 "include/cppgc/default-platform.h",
4396 "include/cppgc/ephemeron-pair.h",
4397 "include/cppgc/garbage-collected.h",
4398 "include/cppgc/heap.h",
4399 "include/cppgc/internal/api-constants.h",
4400 "include/cppgc/internal/atomic-entry-flag.h",
4401 "include/cppgc/internal/compiler-specific.h",
4402 "include/cppgc/internal/finalizer-trait.h",
4403 "include/cppgc/internal/gc-info.h",
4404 "include/cppgc/internal/name-trait.h",
4405 "include/cppgc/internal/persistent-node.h",
4406 "include/cppgc/internal/pointer-policies.h",
4407 "include/cppgc/internal/prefinalizer-handler.h",
4408 "include/cppgc/internal/process-heap.h",
4409 "include/cppgc/internal/write-barrier.h",
4410 "include/cppgc/liveness-broker.h",
4411 "include/cppgc/macros.h",
4412 "include/cppgc/member.h",
4413 "include/cppgc/name-provider.h",
4414 "include/cppgc/persistent.h",
4415 "include/cppgc/platform.h",
4416 "include/cppgc/prefinalizer.h",
4417 "include/cppgc/source-location.h",
4418 "include/cppgc/trace-trait.h",
4419 "include/cppgc/type-traits.h",
4420 "include/cppgc/visitor.h",
4421 "include/v8config.h",
4422 "src/heap/cppgc/allocation.cc",
4423 "src/heap/cppgc/compaction-worklists.cc",
4424 "src/heap/cppgc/compaction-worklists.h",
4425 "src/heap/cppgc/compactor.cc",
4426 "src/heap/cppgc/compactor.h",
4427 "src/heap/cppgc/concurrent-marker.cc",
4428 "src/heap/cppgc/concurrent-marker.h",
4429 "src/heap/cppgc/free-list.cc",
4430 "src/heap/cppgc/free-list.h",
4431 "src/heap/cppgc/garbage-collector.h",
4432 "src/heap/cppgc/gc-info-table.cc",
4433 "src/heap/cppgc/gc-info-table.h",
4434 "src/heap/cppgc/gc-info.cc",
4435 "src/heap/cppgc/gc-invoker.cc",
4436 "src/heap/cppgc/gc-invoker.h",
4437 "src/heap/cppgc/heap-base.cc",
4438 "src/heap/cppgc/heap-base.h",
4439 "src/heap/cppgc/heap-growing.cc",
4440 "src/heap/cppgc/heap-growing.h",
4441 "src/heap/cppgc/heap-object-header.cc",
4442 "src/heap/cppgc/heap-object-header.h",
4443 "src/heap/cppgc/heap-page.cc",
4444 "src/heap/cppgc/heap-page.h",
4445 "src/heap/cppgc/heap-space.cc",
4446 "src/heap/cppgc/heap-space.h",
4447 "src/heap/cppgc/heap-visitor.h",
4448 "src/heap/cppgc/heap.cc",
4449 "src/heap/cppgc/heap.h",
4450 "src/heap/cppgc/incremental-marking-schedule.cc",
4451 "src/heap/cppgc/incremental-marking-schedule.h",
4452 "src/heap/cppgc/liveness-broker.cc",
4453 "src/heap/cppgc/liveness-broker.h",
4454 "src/heap/cppgc/logging.cc",
4455 "src/heap/cppgc/marker.cc",
4456 "src/heap/cppgc/marker.h",
4457 "src/heap/cppgc/marking-state.cc",
4458 "src/heap/cppgc/marking-state.h",
4459 "src/heap/cppgc/marking-verifier.cc",
4460 "src/heap/cppgc/marking-verifier.h",
4461 "src/heap/cppgc/marking-visitor.cc",
4462 "src/heap/cppgc/marking-visitor.h",
4463 "src/heap/cppgc/marking-worklists.cc",
4464 "src/heap/cppgc/marking-worklists.h",
4465 "src/heap/cppgc/name-trait.cc",
4466 "src/heap/cppgc/object-allocator.cc",
4467 "src/heap/cppgc/object-allocator.h",
4468 "src/heap/cppgc/object-start-bitmap.h",
4469 "src/heap/cppgc/page-memory.cc",
4470 "src/heap/cppgc/page-memory.h",
4471 "src/heap/cppgc/persistent-node.cc",
4472 "src/heap/cppgc/platform.cc",
4473 "src/heap/cppgc/pointer-policies.cc",
4474 "src/heap/cppgc/prefinalizer-handler.cc",
4475 "src/heap/cppgc/prefinalizer-handler.h",
4476 "src/heap/cppgc/process-heap.cc",
4477 "src/heap/cppgc/process-heap.h",
4478 "src/heap/cppgc/raw-heap.cc",
4479 "src/heap/cppgc/raw-heap.h",
4480 "src/heap/cppgc/sanitizers.h",
4481 "src/heap/cppgc/source-location.cc",
4482 "src/heap/cppgc/stats-collector.cc",
4483 "src/heap/cppgc/stats-collector.h",
4484 "src/heap/cppgc/sweeper.cc",
4485 "src/heap/cppgc/sweeper.h",
4486 "src/heap/cppgc/task-handle.h",
4487 "src/heap/cppgc/trace-trait.cc",
4488 "src/heap/cppgc/virtual-memory.cc",
4489 "src/heap/cppgc/virtual-memory.h",
4490 "src/heap/cppgc/visitor.cc",
4491 "src/heap/cppgc/write-barrier.cc",
4492 ]
4493
4494 if (cppgc_enable_caged_heap) {
4495 sources += [
4496 "include/cppgc/internal/caged-heap-local-data.h",
4497 "src/heap/cppgc/caged-heap-local-data.cc",
4498 "src/heap/cppgc/caged-heap.cc",
4499 "src/heap/cppgc/caged-heap.h",
4500 ]
4501 }
4502
4503 configs = [
4504 ":internal_config",
4505 ":cppgc_base_config",
Ben Murdochf3b273f2017-01-17 12:11:28 +00004506 ]
4507
4508 public_deps = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00004509 ":v8_cppgc_shared",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004510 ":v8_libbase",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004511 ":v8_libplatform",
4512 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00004513}
Ben Murdoch109988c2016-05-18 11:27:45 +01004514
Rubin Xu7bc1b612021-02-16 09:38:50 +00004515###############################################################################
4516# Produce a single static library for embedders
4517#
4518
4519if (v8_monolithic) {
4520 # A component build is not monolithic.
4521 assert(!is_component_build)
4522
4523 # Using external startup data would produce separate files.
4524 assert(!v8_use_external_startup_data)
4525 v8_static_library("v8_monolith") {
4526 deps = [
4527 ":v8",
4528 ":v8_libbase",
4529 ":v8_libplatform",
4530 ":v8_libsampler",
4531 "//build/win:default_exe_manifest",
4532 ]
4533
4534 configs = [ ":internal_config" ]
Ben Murdoch62ed6312017-06-06 11:06:27 +01004535 }
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004536}
4537
Rubin Xu7bc1b612021-02-16 09:38:50 +00004538v8_static_library("wee8") {
4539 deps = [
4540 ":v8_base",
4541 ":v8_libbase",
4542 ":v8_libplatform",
4543 ":v8_libsampler",
4544 ":v8_snapshot",
4545 "//build/win:default_exe_manifest",
4546 ]
4547
4548 # TODO: v8dll-main.cc equivalent for shared library builds
4549
4550 configs = [ ":internal_config" ]
4551
4552 sources = [
4553 ### gcmole(all) ###
4554 "src/wasm/c-api.cc",
4555 "src/wasm/c-api.h",
4556 "third_party/wasm-api/wasm.h",
4557 "third_party/wasm-api/wasm.hh",
4558 ]
4559}
4560
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004561###############################################################################
4562# Executables
4563#
4564
Rubin Xu7bc1b612021-02-16 09:38:50 +00004565if (current_toolchain == v8_generator_toolchain) {
4566 v8_executable("bytecode_builtins_list_generator") {
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004567 visibility = [ ":*" ] # Only targets in this file can depend on this.
4568
Rubin Xu7bc1b612021-02-16 09:38:50 +00004569 include_dirs = [ "." ]
4570
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004571 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00004572 "src/builtins/generate-bytecodes-builtins-list.cc",
4573 "src/interpreter/bytecode-operands.cc",
4574 "src/interpreter/bytecode-operands.h",
4575 "src/interpreter/bytecodes.cc",
4576 "src/interpreter/bytecodes.h",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004577 ]
4578
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004579 configs = [ ":internal_config" ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004580
4581 deps = [
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004582 ":v8_libbase",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004583 "//build/win:default_exe_manifest",
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004584 ]
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004585 }
4586}
4587
Rubin Xu7bc1b612021-02-16 09:38:50 +00004588if (current_toolchain == v8_snapshot_toolchain) {
4589 v8_executable("mksnapshot") {
4590 visibility = [ ":*" ] # Only targets in this file can depend on this.
4591
4592 sources = [
4593 "src/snapshot/embedded/embedded-empty.cc",
4594 "src/snapshot/embedded/embedded-file-writer.cc",
4595 "src/snapshot/embedded/embedded-file-writer.h",
4596 "src/snapshot/embedded/platform-embedded-file-writer-aix.cc",
4597 "src/snapshot/embedded/platform-embedded-file-writer-aix.h",
4598 "src/snapshot/embedded/platform-embedded-file-writer-base.cc",
4599 "src/snapshot/embedded/platform-embedded-file-writer-base.h",
4600 "src/snapshot/embedded/platform-embedded-file-writer-generic.cc",
4601 "src/snapshot/embedded/platform-embedded-file-writer-generic.h",
4602 "src/snapshot/embedded/platform-embedded-file-writer-mac.cc",
4603 "src/snapshot/embedded/platform-embedded-file-writer-mac.h",
4604 "src/snapshot/embedded/platform-embedded-file-writer-win.cc",
4605 "src/snapshot/embedded/platform-embedded-file-writer-win.h",
4606 "src/snapshot/mksnapshot.cc",
4607 "src/snapshot/snapshot-empty.cc",
4608 ]
4609
4610 if (v8_control_flow_integrity) {
4611 sources += [ "src/deoptimizer/deoptimizer-cfi-empty.cc" ]
4612 }
4613
4614 configs = [ ":internal_config" ]
4615
4616 deps = [
4617 ":v8_base_without_compiler",
4618 ":v8_compiler_for_mksnapshot",
4619 ":v8_init",
4620 ":v8_libbase",
4621 ":v8_libplatform",
4622 ":v8_maybe_icu",
4623 ":v8_tracing",
4624 "//build/win:default_exe_manifest",
4625 ]
4626 }
4627}
4628
4629if (current_toolchain == v8_snapshot_toolchain) {
4630 v8_executable("torque") {
4631 visibility = [ ":*" ] # Only targets in this file can depend on this.
4632
4633 sources = [ "src/torque/torque.cc" ]
4634
4635 deps = [
4636 ":torque_base",
4637 "//build/win:default_exe_manifest",
4638 ]
4639
4640 # The use of exceptions for Torque in violation of the Chromium style-guide
4641 # is justified by the fact that it is only used from the non-essential
4642 # language server and can be removed anytime if it causes problems.
4643 configs = [
4644 ":internal_config",
4645 "//build/config/compiler:exceptions",
4646 "//build/config/compiler:rtti",
4647 ]
4648
4649 remove_configs = [
4650 "//build/config/compiler:no_exceptions",
4651 "//build/config/compiler:no_rtti",
4652 ]
4653
4654 if (is_win && is_asan) {
4655 remove_configs += [ "//build/config/sanitizers:default_sanitizer_flags" ]
4656 }
4657 }
4658}
4659
4660v8_executable("torque-language-server") {
Ben Murdochf91f0612016-11-29 16:50:11 +00004661 visibility = [ ":*" ] # Only targets in this file can depend on this.
4662
Rubin Xu7bc1b612021-02-16 09:38:50 +00004663 sources = [ "src/torque/ls/torque-language-server.cc" ]
Ben Murdochf91f0612016-11-29 16:50:11 +00004664
4665 deps = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00004666 ":torque_base",
4667 ":torque_ls_base",
Ben Murdochf91f0612016-11-29 16:50:11 +00004668 "//build/win:default_exe_manifest",
4669 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00004670
4671 # The use of exceptions for Torque in violation of the Chromium style-guide
4672 # is justified by the fact that it is only used from the non-essential
4673 # language server and can be removed anytime if it causes problems.
4674 configs = [
4675 ":internal_config",
4676 "//build/config/compiler:exceptions",
4677 "//build/config/compiler:rtti",
4678 ]
4679
4680 remove_configs = [
4681 "//build/config/compiler:no_exceptions",
4682 "//build/config/compiler:no_rtti",
4683 ]
4684
4685 if (is_win && is_asan) {
4686 remove_configs += [ "//build/config/sanitizers:default_sanitizer_flags" ]
4687 }
4688}
4689
4690if (v8_enable_i18n_support) {
4691 if (current_toolchain == v8_generator_toolchain) {
4692 v8_executable("gen-regexp-special-case") {
4693 visibility = [ ":*" ] # Only targets in this file can depend on this.
4694
4695 sources = [ "src/regexp/gen-regexp-special-case.cc" ]
4696
4697 deps = [
4698 ":v8_libbase",
4699 "//build/win:default_exe_manifest",
4700 "//third_party/icu",
4701 ]
4702
4703 configs = [ ":internal_config" ]
4704 }
4705 }
4706
4707 action("run_gen-regexp-special-case") {
4708 visibility = [ ":*" ] # Only targets in this file can depend on this.
4709
4710 script = "tools/run.py"
4711
4712 deps = [ ":gen-regexp-special-case($v8_generator_toolchain)" ]
4713
4714 output_file = "$target_gen_dir/src/regexp/special-case.cc"
4715
4716 outputs = [ output_file ]
4717
4718 args = [
4719 "./" + rebase_path(
4720 get_label_info(
4721 ":gen-regexp-special-case($v8_generator_toolchain)",
4722 "root_out_dir") + "/gen-regexp-special-case",
4723 root_build_dir),
4724 rebase_path(output_file, root_build_dir),
4725 ]
4726 }
Ben Murdochf91f0612016-11-29 16:50:11 +00004727}
4728
Ben Murdochb8a8cc12014-11-26 15:28:44 +00004729###############################################################################
4730# Public targets
4731#
4732
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004733want_v8_shell =
4734 (current_toolchain == host_toolchain && v8_toolset_for_shell == "host") ||
4735 (current_toolchain == v8_snapshot_toolchain &&
4736 v8_toolset_for_shell == "host") ||
4737 (current_toolchain != host_toolchain && v8_toolset_for_shell == "target")
4738
4739group("gn_all") {
4740 testonly = true
4741
4742 deps = [
4743 ":d8",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004744 ":v8_fuzzers",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004745 ":v8_hello_world",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004746 ":v8_sample_process",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004747 "test:gn_all",
4748 "tools:gn_all",
4749 ]
4750
Rubin Xu7bc1b612021-02-16 09:38:50 +00004751 if (v8_custom_deps != "") {
4752 # Custom dependency from directory under v8/custom_deps.
4753 deps += [ v8_custom_deps ]
4754 }
4755
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004756 if (want_v8_shell) {
4757 deps += [ ":v8_shell" ]
4758 }
Rubin Xu7bc1b612021-02-16 09:38:50 +00004759}
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004760
Rubin Xu7bc1b612021-02-16 09:38:50 +00004761group("v8_python_base") {
4762 data = [ ".vpython" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004763}
4764
Ben Murdoch62ed6312017-06-06 11:06:27 +01004765group("v8_clusterfuzz") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00004766 testonly = true
4767
4768 deps = [ ":d8" ]
Ben Murdoch62ed6312017-06-06 11:06:27 +01004769
4770 if (v8_multi_arch_build) {
4771 deps += [
4772 ":d8(//build/toolchain/linux:clang_x64)",
4773 ":d8(//build/toolchain/linux:clang_x64_v8_arm64)",
4774 ":d8(//build/toolchain/linux:clang_x86)",
4775 ":d8(//build/toolchain/linux:clang_x86_v8_arm)",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004776 ":d8(tools/clusterfuzz/toolchain:clang_x64_pointer_compression)",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004777 ]
4778 }
4779}
4780
Rubin Xu7bc1b612021-02-16 09:38:50 +00004781group("v8_archive") {
4782 testonly = true
4783
4784 deps = [ ":d8" ]
4785
4786 if (!is_win) {
4787 # On windows, cctest doesn't link with v8_static_library.
4788 deps += [ "test/cctest:cctest" ]
4789 }
4790}
4791
4792# TODO(dglazkov): Remove the "!build_with_chromium" condition once this clause
4793# is removed from Chromium.
4794if (is_fuchsia && !build_with_chromium) {
4795 import("//build/config/fuchsia/rules.gni")
4796
4797 cr_fuchsia_package("d8_fuchsia_pkg") {
4798 testonly = true
4799 binary = ":d8"
4800 package_name_override = "d8"
4801 }
4802
4803 fuchsia_package_runner("d8_fuchsia") {
4804 testonly = true
4805 package = ":d8_fuchsia_pkg"
4806 package_name_override = "d8"
4807 }
4808}
4809
Ben Murdoch62ed6312017-06-06 11:06:27 +01004810group("v8_fuzzers") {
4811 testonly = true
Rubin Xu7bc1b612021-02-16 09:38:50 +00004812 data_deps = [
4813 ":v8_simple_inspector_fuzzer",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004814 ":v8_simple_json_fuzzer",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004815 ":v8_simple_multi_return_fuzzer",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004816 ":v8_simple_parser_fuzzer",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004817 ":v8_simple_regexp_builtins_fuzzer",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004818 ":v8_simple_regexp_fuzzer",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004819 ":v8_simple_wasm_async_fuzzer",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004820 ":v8_simple_wasm_code_fuzzer",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004821 ":v8_simple_wasm_compile_fuzzer",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004822 ":v8_simple_wasm_fuzzer",
Ben Murdoch62ed6312017-06-06 11:06:27 +01004823 ]
4824}
4825
Ben Murdoch014dc512016-03-22 12:00:34 +00004826if (is_component_build) {
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004827 v8_component("v8") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00004828 sources = [ "src/utils/v8dll-main.cc" ]
Ben Murdochf91f0612016-11-29 16:50:11 +00004829
Ben Murdoch014dc512016-03-22 12:00:34 +00004830 public_deps = [
4831 ":v8_base",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004832 ":v8_snapshot",
Ben Murdoch014dc512016-03-22 12:00:34 +00004833 ]
4834
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004835 configs = [ ":internal_config" ]
Ben Murdoch014dc512016-03-22 12:00:34 +00004836
4837 public_configs = [ ":external_config" ]
Ben Murdoch014dc512016-03-22 12:00:34 +00004838 }
Rubin Xu7bc1b612021-02-16 09:38:50 +00004839
4840 v8_component("v8_for_testing") {
4841 testonly = true
4842
4843 sources = [ "src/utils/v8dll-main.cc" ]
Ben Murdochf91f0612016-11-29 16:50:11 +00004844
Ben Murdoch014dc512016-03-22 12:00:34 +00004845 public_deps = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00004846 ":torque_base",
4847 ":torque_ls_base",
Ben Murdoch014dc512016-03-22 12:00:34 +00004848 ":v8_base",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004849 ":v8_headers",
4850 ":v8_initializers",
4851 ":v8_snapshot",
Ben Murdoch014dc512016-03-22 12:00:34 +00004852 ]
Ben Murdoch62ed6312017-06-06 11:06:27 +01004853
Rubin Xu7bc1b612021-02-16 09:38:50 +00004854 configs = [ ":internal_config" ]
4855
4856 public_configs = [ ":external_config" ]
4857 }
4858
4859 v8_component("cppgc") {
4860 public_deps = [ ":cppgc_base" ]
4861
4862 configs = [ ":internal_config" ]
4863
4864 public_configs = [ ":external_config" ]
4865 }
4866
4867 v8_component("cppgc_for_testing") {
4868 testonly = true
4869
4870 public_deps = [ ":cppgc_base" ]
4871
4872 configs = [ ":internal_config" ]
4873 public_configs = [ ":external_config" ]
4874 }
4875
4876 v8_component("v8_cppgc_shared_for_testing") {
4877 testonly = true
4878
4879 public_deps = [ ":v8_cppgc_shared" ]
4880
4881 configs = [ ":internal_config" ]
4882 public_configs = [ ":external_config" ]
4883 }
4884} else {
4885 group("v8") {
4886 public_deps = [
4887 ":v8_base",
4888 ":v8_snapshot",
4889 ]
4890
4891 public_configs = [ ":external_config" ]
4892 }
4893
4894 group("v8_for_testing") {
4895 testonly = true
4896
4897 public_deps = [
4898 ":torque_base",
4899 ":torque_ls_base",
4900 ":v8_base",
4901 ":v8_initializers",
4902 ":v8_snapshot",
4903 ]
4904
4905 public_configs = [ ":external_config" ]
4906 }
4907
4908 group("cppgc") {
4909 public_deps = [ ":cppgc_base" ]
4910
4911 public_configs = [ ":external_config" ]
4912 }
4913
4914 group("cppgc_for_testing") {
4915 testonly = true
4916
4917 public_deps = [ ":cppgc_base" ]
4918
4919 public_configs = [ ":external_config" ]
4920 }
4921
4922 group("v8_cppgc_shared_for_testing") {
4923 testonly = true
4924
4925 public_deps = [ ":v8_cppgc_shared" ]
4926
Ben Murdoch014dc512016-03-22 12:00:34 +00004927 public_configs = [ ":external_config" ]
4928 }
4929}
4930
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004931v8_executable("d8") {
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004932 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00004933 "src/d8/async-hooks-wrapper.cc",
4934 "src/d8/async-hooks-wrapper.h",
4935 "src/d8/d8-console.cc",
4936 "src/d8/d8-console.h",
4937 "src/d8/d8-js.cc",
4938 "src/d8/d8-platforms.cc",
4939 "src/d8/d8-platforms.h",
4940 "src/d8/d8.cc",
4941 "src/d8/d8.h",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004942 ]
4943
Rubin Xu7bc1b612021-02-16 09:38:50 +00004944 if (v8_fuzzilli) {
4945 sources += [
4946 "src/d8/cov.cc",
4947 "src/d8/cov.h",
4948 ]
4949 }
4950
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004951 configs = [
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004952 # Note: don't use :internal_config here because this target will get
4953 # the :external_config applied to it by virtue of depending on :v8, and
4954 # you can't have both applied to the same target.
4955 ":internal_config_base",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004956 ":v8_tracing_config",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004957 ]
4958
4959 deps = [
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004960 ":v8",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004961 ":v8_libbase",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004962 ":v8_libplatform",
Rubin Xu7bc1b612021-02-16 09:38:50 +00004963 ":v8_tracing",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004964 "//build/win:default_exe_manifest",
4965 ]
4966
Rubin Xu7bc1b612021-02-16 09:38:50 +00004967 if (is_posix || is_fuchsia) {
4968 sources += [ "src/d8/d8-posix.cc" ]
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004969 } else if (is_win) {
Rubin Xu7bc1b612021-02-16 09:38:50 +00004970 sources += [ "src/d8/d8-windows.cc" ]
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004971 }
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004972
Ben Murdoch62ed6312017-06-06 11:06:27 +01004973 if (v8_correctness_fuzzer) {
Rubin Xu7bc1b612021-02-16 09:38:50 +00004974 deps += [ "tools/clusterfuzz:v8_correctness_fuzzer_resources" ]
Ben Murdoch62ed6312017-06-06 11:06:27 +01004975 }
4976
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004977 defines = []
Ben Murdoch62ed6312017-06-06 11:06:27 +01004978
4979 if (v8_enable_vtunejit) {
Rubin Xu7bc1b612021-02-16 09:38:50 +00004980 deps += [ "src/third_party/vtune:v8_vtune" ]
Ben Murdoch62ed6312017-06-06 11:06:27 +01004981 }
Ben Murdochbcf72ee2016-08-08 18:44:38 +01004982}
4983
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004984v8_executable("v8_hello_world") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00004985 sources = [ "samples/hello-world.cc" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004986
4987 configs = [
4988 # Note: don't use :internal_config here because this target will get
4989 # the :external_config applied to it by virtue of depending on :v8, and
4990 # you can't have both applied to the same target.
4991 ":internal_config_base",
4992 ]
4993
4994 deps = [
4995 ":v8",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00004996 ":v8_libbase",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004997 ":v8_libplatform",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01004998 "//build/win:default_exe_manifest",
4999 ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005000}
5001
5002v8_executable("v8_sample_process") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00005003 sources = [ "samples/process.cc" ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005004
5005 configs = [
5006 # Note: don't use :internal_config here because this target will get
5007 # the :external_config applied to it by virtue of depending on :v8, and
5008 # you can't have both applied to the same target.
5009 ":internal_config_base",
5010 ]
5011
5012 deps = [
5013 ":v8",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00005014 ":v8_libbase",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005015 ":v8_libplatform",
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005016 "//build/win:default_exe_manifest",
5017 ]
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005018}
5019
5020if (want_v8_shell) {
5021 v8_executable("v8_shell") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00005022 sources = [ "samples/shell.cc" ]
Ben Murdoch014dc512016-03-22 12:00:34 +00005023
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005024 configs = [
Ben Murdoch014dc512016-03-22 12:00:34 +00005025 # Note: don't use :internal_config here because this target will get
5026 # the :external_config applied to it by virtue of depending on :v8, and
5027 # you can't have both applied to the same target.
5028 ":internal_config_base",
Ben Murdoch014dc512016-03-22 12:00:34 +00005029 ]
5030
5031 deps = [
Ben Murdoch014dc512016-03-22 12:00:34 +00005032 ":v8",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00005033 ":v8_libbase",
Ben Murdoch014dc512016-03-22 12:00:34 +00005034 ":v8_libplatform",
Ben Murdochbcf72ee2016-08-08 18:44:38 +01005035 "//build/win:default_exe_manifest",
Ben Murdoch014dc512016-03-22 12:00:34 +00005036 ]
Ben Murdoch014dc512016-03-22 12:00:34 +00005037 }
Ben Murdochb8a8cc12014-11-26 15:28:44 +00005038}
Ben Murdoch109988c2016-05-18 11:27:45 +01005039
Rubin Xu7bc1b612021-02-16 09:38:50 +00005040v8_executable("cppgc_for_v8_embedders") {
5041 sources = [ "samples/cppgc/cppgc-for-v8-embedders.cc" ]
5042
5043 configs = [
5044 # Note: don't use :internal_config here because this target will get
5045 # the :external_config applied to it by virtue of depending on :cppgc, and
5046 # you can't have both applied to the same target.
5047 ":internal_config_base",
5048 ]
5049
5050 deps = [
5051 ":cppgc",
5052 ":v8_libplatform",
5053 "//build/win:default_exe_manifest",
5054 ]
5055}
5056
5057v8_executable("cppgc_standalone") {
5058 sources = [ "samples/cppgc/cppgc-standalone.cc" ]
5059
5060 configs = [
5061 # Note: don't use :internal_config here because this target will get
5062 # the :external_config applied to it by virtue of depending on :cppgc, and
5063 # you can't have both applied to the same target.
5064 ":internal_config_base",
5065 ]
5066
5067 deps = [ ":cppgc" ]
5068}
5069
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005070template("v8_fuzzer") {
5071 name = target_name
5072 forward_variables_from(invoker, "*")
5073 v8_executable("v8_simple_" + name) {
5074 deps = [
5075 ":" + name,
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005076 "//build/win:default_exe_manifest",
5077 ]
5078
Rubin Xu7bc1b612021-02-16 09:38:50 +00005079 sources = [ "test/fuzzer/fuzzer.cc" ]
Ben Murdoch62ed6312017-06-06 11:06:27 +01005080
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005081 configs = [ ":external_config" ]
5082 }
5083}
5084
Ben Murdochbcf72ee2016-08-08 18:44:38 +01005085v8_source_set("json_fuzzer") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00005086 sources = [ "test/fuzzer/json.cc" ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005087
Rubin Xu7bc1b612021-02-16 09:38:50 +00005088 deps = [ ":fuzzer_support" ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005089
Ben Murdochf3b273f2017-01-17 12:11:28 +00005090 configs = [
5091 ":external_config",
5092 ":internal_config_base",
5093 ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005094}
5095
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005096v8_fuzzer("json_fuzzer") {
5097}
5098
Rubin Xu7bc1b612021-02-16 09:38:50 +00005099v8_source_set("multi_return_fuzzer") {
5100 sources = [ "test/fuzzer/multi-return.cc" ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005101
Rubin Xu7bc1b612021-02-16 09:38:50 +00005102 deps = [ ":fuzzer_support" ]
5103
5104 configs = [
5105 ":external_config",
5106 ":internal_config_base",
Ben Murdoch109988c2016-05-18 11:27:45 +01005107 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00005108}
5109
5110v8_fuzzer("multi_return_fuzzer") {
5111}
5112
5113v8_source_set("parser_fuzzer") {
5114 sources = [ "test/fuzzer/parser.cc" ]
5115
5116 deps = [ ":fuzzer_support" ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005117
Ben Murdochf3b273f2017-01-17 12:11:28 +00005118 configs = [
5119 ":external_config",
5120 ":internal_config_base",
5121 ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005122}
5123
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005124v8_fuzzer("parser_fuzzer") {
5125}
5126
Rubin Xu7bc1b612021-02-16 09:38:50 +00005127v8_source_set("regexp_builtins_fuzzer") {
Ben Murdoch109988c2016-05-18 11:27:45 +01005128 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00005129 "test/fuzzer/regexp-builtins.cc",
5130 "test/fuzzer/regexp_builtins/mjsunit.js.h",
Ben Murdoch109988c2016-05-18 11:27:45 +01005131 ]
5132
Rubin Xu7bc1b612021-02-16 09:38:50 +00005133 deps = [ ":fuzzer_support" ]
5134
5135 configs = [
5136 ":external_config",
5137 ":internal_config_base",
Ben Murdoch109988c2016-05-18 11:27:45 +01005138 ]
Rubin Xu7bc1b612021-02-16 09:38:50 +00005139}
5140
5141v8_fuzzer("regexp_builtins_fuzzer") {
5142}
5143
5144v8_source_set("regexp_fuzzer") {
5145 sources = [ "test/fuzzer/regexp.cc" ]
5146
5147 deps = [ ":fuzzer_support" ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005148
Ben Murdochf3b273f2017-01-17 12:11:28 +00005149 configs = [
5150 ":external_config",
5151 ":internal_config_base",
5152 ]
Ben Murdoch3b9bc312016-06-02 14:46:10 +01005153}
5154
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005155v8_fuzzer("regexp_fuzzer") {
5156}
5157
Rubin Xu7bc1b612021-02-16 09:38:50 +00005158v8_source_set("wasm_test_common") {
Ben Murdochf3b273f2017-01-17 12:11:28 +00005159 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00005160 "test/common/wasm/wasm-interpreter.cc",
5161 "test/common/wasm/wasm-interpreter.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00005162 "test/common/wasm/wasm-module-runner.cc",
5163 "test/common/wasm/wasm-module-runner.h",
5164 ]
5165
Rubin Xu7bc1b612021-02-16 09:38:50 +00005166 deps = [
5167 ":generate_bytecode_builtins_list",
5168 ":run_torque",
5169 ":v8_tracing",
Ben Murdochf3b273f2017-01-17 12:11:28 +00005170 ]
Ben Murdochf3b273f2017-01-17 12:11:28 +00005171
Rubin Xu7bc1b612021-02-16 09:38:50 +00005172 public_deps = [ ":v8_maybe_icu" ]
Ben Murdochf3b273f2017-01-17 12:11:28 +00005173
5174 configs = [
5175 ":external_config",
5176 ":internal_config_base",
5177 ]
5178}
5179
Ben Murdochbcf72ee2016-08-08 18:44:38 +01005180v8_source_set("wasm_fuzzer") {
Rubin Xu7bc1b612021-02-16 09:38:50 +00005181 sources = [ "test/fuzzer/wasm.cc" ]
Ben Murdoch3b9bc312016-06-02 14:46:10 +01005182
5183 deps = [
5184 ":fuzzer_support",
Rubin Xu7bc1b612021-02-16 09:38:50 +00005185 ":lib_wasm_fuzzer_common",
5186 ":wasm_test_common",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01005187 ]
5188
Ben Murdochf3b273f2017-01-17 12:11:28 +00005189 configs = [
5190 ":external_config",
5191 ":internal_config_base",
5192 ]
Ben Murdoch3b9bc312016-06-02 14:46:10 +01005193}
5194
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005195v8_fuzzer("wasm_fuzzer") {
5196}
5197
Rubin Xu7bc1b612021-02-16 09:38:50 +00005198v8_source_set("wasm_async_fuzzer") {
5199 sources = [ "test/fuzzer/wasm-async.cc" ]
Ben Murdoch3b9bc312016-06-02 14:46:10 +01005200
5201 deps = [
5202 ":fuzzer_support",
Rubin Xu7bc1b612021-02-16 09:38:50 +00005203 ":lib_wasm_fuzzer_common",
5204 ":wasm_test_common",
Ben Murdoch3b9bc312016-06-02 14:46:10 +01005205 ]
5206
Ben Murdochf3b273f2017-01-17 12:11:28 +00005207 configs = [
5208 ":external_config",
5209 ":internal_config_base",
5210 ]
Ben Murdoch109988c2016-05-18 11:27:45 +01005211}
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005212
Rubin Xu7bc1b612021-02-16 09:38:50 +00005213v8_fuzzer("wasm_async_fuzzer") {
Ben Murdoch13e2dad2016-09-16 13:49:30 +01005214}
Ben Murdochf3b273f2017-01-17 12:11:28 +00005215
5216v8_source_set("wasm_code_fuzzer") {
5217 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00005218 "test/common/wasm/test-signatures.h",
Ben Murdochf3b273f2017-01-17 12:11:28 +00005219 "test/fuzzer/wasm-code.cc",
5220 ]
5221
5222 deps = [
5223 ":fuzzer_support",
Rubin Xu7bc1b612021-02-16 09:38:50 +00005224 ":lib_wasm_fuzzer_common",
5225 ":wasm_test_common",
Ben Murdochf3b273f2017-01-17 12:11:28 +00005226 ]
5227
5228 configs = [
5229 ":external_config",
5230 ":internal_config_base",
5231 ]
5232}
5233
5234v8_fuzzer("wasm_code_fuzzer") {
5235}
5236
Rubin Xu7bc1b612021-02-16 09:38:50 +00005237v8_source_set("lib_wasm_fuzzer_common") {
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00005238 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00005239 "test/fuzzer/wasm-fuzzer-common.cc",
5240 "test/fuzzer/wasm-fuzzer-common.h",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00005241 ]
5242
5243 deps = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00005244 ":generate_bytecode_builtins_list",
5245 ":run_torque",
5246 ":v8_tracing",
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00005247 ]
5248
Rubin Xu7bc1b612021-02-16 09:38:50 +00005249 public_deps = [ ":v8_maybe_icu" ]
5250
Ben Murdochc8c1d9e2017-03-08 14:04:23 +00005251 configs = [
5252 ":external_config",
5253 ":internal_config_base",
5254 ]
5255}
5256
Ben Murdoch62ed6312017-06-06 11:06:27 +01005257v8_source_set("wasm_compile_fuzzer") {
5258 sources = [
Rubin Xu7bc1b612021-02-16 09:38:50 +00005259 "test/common/wasm/test-signatures.h",
Ben Murdoch62ed6312017-06-06 11:06:27 +01005260 "test/fuzzer/wasm-compile.cc",
5261 ]
5262
5263 deps = [
5264 ":fuzzer_support",
Rubin Xu7bc1b612021-02-16 09:38:50 +00005265 ":lib_wasm_fuzzer_common",
5266 ":wasm_test_common",
Ben Murdoch62ed6312017-06-06 11:06:27 +01005267 ]
5268
5269 configs = [
5270 ":external_config",
5271 ":internal_config_base",
5272 ]
5273}
5274
5275v8_fuzzer("wasm_compile_fuzzer") {
5276}
Rubin Xu7bc1b612021-02-16 09:38:50 +00005277
5278v8_source_set("inspector_fuzzer") {
5279 sources = [ "test/fuzzer/inspector-fuzzer.cc" ]
5280
5281 deps = [
5282 ":fuzzer_support",
5283 "test/inspector:inspector_test",
5284 ]
5285
5286 configs = [
5287 ":external_config",
5288 ":internal_config_base",
5289 ]
5290}
5291
5292v8_fuzzer("inspector_fuzzer") {
5293}
5294
5295# Target to build all generated .cc files.
5296group("v8_generated_cc_files") {
5297 testonly = true
5298
5299 deps = [
5300 ":generate_bytecode_builtins_list",
5301 ":run_torque",
5302 "src/inspector:v8_generated_cc_files",
5303 ]
5304}
5305
5306# Protobuf targets, used only when building outside of chromium.
5307
5308if (!build_with_chromium && v8_use_perfetto) {
5309 # This config is applied to the autogenerated .pb.{cc,h} files in
5310 # proto_library.gni. This config is propagated up to the source sets
5311 # that depend on generated proto headers.
5312 config("protobuf_gen_config") {
5313 defines = [
5314 "GOOGLE_PROTOBUF_NO_RTTI",
5315 "GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER",
5316 ]
5317 cflags = [
5318 "-Wno-unknown-warning-option",
5319 "-Wno-deprecated",
5320 "-Wno-undef",
5321 "-Wno-zero-as-null-pointer-constant",
5322 "-Wno-thread-safety-attributes",
5323 ]
5324 include_dirs = [ "third_party/protobuf/src" ]
5325 }
5326
5327 # Configuration used to build libprotobuf_* and the protoc compiler.
5328 config("protobuf_config") {
5329 # Apply the lighter supressions and macro definitions from above.
5330 configs = [ ":protobuf_gen_config" ]
5331
5332 if (!is_win) {
5333 defines = [ "HAVE_PTHREAD=1" ]
5334 }
5335 if (is_clang) {
5336 cflags = [
5337 "-Wno-unused-private-field",
5338 "-Wno-unused-function",
5339 "-Wno-inconsistent-missing-override",
5340 "-Wno-unknown-warning-option",
5341 "-Wno-enum-compare-switch",
5342 "-Wno-user-defined-warnings",
5343 "-Wno-tautological-constant-compare",
5344 ]
5345 }
5346 if (is_win && is_clang) {
5347 cflags += [ "-Wno-microsoft-unqualified-friend" ]
5348 }
5349 }
5350
5351 source_set("protobuf_lite") {
5352 sources = [
5353 "third_party/protobuf/src/google/protobuf/any_lite.cc",
5354 "third_party/protobuf/src/google/protobuf/arena.cc",
5355 "third_party/protobuf/src/google/protobuf/extension_set.cc",
5356 "third_party/protobuf/src/google/protobuf/generated_message_table_driven_lite.cc",
5357 "third_party/protobuf/src/google/protobuf/generated_message_util.cc",
5358 "third_party/protobuf/src/google/protobuf/implicit_weak_message.cc",
5359 "third_party/protobuf/src/google/protobuf/io/coded_stream.cc",
5360 "third_party/protobuf/src/google/protobuf/io/strtod.cc",
5361 "third_party/protobuf/src/google/protobuf/io/zero_copy_stream.cc",
5362 "third_party/protobuf/src/google/protobuf/io/zero_copy_stream_impl_lite.cc",
5363 "third_party/protobuf/src/google/protobuf/message_lite.cc",
5364 "third_party/protobuf/src/google/protobuf/repeated_field.cc",
5365 "third_party/protobuf/src/google/protobuf/stubs/bytestream.cc",
5366 "third_party/protobuf/src/google/protobuf/stubs/common.cc",
5367 "third_party/protobuf/src/google/protobuf/stubs/int128.cc",
5368 "third_party/protobuf/src/google/protobuf/stubs/io_win32.cc",
5369 "third_party/protobuf/src/google/protobuf/stubs/status.cc",
5370 "third_party/protobuf/src/google/protobuf/stubs/statusor.cc",
5371 "third_party/protobuf/src/google/protobuf/stubs/stringpiece.cc",
5372 "third_party/protobuf/src/google/protobuf/stubs/stringprintf.cc",
5373 "third_party/protobuf/src/google/protobuf/stubs/structurally_valid.cc",
5374 "third_party/protobuf/src/google/protobuf/stubs/strutil.cc",
5375 "third_party/protobuf/src/google/protobuf/stubs/time.cc",
5376 "third_party/protobuf/src/google/protobuf/wire_format_lite.cc",
5377 ]
5378 configs -= [ "//build/config/compiler:chromium_code" ]
5379 configs += [
5380 "//build/config/compiler:no_chromium_code",
5381 ":protobuf_config",
5382 ]
5383 if (is_win) {
5384 configs -= [ "//build/config/win:lean_and_mean" ]
5385 }
5386 public_configs = [ ":protobuf_gen_config" ]
5387 }
5388
5389 # This target should be used only by the protoc compiler and by test targets.
5390 source_set("protobuf_full") {
5391 deps = [ ":protobuf_lite" ]
5392 sources = [
5393 "third_party/protobuf/src/google/protobuf/any.cc",
5394 "third_party/protobuf/src/google/protobuf/any.pb.cc",
5395 "third_party/protobuf/src/google/protobuf/api.pb.cc",
5396 "third_party/protobuf/src/google/protobuf/compiler/importer.cc",
5397 "third_party/protobuf/src/google/protobuf/compiler/parser.cc",
5398 "third_party/protobuf/src/google/protobuf/descriptor.cc",
5399 "third_party/protobuf/src/google/protobuf/descriptor.pb.cc",
5400 "third_party/protobuf/src/google/protobuf/descriptor_database.cc",
5401 "third_party/protobuf/src/google/protobuf/duration.pb.cc",
5402 "third_party/protobuf/src/google/protobuf/dynamic_message.cc",
5403 "third_party/protobuf/src/google/protobuf/empty.pb.cc",
5404 "third_party/protobuf/src/google/protobuf/extension_set_heavy.cc",
5405 "third_party/protobuf/src/google/protobuf/field_mask.pb.cc",
5406 "third_party/protobuf/src/google/protobuf/generated_message_reflection.cc",
5407 "third_party/protobuf/src/google/protobuf/generated_message_table_driven.cc",
5408 "third_party/protobuf/src/google/protobuf/io/gzip_stream.cc",
5409 "third_party/protobuf/src/google/protobuf/io/printer.cc",
5410 "third_party/protobuf/src/google/protobuf/io/tokenizer.cc",
5411 "third_party/protobuf/src/google/protobuf/io/zero_copy_stream_impl.cc",
5412 "third_party/protobuf/src/google/protobuf/map_field.cc",
5413 "third_party/protobuf/src/google/protobuf/message.cc",
5414 "third_party/protobuf/src/google/protobuf/reflection_ops.cc",
5415 "third_party/protobuf/src/google/protobuf/service.cc",
5416 "third_party/protobuf/src/google/protobuf/source_context.pb.cc",
5417 "third_party/protobuf/src/google/protobuf/struct.pb.cc",
5418 "third_party/protobuf/src/google/protobuf/stubs/mathlimits.cc",
5419 "third_party/protobuf/src/google/protobuf/stubs/substitute.cc",
5420 "third_party/protobuf/src/google/protobuf/text_format.cc",
5421 "third_party/protobuf/src/google/protobuf/timestamp.pb.cc",
5422 "third_party/protobuf/src/google/protobuf/type.pb.cc",
5423 "third_party/protobuf/src/google/protobuf/unknown_field_set.cc",
5424 "third_party/protobuf/src/google/protobuf/util/delimited_message_util.cc",
5425 "third_party/protobuf/src/google/protobuf/util/field_comparator.cc",
5426 "third_party/protobuf/src/google/protobuf/util/field_mask_util.cc",
5427 "third_party/protobuf/src/google/protobuf/util/internal/datapiece.cc",
5428 "third_party/protobuf/src/google/protobuf/util/internal/default_value_objectwriter.cc",
5429 "third_party/protobuf/src/google/protobuf/util/internal/error_listener.cc",
5430 "third_party/protobuf/src/google/protobuf/util/internal/field_mask_utility.cc",
5431 "third_party/protobuf/src/google/protobuf/util/internal/json_escaping.cc",
5432 "third_party/protobuf/src/google/protobuf/util/internal/json_objectwriter.cc",
5433 "third_party/protobuf/src/google/protobuf/util/internal/json_stream_parser.cc",
5434 "third_party/protobuf/src/google/protobuf/util/internal/object_writer.cc",
5435 "third_party/protobuf/src/google/protobuf/util/internal/proto_writer.cc",
5436 "third_party/protobuf/src/google/protobuf/util/internal/protostream_objectsource.cc",
5437 "third_party/protobuf/src/google/protobuf/util/internal/protostream_objectwriter.cc",
5438 "third_party/protobuf/src/google/protobuf/util/internal/type_info.cc",
5439 "third_party/protobuf/src/google/protobuf/util/internal/type_info_test_helper.cc",
5440 "third_party/protobuf/src/google/protobuf/util/internal/utility.cc",
5441 "third_party/protobuf/src/google/protobuf/util/json_util.cc",
5442 "third_party/protobuf/src/google/protobuf/util/message_differencer.cc",
5443 "third_party/protobuf/src/google/protobuf/util/time_util.cc",
5444 "third_party/protobuf/src/google/protobuf/util/type_resolver_util.cc",
5445 "third_party/protobuf/src/google/protobuf/wire_format.cc",
5446 "third_party/protobuf/src/google/protobuf/wrappers.pb.cc",
5447 ]
5448 configs -= [ "//build/config/compiler:chromium_code" ]
5449 configs += [
5450 "//build/config/compiler:no_chromium_code",
5451 ":protobuf_config",
5452 ]
5453 if (is_win) {
5454 configs -= [ "//build/config/win:lean_and_mean" ]
5455 }
5456 public_configs = [ ":protobuf_gen_config" ]
5457 }
5458
5459 if (current_toolchain == host_toolchain) {
5460 source_set("protoc_lib") {
5461 deps = [ ":protobuf_full" ]
5462 sources = [
5463 "third_party/protobuf/src/google/protobuf/compiler/code_generator.cc",
5464 "third_party/protobuf/src/google/protobuf/compiler/command_line_interface.cc",
5465 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_enum.cc",
5466 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_enum_field.cc",
5467 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_extension.cc",
5468 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_field.cc",
5469 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_file.cc",
5470 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_generator.cc",
5471 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_helpers.cc",
5472 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_map_field.cc",
5473 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_message.cc",
5474 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_message_field.cc",
5475 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_padding_optimizer.cc",
5476 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_primitive_field.cc",
5477 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_service.cc",
5478 "third_party/protobuf/src/google/protobuf/compiler/cpp/cpp_string_field.cc",
5479 "third_party/protobuf/src/google/protobuf/compiler/plugin.cc",
5480 "third_party/protobuf/src/google/protobuf/compiler/plugin.pb.cc",
5481 "third_party/protobuf/src/google/protobuf/compiler/subprocess.cc",
5482 "third_party/protobuf/src/google/protobuf/compiler/zip_writer.cc",
5483 ]
5484 configs -= [ "//build/config/compiler:chromium_code" ]
5485 configs += [
5486 "//build/config/compiler:no_chromium_code",
5487 ":protobuf_config",
5488 ]
5489 if (is_win) {
5490 configs -= [ "//build/config/win:lean_and_mean" ]
5491 }
5492 public_configs = [ ":protobuf_gen_config" ]
5493 }
5494
5495 executable("protoc") {
5496 deps = [
5497 ":protoc_lib",
5498 "//build/win:default_exe_manifest",
5499 ]
5500 sources = [ "src/protobuf/protobuf-compiler-main.cc" ]
5501 configs -= [ "//build/config/compiler:chromium_code" ]
5502 configs += [ "//build/config/compiler:no_chromium_code" ]
5503 }
5504 } # host_toolchain
5505
5506 v8_component("v8_libperfetto") {
5507 configs = [ ":v8_tracing_config" ]
5508 public_configs = [ "//third_party/perfetto/gn:public_config" ]
5509 deps = [
5510 "//third_party/perfetto/src/trace_processor:export_json",
5511 "//third_party/perfetto/src/trace_processor:storage_minimal",
5512 "//third_party/perfetto/src/tracing:client_api",
5513 "//third_party/perfetto/src/tracing/core",
5514
5515 # TODO(skyostil): Support non-POSIX platforms.
5516 "//third_party/perfetto/protos/perfetto/config:cpp",
5517 "//third_party/perfetto/protos/perfetto/trace/track_event:zero",
5518 "//third_party/perfetto/src/tracing:in_process_backend",
5519 "//third_party/perfetto/src/tracing:platform_posix",
5520 ]
5521 }
5522} # if (!build_with_chromium && v8_use_perfetto)