diff --git a/Makefile b/Makefile index 346f355ea7a298..6924d349513422 100644 --- a/Makefile +++ b/Makefile @@ -126,7 +126,7 @@ test-code-cache: with-code-cache out/Makefile: config.gypi common.gypi node.gyp \ deps/uv/uv.gyp deps/http_parser/http_parser.gyp deps/zlib/zlib.gyp \ tools/v8_gypfiles/toolchain.gypi tools/v8_gypfiles/features.gypi \ - tools/v8_gypfiles/inspector.gypi tools/v8_gypfiles/v8.gyp + tools/v8_gypfiles/v8.gyp $(PYTHON) tools/gyp_node.py -f make config.gypi: configure configure.py diff --git a/deps/v8/third_party/inspector_protocol/inspector_protocol.gypi b/deps/v8/third_party/inspector_protocol/inspector_protocol.gypi deleted file mode 100644 index 3d0a60e1395241..00000000000000 --- a/deps/v8/third_party/inspector_protocol/inspector_protocol.gypi +++ /dev/null @@ -1,34 +0,0 @@ -# Copyright 2016 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -{ - 'variables': { - 'inspector_protocol_files': [ - 'lib/Allocator_h.template', - 'lib/Array_h.template', - 'lib/CBOR_h.template', - 'lib/CBOR_cpp.template', - 'lib/DispatcherBase_cpp.template', - 'lib/DispatcherBase_h.template', - 'lib/ErrorSupport_cpp.template', - 'lib/ErrorSupport_h.template', - 'lib/Forward_h.template', - 'lib/FrontendChannel_h.template', - 'lib/Maybe_h.template', - 'lib/Object_cpp.template', - 'lib/Object_h.template', - 'lib/Parser_cpp.template', - 'lib/Parser_h.template', - 'lib/Protocol_cpp.template', - 'lib/ValueConversions_h.template', - 'lib/Values_cpp.template', - 'lib/Values_h.template', - 'templates/Exported_h.template', - 'templates/Imported_h.template', - 'templates/TypeBuilder_cpp.template', - 'templates/TypeBuilder_h.template', - 'code_generator.py', - ] - } -} diff --git a/node.gypi b/node.gypi index d6c4c2669834bf..30e7941c192344 100644 --- a/node.gypi +++ b/node.gypi @@ -62,6 +62,9 @@ '<(_msvs_precompiled_header)', '<(_msvs_precompiled_source)', ], + 'include_dirs': [ + 'tools/msvs/pch', + ], }, { # POSIX 'defines': [ '__POSIX__' ], }], diff --git a/tools/msvs/pch/v8_pch.cc b/tools/msvs/pch/v8_pch.cc deleted file mode 100644 index 03a5d999d36d9d..00000000000000 --- a/tools/msvs/pch/v8_pch.cc +++ /dev/null @@ -1 +0,0 @@ -#include "v8_pch.h" diff --git a/tools/msvs/pch/v8_pch.h b/tools/msvs/pch/v8_pch.h deleted file mode 100644 index 2c543beac2111b..00000000000000 --- a/tools/msvs/pch/v8_pch.h +++ /dev/null @@ -1,3 +0,0 @@ -#include "src/api-inl.h" -#include "src/objects-inl.h" -#include "src/utils.h" diff --git a/tools/v8_gypfiles/inspector.gypi b/tools/v8_gypfiles/inspector.gypi deleted file mode 100644 index 79e582cea9e68d..00000000000000 --- a/tools/v8_gypfiles/inspector.gypi +++ /dev/null @@ -1,130 +0,0 @@ -# Copyright 2016 the V8 project authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -{ - 'includes': [ - '../../deps/v8/third_party/inspector_protocol/inspector_protocol.gypi', - ], - 'variables': { - 'inspector_protocol_path': '<(V8_ROOT)/third_party/inspector_protocol', - 'inspector_path': '<(V8_ROOT)/src/inspector', - 'inspector_generated_output_root': '<(SHARED_INTERMEDIATE_DIR)/inspector-generated-output-root', - 'inspector_generated_sources': [ - '<(inspector_generated_output_root)/src/inspector/protocol/Forward.h', - '<(inspector_generated_output_root)/src/inspector/protocol/Protocol.cpp', - '<(inspector_generated_output_root)/src/inspector/protocol/Protocol.h', - '<(inspector_generated_output_root)/src/inspector/protocol/Console.cpp', - '<(inspector_generated_output_root)/src/inspector/protocol/Console.h', - '<(inspector_generated_output_root)/src/inspector/protocol/Debugger.cpp', - '<(inspector_generated_output_root)/src/inspector/protocol/Debugger.h', - '<(inspector_generated_output_root)/src/inspector/protocol/HeapProfiler.cpp', - '<(inspector_generated_output_root)/src/inspector/protocol/HeapProfiler.h', - '<(inspector_generated_output_root)/src/inspector/protocol/Profiler.cpp', - '<(inspector_generated_output_root)/src/inspector/protocol/Profiler.h', - '<(inspector_generated_output_root)/src/inspector/protocol/Runtime.cpp', - '<(inspector_generated_output_root)/src/inspector/protocol/Runtime.h', - '<(inspector_generated_output_root)/src/inspector/protocol/Schema.cpp', - '<(inspector_generated_output_root)/src/inspector/protocol/Schema.h', - '<(inspector_generated_output_root)/include/inspector/Debugger.h', - '<(inspector_generated_output_root)/include/inspector/Runtime.h', - '<(inspector_generated_output_root)/include/inspector/Schema.h', - ], - - 'inspector_all_sources': [ - '<(V8_ROOT)/include/v8-inspector.h', - '<(V8_ROOT)/include/v8-inspector-protocol.h', - '<(V8_ROOT)/src/inspector/custom-preview.cc', - '<(V8_ROOT)/src/inspector/custom-preview.h', - '<(V8_ROOT)/src/inspector/injected-script.cc', - '<(V8_ROOT)/src/inspector/injected-script.h', - '<(V8_ROOT)/src/inspector/inspected-context.cc', - '<(V8_ROOT)/src/inspector/inspected-context.h', - '<(V8_ROOT)/src/inspector/remote-object-id.cc', - '<(V8_ROOT)/src/inspector/remote-object-id.h', - '<(V8_ROOT)/src/inspector/search-util.cc', - '<(V8_ROOT)/src/inspector/search-util.h', - '<(V8_ROOT)/src/inspector/string-16.cc', - '<(V8_ROOT)/src/inspector/string-16.h', - '<(V8_ROOT)/src/inspector/string-util.cc', - '<(V8_ROOT)/src/inspector/string-util.h', - '<(V8_ROOT)/src/inspector/test-interface.cc', - '<(V8_ROOT)/src/inspector/test-interface.h', - '<(V8_ROOT)/src/inspector/v8-console.cc', - '<(V8_ROOT)/src/inspector/v8-console.h', - '<(V8_ROOT)/src/inspector/v8-console-agent-impl.cc', - '<(V8_ROOT)/src/inspector/v8-console-agent-impl.h', - '<(V8_ROOT)/src/inspector/v8-console-message.cc', - '<(V8_ROOT)/src/inspector/v8-console-message.h', - '<(V8_ROOT)/src/inspector/v8-debugger.cc', - '<(V8_ROOT)/src/inspector/v8-debugger.h', - '<(V8_ROOT)/src/inspector/v8-debugger-agent-impl.cc', - '<(V8_ROOT)/src/inspector/v8-debugger-agent-impl.h', - '<(V8_ROOT)/src/inspector/v8-debugger-script.cc', - '<(V8_ROOT)/src/inspector/v8-debugger-script.h', - '<(V8_ROOT)/src/inspector/v8-heap-profiler-agent-impl.cc', - '<(V8_ROOT)/src/inspector/v8-heap-profiler-agent-impl.h', - '<(V8_ROOT)/src/inspector/v8-inspector-impl.cc', - '<(V8_ROOT)/src/inspector/v8-inspector-impl.h', - '<(V8_ROOT)/src/inspector/v8-inspector-session-impl.cc', - '<(V8_ROOT)/src/inspector/v8-inspector-session-impl.h', - '<(V8_ROOT)/src/inspector/v8-profiler-agent-impl.cc', - '<(V8_ROOT)/src/inspector/v8-profiler-agent-impl.h', - '<(V8_ROOT)/src/inspector/v8-regex.cc', - '<(V8_ROOT)/src/inspector/v8-regex.h', - '<(V8_ROOT)/src/inspector/v8-runtime-agent-impl.cc', - '<(V8_ROOT)/src/inspector/v8-runtime-agent-impl.h', - '<(V8_ROOT)/src/inspector/v8-schema-agent-impl.cc', - '<(V8_ROOT)/src/inspector/v8-schema-agent-impl.h', - '<(V8_ROOT)/src/inspector/v8-stack-trace-impl.cc', - '<(V8_ROOT)/src/inspector/v8-stack-trace-impl.h', - '<(V8_ROOT)/src/inspector/v8-value-utils.cc', - '<(V8_ROOT)/src/inspector/v8-value-utils.h', - '<(V8_ROOT)/src/inspector/value-mirror.cc', - '<(V8_ROOT)/src/inspector/value-mirror.h', - '<(V8_ROOT)/src/inspector/wasm-translation.cc', - '<(V8_ROOT)/src/inspector/wasm-translation.h', - ] - }, - 'include_dirs': [ - '<(inspector_generated_output_root)', - ], - 'actions': [ - { - 'action_name': 'protocol_compatibility', - 'inputs': [ - '<(inspector_path)/js_protocol.pdl', - ], - 'outputs': [ - '<@(inspector_generated_output_root)/src/js_protocol.stamp', - ], - 'action': [ - 'python', - '<(inspector_protocol_path)/check_protocol_compatibility.py', - '--stamp', '<@(_outputs)', - '<@(_inputs)', - ], - 'message': 'Checking inspector protocol compatibility', - }, - { - 'action_name': 'protocol_generated_sources', - 'inputs': [ - '<(inspector_path)/js_protocol.pdl', - '<(inspector_path)/inspector_protocol_config.json', - '<@(inspector_protocol_files)', - ], - 'outputs': [ - '<@(inspector_generated_sources)', - ], - 'process_outputs_as_sources': 1, - 'action': [ - 'python', - '<(inspector_protocol_path)/code_generator.py', - '--jinja_dir', '<(V8_ROOT)/third_party', - '--output_base', '<(inspector_generated_output_root)/src/inspector', - '--config', '<(inspector_path)/inspector_protocol_config.json', - ], - 'message': 'Generating inspector protocol sources from protocol json', - }, - ], -} diff --git a/tools/v8_gypfiles/pch/v8_base_pch.cc b/tools/v8_gypfiles/pch/v8_base_pch.cc new file mode 100644 index 00000000000000..284bb4ce7aeabd --- /dev/null +++ b/tools/v8_gypfiles/pch/v8_base_pch.cc @@ -0,0 +1 @@ +#include "v8_base_pch.h" diff --git a/tools/v8_gypfiles/pch/v8_base_pch.h b/tools/v8_gypfiles/pch/v8_base_pch.h new file mode 100644 index 00000000000000..dbf3f126ade9fc --- /dev/null +++ b/tools/v8_gypfiles/pch/v8_base_pch.h @@ -0,0 +1,169 @@ +#include "include/v8.h" +#include "include/v8-profiler.h" +#include "include/v8-testing.h" +#include "include/v8-util.h" +#include "src/accessors.h" +#include "src/allocation-site-scopes.h" +#include "src/api.h" +#include "src/api-arguments-inl.h" +#include "src/api-inl.h" +#include "src/api-natives.h" +#include "src/arguments.h" +#include "src/assert-scope.h" +#include "src/ast/ast.h" +#include "src/ast/scopes.h" +#include "src/base/bits.h" +#include "src/base/functional.h" +#include "src/base/logging.h" +#include "src/base/overflowing-math.h" +#include "src/base/platform/platform.h" +#include "src/base/platform/time.h" +#include "src/base/safe_conversions.h" +#include "src/base/utils/random-number-generator.h" +#include "src/bootstrapper.h" +#include "src/builtins/builtins.h" +#include "src/builtins/builtins-utils.h" +#include "src/char-predicates-inl.h" +#include "src/code-factory.h" +// Problematic #include "src/code-stub-assembler.h" +#include "src/compiler.h" +#include "src/compiler-dispatcher/compiler-dispatcher.h" +#include "src/contexts.h" +#include "src/conversions-inl.h" +#include "src/counters.h" +#include "src/counters-inl.h" +#include "src/cpu-features.h" +#include "src/date.h" +#include "src/debug/debug.h" +#include "src/debug/debug-coverage.h" +#include "src/debug/debug-evaluate.h" +#include "src/debug/debug-type-profile.h" +#include "src/debug/liveedit.h" +#include "src/deoptimizer.h" +#include "src/detachable-vector.h" +#include "src/elements.h" +#include "src/execution.h" +#include "src/field-index.h" +#include "src/field-index-inl.h" +#include "src/field-type.h" +#include "src/frames.h" +#include "src/frames-inl.h" +#include "src/function-kind.h" +#include "src/gdb-jit.h" +#include "src/global-handles.h" +#include "src/globals.h" +#include "src/heap/heap-inl.h" +#include "src/heap/read-only-heap.h" +#include "src/ic/ic.h" +#include "src/icu_util.h" +#include "src/identity-map.h" +#include "src/isolate-inl.h" +#include "src/json-parser.h" +#include "src/json-stringifier.h" +#include "src/keys.h" +#include "src/log.h" +#include "src/lookup-inl.h" +#include "src/map-updater.h" +#include "src/messages.h" +#include "src/message-template.h" +#include "src/microtask-queue.h" +#include "src/objects.h" +#include "src/objects/allocation-site-inl.h" +#include "src/objects/api-callbacks.h" +#include "src/objects/arguments-inl.h" +#include "src/objects/bigint.h" +#include "src/objects/cell.h" +#include "src/objects/cell-inl.h" +#include "src/objects/code-inl.h" +#include "src/objects/compilation-cache-inl.h" +#include "src/objects/debug-objects-inl.h" +#include "src/objects/descriptor-array.h" +#include "src/objects/embedder-data-array-inl.h" +#include "src/objects/embedder-data-slot-inl.h" +#include "src/objects/foreign.h" +#include "src/objects/frame-array-inl.h" +#include "src/objects/free-space-inl.h" +#include "src/objects/hash-table-inl.h" +#include "src/objects/heap-number.h" +#include "src/objects/heap-object.h" +#include "src/objects/js-array-inl.h" +#include "src/objects/js-collection-inl.h" +#include "src/objects/js-generator-inl.h" +#include "src/objects/js-promise-inl.h" +#include "src/objects/js-regexp-inl.h" +#include "src/objects/js-regexp-string-iterator.h" +#include "src/objects/js-weak-refs-inl.h" +#include "src/objects/literal-objects-inl.h" +#include "src/objects/map.h" +#include "src/objects/map-inl.h" +#include "src/objects/microtask-inl.h" +#include "src/objects/module-inl.h" +#include "src/objects/oddball.h" +#include "src/objects/ordered-hash-table-inl.h" +#include "src/objects/promise-inl.h" +#include "src/objects/property-cell.h" +#include "src/objects/slots.h" +#include "src/objects/slots-atomic-inl.h" +#include "src/objects/smi.h" +#include "src/objects/stack-frame-info-inl.h" +#include "src/objects/string-comparator.h" +#include "src/objects/struct-inl.h" +#include "src/objects/templates.h" +#include "src/objects-body-descriptors-inl.h" +#include "src/objects-inl.h" +#include "src/ostreams.h" +#include "src/parsing/parse-info.h" +#include "src/parsing/parser.h" +#include "src/parsing/preparse-data.h" +#include "src/parsing/scanner-character-streams.h" +#include "src/pending-compilation-error-handler.h" +#include "src/profiler/cpu-profiler.h" +#include "src/profiler/heap-profiler.h" +#include "src/profiler/heap-snapshot-generator-inl.h" +#include "src/profiler/profile-generator-inl.h" +#include "src/profiler/tick-sample.h" +#include "src/property.h" +#include "src/property-descriptor.h" +#include "src/property-details.h" +#include "src/prototype.h" +#include "src/regexp/jsregexp.h" +#include "src/runtime/runtime.h" +#include "src/runtime-profiler.h" +#include "src/simulator.h" +#include "src/snapshot/code-serializer.h" +#include "src/snapshot/natives.h" +#include "src/snapshot/partial-serializer.h" +#include "src/snapshot/read-only-serializer.h" +#include "src/snapshot/snapshot.h" +#include "src/snapshot/startup-serializer.h" +#include "src/source-position-table.h" +#include "src/startup-data-util.h" +#include "src/string-builder-inl.h" +#include "src/string-hasher.h" +#include "src/string-search.h" +#include "src/string-stream.h" +#include "src/tracing/trace-event.h" +#include "src/transitions-inl.h" +#include "src/trap-handler/trap-handler.h" +#include "src/unicode-decoder.h" +#include "src/unicode-inl.h" +#include "src/utils-inl.h" +#include "src/v8.h" +#include "src/v8threads.h" +#include "src/value-serializer.h" +#include "src/version.h" +#include "src/vm-state-inl.h" +#include "src/wasm/streaming-decoder.h" +#include "src/wasm/wasm-engine.h" +#include "src/wasm/wasm-objects.h" +#include "src/wasm/wasm-objects-inl.h" +#include "src/wasm/wasm-result.h" +#include "src/wasm/wasm-serialization.h" +#include "src/zone/zone.h" +#include +#include +#include +#include +#include +#include +#include diff --git a/tools/v8_gypfiles/pch/v8_initializers_pch.cc b/tools/v8_gypfiles/pch/v8_initializers_pch.cc new file mode 100644 index 00000000000000..dd77f73e118652 --- /dev/null +++ b/tools/v8_gypfiles/pch/v8_initializers_pch.cc @@ -0,0 +1 @@ +#include "v8_initializers_pch.h" diff --git a/tools/v8_gypfiles/pch/v8_initializers_pch.h b/tools/v8_gypfiles/pch/v8_initializers_pch.h new file mode 100644 index 00000000000000..e64ca19d2942b3 --- /dev/null +++ b/tools/v8_gypfiles/pch/v8_initializers_pch.h @@ -0,0 +1,73 @@ +// From all the torque generated files +#include "src/builtins/builtins-utils-gen.h" +#include "src/builtins/builtins.h" +#include "src/code-factory.h" +#include "src/elements-kind.h" +#include "src/heap/factory-inl.h" +#include "src/objects.h" +#include "src/objects/arguments.h" +#include "src/objects/bigint.h" +#include "src/objects/js-generator.h" +#include "src/objects/js-promise.h" +#include "src/objects/module.h" +#include "src/objects/stack-frame-info.h" +#include "src/builtins/builtins-array-gen.h" +#include "src/builtins/builtins-collections-gen.h" +#include "src/builtins/builtins-data-view-gen.h" +#include "src/builtins/builtins-iterator-gen.h" +#include "src/builtins/builtins-regexp-gen.h" +#include "src/builtins/builtins-typed-array-gen.h" +#include "src/builtins/builtins-constructor-gen.h" +#include "src/builtins/builtins-typed-array-gen.h" +#include "src/builtins/builtins-typed-array-gen.h" +#include "src/builtins/builtins-typed-array-gen.h" +#include "src/builtins/builtins-typed-array-gen.h" +#include "torque-generated/builtins-base-from-dsl-gen.h" +#include "torque-generated/builtins-growable-fixed-array-from-dsl-gen.h" +#include "torque-generated/builtins-arguments-from-dsl-gen.h" +#include "torque-generated/builtins-array-from-dsl-gen.h" +#include "torque-generated/builtins-array-copywithin-from-dsl-gen.h" +#include "torque-generated/builtins-array-filter-from-dsl-gen.h" +#include "torque-generated/builtins-array-find-from-dsl-gen.h" +#include "torque-generated/builtins-array-findindex-from-dsl-gen.h" +#include "torque-generated/builtins-array-foreach-from-dsl-gen.h" +#include "torque-generated/builtins-array-join-from-dsl-gen.h" +#include "torque-generated/builtins-array-lastindexof-from-dsl-gen.h" +#include "torque-generated/builtins-array-of-from-dsl-gen.h" +#include "torque-generated/builtins-array-map-from-dsl-gen.h" +#include "torque-generated/builtins-array-reverse-from-dsl-gen.h" +#include "torque-generated/builtins-array-slice-from-dsl-gen.h" +#include "torque-generated/builtins-array-splice-from-dsl-gen.h" +#include "torque-generated/builtins-array-unshift-from-dsl-gen.h" +#include "torque-generated/builtins-collections-from-dsl-gen.h" +#include "torque-generated/builtins-data-view-from-dsl-gen.h" +#include "torque-generated/builtins-extras-utils-from-dsl-gen.h" +#include "torque-generated/builtins-object-from-dsl-gen.h" +#include "torque-generated/builtins-iterator-from-dsl-gen.h" +#include "torque-generated/builtins-string-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-createtypedarray-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-filter-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-foreach-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-reduce-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-reduceright-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-slice-from-dsl-gen.h" +#include "torque-generated/builtins-typed-array-subarray-from-dsl-gen.h" + +// From src/builtins/setup-builtins-internal.cc +#include "src/setup-isolate.h" +#include "src/assembler-inl.h" +// Duplicate #include "src/builtins/builtins.h" +#include "src/code-events.h" +#include "src/compiler/code-assembler.h" +#include "src/handles-inl.h" +#include "src/heap/heap-inl.h" // For MemoryAllocator::code_range. +#include "src/interface-descriptors.h" +#include "src/interpreter/bytecodes.h" +#include "src/interpreter/interpreter-generator.h" +#include "src/interpreter/interpreter.h" +#include "src/isolate.h" +#include "src/macro-assembler.h" +#include "src/objects-inl.h" +#include "src/objects/shared-function-info.h" +#include "src/objects/smi.h" \ No newline at end of file diff --git a/tools/v8_gypfiles/toolchain.gypi b/tools/v8_gypfiles/toolchain.gypi index 64914284e7efd7..de2280ab6d463f 100644 --- a/tools/v8_gypfiles/toolchain.gypi +++ b/tools/v8_gypfiles/toolchain.gypi @@ -293,7 +293,7 @@ 'defines': [ 'V8_TARGET_ARCH_ARM64', ], - }], + }], # v8_target_arch=="arm64" ['v8_target_arch=="s390" or v8_target_arch=="s390x"', { 'defines': [ 'V8_TARGET_ARCH_S390', @@ -312,7 +312,7 @@ 'cflags': [ '-march=z196' ], }], ], - }], # s390 + }], # v8_target_arch=="s390*" ['v8_target_arch=="ppc" or v8_target_arch=="ppc64"', { 'defines': [ 'V8_TARGET_ARCH_PPC', @@ -344,7 +344,7 @@ ], }], ], - }], # ppc + }], # v8_target_arch=="ppc**" ['v8_target_arch=="ia32"', { 'defines': [ 'V8_TARGET_ARCH_IA32', @@ -392,7 +392,7 @@ ], }], #'_toolset=="host" ], - }], + }], # v8_target_arch=="mips***" ['v8_target_arch=="mips"', { 'defines': [ 'V8_TARGET_ARCH_MIPS', @@ -982,12 +982,12 @@ # selection. # gcc -- http://gcc.gnu.org/onlinedocs/gcc-4.8.0/gcc/Optimize-Options.html 'ldflags': [ '-fuse-ld=gold', ], - }], + }], # linux_use_gold_flags==1 ['linux_use_bundled_binutils==1', { 'cflags': [ '-B