From 1123425dd1060a53e7b895e13e73ba3bffba1c6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl=20Zasso?= Date: Tue, 12 May 2020 20:37:22 +0200 Subject: [PATCH] deps: update V8 to 8.3.110.9 PR-URL: https://github.com/nodejs/node/pull/33376 Reviewed-By: Jiawen Geng --- deps/v8/.git-blame-ignore-revs | 3 + deps/v8/AUTHORS | 6 + deps/v8/BUILD.gn | 213 ++- deps/v8/COMMON_OWNERS | 4 +- deps/v8/DEPS | 68 +- .../trace_event/common/trace_event_common.h | 64 +- deps/v8/gni/proto_library.gni | 36 +- deps/v8/gni/v8.gni | 45 + deps/v8/include/OWNERS | 1 + deps/v8/include/cppgc/README.md | 5 + deps/v8/include/cppgc/allocation.h | 91 ++ deps/v8/include/cppgc/finalizer-trait.h | 90 ++ deps/v8/include/cppgc/garbage-collected.h | 53 + deps/v8/include/cppgc/gc-info.h | 43 + deps/v8/include/cppgc/heap.h | 31 + deps/v8/include/cppgc/internals.h | 41 + deps/v8/include/cppgc/platform.h | 31 + deps/v8/include/js_protocol.pdl | 36 +- deps/v8/include/v8-fast-api-calls.h | 408 ++++++ deps/v8/include/v8-inspector.h | 3 - deps/v8/include/v8-internal.h | 4 - deps/v8/include/v8-version.h | 6 +- deps/v8/include/v8.h | 268 ++-- deps/v8/infra/testing/builders.pyl | 15 +- deps/v8/samples/hello-world.cc | 9 +- deps/v8/samples/process.cc | 34 +- deps/v8/samples/shell.cc | 69 +- deps/v8/src/DEPS | 1 + deps/v8/src/api/api-inl.h | 2 +- deps/v8/src/api/api.cc | 325 ++++- deps/v8/src/api/api.h | 11 +- deps/v8/src/asmjs/asm-js.cc | 64 +- deps/v8/src/ast/ast-traversal-visitor.h | 16 - deps/v8/src/ast/ast-value-factory.cc | 159 ++- deps/v8/src/ast/ast-value-factory.h | 94 +- deps/v8/src/ast/ast.cc | 152 +- deps/v8/src/ast/ast.h | 340 ++--- deps/v8/src/ast/modules.cc | 28 +- deps/v8/src/ast/modules.h | 6 +- deps/v8/src/ast/prettyprinter.cc | 89 +- deps/v8/src/ast/prettyprinter.h | 10 +- deps/v8/src/ast/scopes.cc | 76 +- deps/v8/src/ast/scopes.h | 19 +- deps/v8/src/ast/variables.h | 3 +- deps/v8/src/base/address-region.h | 10 + deps/v8/src/base/atomic-utils.h | 29 +- deps/v8/src/base/atomicops.h | 87 +- .../atomicops_internals_atomicword_compat.h | 6 - .../src/base/atomicops_internals_portable.h | 10 - deps/v8/src/base/atomicops_internals_std.h | 14 - deps/v8/src/base/bits-iterator.h | 58 + deps/v8/src/base/build_config.h | 17 +- deps/v8/src/base/cpu.cc | 78 +- deps/v8/src/base/enum-set.h | 41 +- deps/v8/src/base/macros.h | 10 +- deps/v8/src/base/platform/platform-freebsd.cc | 18 + deps/v8/src/base/platform/platform-macos.cc | 5 + deps/v8/src/base/platform/platform-posix.cc | 44 +- deps/v8/src/base/platform/platform-win32.cc | 26 + deps/v8/src/base/platform/platform.h | 36 + deps/v8/src/builtins/arm/builtins-arm.cc | 150 +- deps/v8/src/builtins/arm64/builtins-arm64.cc | 156 +- deps/v8/src/builtins/array-lastindexof.tq | 5 +- deps/v8/src/builtins/base.tq | 117 +- deps/v8/src/builtins/builtins-api.cc | 25 +- deps/v8/src/builtins/builtins-array-gen.cc | 33 +- .../builtins/builtins-async-generator-gen.cc | 12 +- .../builtins/builtins-async-iterator-gen.cc | 23 +- deps/v8/src/builtins/builtins-call-gen.cc | 42 +- deps/v8/src/builtins/builtins-call-gen.h | 7 +- .../src/builtins/builtins-collections-gen.cc | 37 +- .../src/builtins/builtins-constructor-gen.cc | 52 +- .../src/builtins/builtins-constructor-gen.h | 20 +- .../src/builtins/builtins-conversion-gen.cc | 23 +- deps/v8/src/builtins/builtins-definitions.h | 108 +- deps/v8/src/builtins/builtins-descriptors.h | 28 + .../v8/src/builtins/builtins-generator-gen.cc | 12 +- deps/v8/src/builtins/builtins-internal-gen.cc | 10 +- deps/v8/src/builtins/builtins-iterator-gen.cc | 108 +- deps/v8/src/builtins/builtins-iterator-gen.h | 16 +- .../builtins/builtins-microtask-queue-gen.cc | 94 +- deps/v8/src/builtins/builtins-object-gen.cc | 26 +- deps/v8/src/builtins/builtins-promise-gen.cc | 5 - deps/v8/src/builtins/builtins-promise-gen.h | 2 - deps/v8/src/builtins/builtins-proxy-gen.cc | 7 +- deps/v8/src/builtins/builtins-regexp-gen.cc | 10 +- deps/v8/src/builtins/builtins-regexp-gen.h | 11 +- .../builtins/builtins-sharedarraybuffer.cc | 24 +- deps/v8/src/builtins/builtins-string-gen.cc | 51 +- deps/v8/src/builtins/builtins-string.tq | 2 +- .../src/builtins/builtins-typed-array-gen.cc | 11 +- .../src/builtins/builtins-typed-array-gen.h | 2 - deps/v8/src/builtins/builtins-utils-inl.h | 14 +- deps/v8/src/builtins/builtins-utils.h | 23 +- deps/v8/src/builtins/builtins-wasm-gen.cc | 186 ++- deps/v8/src/builtins/builtins-weak-refs.cc | 74 +- deps/v8/src/builtins/builtins.cc | 2 + deps/v8/src/builtins/cast.tq | 4 +- deps/v8/src/builtins/convert.tq | 6 + deps/v8/src/builtins/ia32/builtins-ia32.cc | 265 +++- deps/v8/src/builtins/internal-coverage.tq | 32 +- deps/v8/src/builtins/iterator.tq | 8 +- deps/v8/src/builtins/mips/builtins-mips.cc | 104 +- .../v8/src/builtins/mips64/builtins-mips64.cc | 104 +- deps/v8/src/builtins/number.tq | 2 +- deps/v8/src/builtins/ppc/builtins-ppc.cc | 159 ++- .../builtins/promise-abstract-operations.tq | 52 +- deps/v8/src/builtins/promise-misc.tq | 59 +- deps/v8/src/builtins/promise-reaction-job.tq | 50 +- deps/v8/src/builtins/promise-resolve.tq | 9 +- deps/v8/src/builtins/s390/builtins-s390.cc | 363 +++-- .../src/builtins/setup-builtins-internal.cc | 7 +- deps/v8/src/builtins/string-repeat.tq | 2 +- deps/v8/src/builtins/torque-internal.tq | 11 +- .../builtins/typed-array-createtypedarray.tq | 2 - deps/v8/src/builtins/x64/builtins-x64.cc | 619 ++++++-- deps/v8/src/codegen/OWNERS | 2 + .../v8/src/codegen/arm/macro-assembler-arm.cc | 66 +- deps/v8/src/codegen/arm/macro-assembler-arm.h | 21 +- deps/v8/src/codegen/arm/register-arm.h | 12 - .../src/codegen/arm64/assembler-arm64-inl.h | 13 - deps/v8/src/codegen/arm64/assembler-arm64.cc | 94 +- deps/v8/src/codegen/arm64/assembler-arm64.h | 19 +- deps/v8/src/codegen/arm64/constants-arm64.h | 39 +- .../src/codegen/arm64/instructions-arm64.cc | 22 - .../v8/src/codegen/arm64/instructions-arm64.h | 32 +- .../codegen/arm64/macro-assembler-arm64-inl.h | 232 ++- .../codegen/arm64/macro-assembler-arm64.cc | 392 +++-- .../src/codegen/arm64/macro-assembler-arm64.h | 130 +- deps/v8/src/codegen/arm64/register-arm64.h | 26 - deps/v8/src/codegen/assembler-arch.h | 2 +- deps/v8/src/codegen/assembler-inl.h | 2 +- deps/v8/src/codegen/assembler.cc | 3 +- deps/v8/src/codegen/assembler.h | 2 +- deps/v8/src/codegen/code-stub-assembler.cc | 568 +++++--- deps/v8/src/codegen/code-stub-assembler.h | 196 ++- deps/v8/src/codegen/compiler.cc | 489 +++++-- deps/v8/src/codegen/compiler.h | 49 +- deps/v8/src/codegen/constant-pool.cc | 4 +- deps/v8/src/codegen/constant-pool.h | 4 +- deps/v8/src/codegen/constants-arch.h | 2 +- deps/v8/src/codegen/cpu-features.h | 2 +- deps/v8/src/codegen/external-reference.cc | 8 +- deps/v8/src/codegen/external-reference.h | 1 + deps/v8/src/codegen/ia32/assembler-ia32.h | 2 + .../src/codegen/ia32/macro-assembler-ia32.cc | 88 +- .../src/codegen/ia32/macro-assembler-ia32.h | 59 +- deps/v8/src/codegen/ia32/sse-instr.h | 6 + deps/v8/src/codegen/interface-descriptors.cc | 27 +- deps/v8/src/codegen/interface-descriptors.h | 170 ++- deps/v8/src/codegen/machine-type.h | 6 +- deps/v8/src/codegen/macro-assembler.h | 2 +- deps/v8/src/codegen/mips/constants-mips.h | 15 +- .../mips/interface-descriptors-mips.cc | 27 +- .../src/codegen/mips/macro-assembler-mips.cc | 54 +- .../src/codegen/mips/macro-assembler-mips.h | 14 +- .../mips64/interface-descriptors-mips64.cc | 27 +- .../codegen/mips64/macro-assembler-mips64.cc | 54 +- .../codegen/mips64/macro-assembler-mips64.h | 14 +- deps/v8/src/codegen/ppc/assembler-ppc.cc | 4 +- deps/v8/src/codegen/ppc/assembler-ppc.h | 4 - deps/v8/src/codegen/ppc/constants-ppc.cc | 4 +- deps/v8/src/codegen/ppc/constants-ppc.h | 16 +- deps/v8/src/codegen/ppc/cpu-ppc.cc | 4 +- .../codegen/ppc/interface-descriptors-ppc.cc | 4 +- .../v8/src/codegen/ppc/macro-assembler-ppc.cc | 84 +- deps/v8/src/codegen/ppc/macro-assembler-ppc.h | 22 +- deps/v8/src/codegen/ppc/register-ppc.h | 11 - deps/v8/src/codegen/register-arch.h | 2 +- deps/v8/src/codegen/register-configuration.cc | 2 + deps/v8/src/codegen/reloc-info.cc | 2 +- deps/v8/src/codegen/s390/assembler-s390-inl.h | 77 +- deps/v8/src/codegen/s390/assembler-s390.cc | 10 - deps/v8/src/codegen/s390/assembler-s390.h | 17 +- deps/v8/src/codegen/s390/constants-s390.h | 11 +- .../src/codegen/s390/macro-assembler-s390.cc | 320 +++-- .../src/codegen/s390/macro-assembler-s390.h | 91 +- deps/v8/src/codegen/s390/register-s390.h | 12 - deps/v8/src/codegen/source-position-table.cc | 63 +- deps/v8/src/codegen/source-position-table.h | 46 +- deps/v8/src/codegen/tnode.h | 6 + deps/v8/src/codegen/turbo-assembler.h | 1 + deps/v8/src/codegen/x64/assembler-x64.cc | 76 - deps/v8/src/codegen/x64/assembler-x64.h | 57 +- .../v8/src/codegen/x64/macro-assembler-x64.cc | 125 +- deps/v8/src/codegen/x64/macro-assembler-x64.h | 112 +- deps/v8/src/codegen/x64/sse-instr.h | 24 +- deps/v8/src/common/globals.h | 43 +- deps/v8/src/common/message-template.h | 13 +- .../backend/arm/code-generator-arm.cc | 237 ++-- .../backend/arm/instruction-codes-arm.h | 6 + .../backend/arm/instruction-scheduler-arm.cc | 6 + .../backend/arm/instruction-selector-arm.cc | 107 +- .../backend/arm64/code-generator-arm64.cc | 306 ++-- .../backend/arm64/instruction-codes-arm64.h | 6 + .../arm64/instruction-scheduler-arm64.cc | 6 + .../arm64/instruction-selector-arm64.cc | 81 +- .../arm64/unwinding-info-writer-arm64.cc | 3 + .../compiler/backend/code-generator-impl.h | 4 + .../v8/src/compiler/backend/code-generator.cc | 61 +- deps/v8/src/compiler/backend/code-generator.h | 5 +- .../backend/ia32/code-generator-ia32.cc | 316 ++--- .../backend/ia32/instruction-codes-ia32.h | 24 +- .../ia32/instruction-scheduler-ia32.cc | 24 +- .../backend/ia32/instruction-selector-ia32.cc | 144 +- .../src/compiler/backend/instruction-codes.h | 3 +- .../compiler/backend/instruction-scheduler.cc | 1 - .../backend/instruction-selector-impl.h | 20 +- .../compiler/backend/instruction-selector.cc | 137 +- .../compiler/backend/instruction-selector.h | 21 +- deps/v8/src/compiler/backend/instruction.h | 8 +- .../v8/src/compiler/backend/jump-threading.cc | 17 +- .../backend/mips/code-generator-mips.cc | 37 +- .../backend/mips/instruction-codes-mips.h | 3 + .../mips/instruction-scheduler-mips.cc | 11 +- .../backend/mips/instruction-selector-mips.cc | 5 +- .../backend/mips64/code-generator-mips64.cc | 36 +- .../backend/mips64/instruction-codes-mips64.h | 3 + .../mips64/instruction-scheduler-mips64.cc | 13 +- .../mips64/instruction-selector-mips64.cc | 5 +- .../backend/ppc/code-generator-ppc.cc | 22 +- .../backend/ppc/instruction-selector-ppc.cc | 8 +- .../compiler/backend/register-allocator.cc | 17 +- .../src/compiler/backend/register-allocator.h | 1 + .../backend/s390/code-generator-s390.cc | 915 ++++++++++-- .../backend/s390/instruction-codes-s390.h | 86 +- .../s390/instruction-scheduler-s390.cc | 82 ++ .../backend/s390/instruction-selector-s390.cc | 465 +++--- .../compiler/backend/unwinding-info-writer.h | 2 +- .../backend/x64/code-generator-x64.cc | 676 +++++---- .../backend/x64/instruction-codes-x64.h | 3 + .../backend/x64/instruction-scheduler-x64.cc | 3 + .../backend/x64/instruction-selector-x64.cc | 73 +- deps/v8/src/compiler/branch-elimination.cc | 5 + deps/v8/src/compiler/bytecode-analysis.cc | 23 +- .../v8/src/compiler/bytecode-graph-builder.cc | 70 +- deps/v8/src/compiler/c-linkage.cc | 3 +- deps/v8/src/compiler/code-assembler.cc | 115 +- deps/v8/src/compiler/code-assembler.h | 112 +- deps/v8/src/compiler/common-node-cache.cc | 6 +- deps/v8/src/compiler/common-node-cache.h | 39 +- .../src/compiler/common-operator-reducer.cc | 3 + deps/v8/src/compiler/common-operator.cc | 28 +- deps/v8/src/compiler/common-operator.h | 9 +- .../src/compiler/constant-folding-reducer.cc | 101 +- deps/v8/src/compiler/dead-code-elimination.cc | 5 +- .../src/compiler/effect-control-linearizer.cc | 111 +- deps/v8/src/compiler/graph-assembler.cc | 14 + deps/v8/src/compiler/graph-assembler.h | 4 + deps/v8/src/compiler/heap-refs.h | 8 +- deps/v8/src/compiler/int64-lowering.cc | 10 +- deps/v8/src/compiler/int64-lowering.h | 19 +- deps/v8/src/compiler/js-call-reducer.cc | 141 +- deps/v8/src/compiler/js-create-lowering.cc | 31 +- deps/v8/src/compiler/js-generic-lowering.cc | 41 +- deps/v8/src/compiler/js-graph.cc | 2 + deps/v8/src/compiler/js-graph.h | 3 +- deps/v8/src/compiler/js-heap-broker.cc | 97 +- deps/v8/src/compiler/js-heap-broker.h | 1 - deps/v8/src/compiler/js-heap-copy-reducer.cc | 6 + deps/v8/src/compiler/js-inlining-heuristic.cc | 14 + deps/v8/src/compiler/js-inlining.cc | 24 +- .../js-native-context-specialization.cc | 40 +- deps/v8/src/compiler/js-typed-lowering.cc | 76 +- deps/v8/src/compiler/linkage.cc | 4 +- deps/v8/src/compiler/linkage.h | 22 +- deps/v8/src/compiler/machine-graph.cc | 9 + deps/v8/src/compiler/machine-graph.h | 2 + .../src/compiler/machine-operator-reducer.cc | 58 + .../src/compiler/machine-operator-reducer.h | 1 + deps/v8/src/compiler/machine-operator.cc | 100 +- deps/v8/src/compiler/machine-operator.h | 6 + deps/v8/src/compiler/node-cache.cc | 125 -- deps/v8/src/compiler/node-cache.h | 40 +- deps/v8/src/compiler/node-matchers.h | 33 +- deps/v8/src/compiler/opcodes.h | 64 +- deps/v8/src/compiler/operation-typer.cc | 96 +- deps/v8/src/compiler/operator.h | 23 +- deps/v8/src/compiler/pipeline.cc | 11 +- .../v8/src/compiler/redundancy-elimination.cc | 1 + deps/v8/src/compiler/representation-change.cc | 6 +- deps/v8/src/compiler/representation-change.h | 3 + .../serializer-for-background-compilation.cc | 19 +- deps/v8/src/compiler/simd-scalar-lowering.cc | 162 ++- deps/v8/src/compiler/simd-scalar-lowering.h | 1 + deps/v8/src/compiler/simplified-lowering.cc | 137 +- deps/v8/src/compiler/simplified-operator.cc | 103 +- deps/v8/src/compiler/simplified-operator.h | 48 +- deps/v8/src/compiler/state-values-utils.cc | 30 +- deps/v8/src/compiler/state-values-utils.h | 18 +- deps/v8/src/compiler/type-cache.h | 2 +- deps/v8/src/compiler/typed-optimization.cc | 6 +- deps/v8/src/compiler/typer.cc | 424 +++--- deps/v8/src/compiler/types.cc | 36 +- deps/v8/src/compiler/types.h | 37 +- deps/v8/src/compiler/verifier.cc | 67 +- deps/v8/src/compiler/wasm-compiler.cc | 1257 ++++++++--------- deps/v8/src/compiler/wasm-compiler.h | 81 +- deps/v8/src/d8/OWNERS | 1 + deps/v8/src/d8/async-hooks-wrapper.cc | 42 +- deps/v8/src/d8/d8-console.cc | 4 +- deps/v8/src/d8/d8-posix.cc | 219 +-- deps/v8/src/d8/d8.cc | 428 +++--- deps/v8/src/d8/d8.h | 7 +- deps/v8/src/date/date.cc | 2 +- deps/v8/src/debug/arm64/debug-arm64.cc | 2 +- deps/v8/src/debug/debug-coverage.cc | 6 +- deps/v8/src/debug/debug-evaluate.cc | 8 +- deps/v8/src/debug/debug-interface.h | 16 +- deps/v8/src/debug/debug-scope-iterator.cc | 37 +- deps/v8/src/debug/debug-scopes.cc | 13 +- deps/v8/src/debug/debug.cc | 71 +- deps/v8/src/debug/debug.h | 9 +- deps/v8/src/debug/liveedit.cc | 2 +- deps/v8/src/debug/ppc/debug-ppc.cc | 4 +- deps/v8/src/debug/s390/debug-s390.cc | 3 +- .../wasm/gdb-server/gdb-server-thread.cc | 118 ++ .../debug/wasm/gdb-server/gdb-server-thread.h | 61 + .../src/debug/wasm/gdb-server/gdb-server.cc | 38 + .../v8/src/debug/wasm/gdb-server/gdb-server.h | 43 + deps/v8/src/debug/wasm/gdb-server/session.cc | 48 + deps/v8/src/debug/wasm/gdb-server/session.h | 59 + deps/v8/src/debug/wasm/gdb-server/target.cc | 65 + deps/v8/src/debug/wasm/gdb-server/target.h | 57 + .../v8/src/debug/wasm/gdb-server/transport.cc | 444 ++++++ deps/v8/src/debug/wasm/gdb-server/transport.h | 183 +++ deps/v8/src/debug/wasm/gdb-server/util.h | 27 + .../v8/src/deoptimizer/arm/deoptimizer-arm.cc | 7 +- .../deoptimizer/arm64/deoptimizer-arm64.cc | 27 +- deps/v8/src/deoptimizer/deoptimize-reason.h | 1 + deps/v8/src/deoptimizer/deoptimizer.cc | 51 +- deps/v8/src/deoptimizer/deoptimizer.h | 9 +- .../src/deoptimizer/ia32/deoptimizer-ia32.cc | 7 +- .../src/deoptimizer/mips/deoptimizer-mips.cc | 7 +- .../deoptimizer/mips64/deoptimizer-mips64.cc | 7 +- .../v8/src/deoptimizer/ppc/deoptimizer-ppc.cc | 7 +- .../src/deoptimizer/s390/deoptimizer-s390.cc | 7 +- .../v8/src/deoptimizer/x64/deoptimizer-x64.cc | 15 +- deps/v8/src/diagnostics/arm64/disasm-arm64.cc | 27 +- deps/v8/src/diagnostics/code-tracer.h | 4 + deps/v8/src/diagnostics/ia32/disasm-ia32.cc | 2 + deps/v8/src/diagnostics/objects-debug.cc | 39 +- deps/v8/src/diagnostics/objects-printer.cc | 53 +- deps/v8/src/diagnostics/perf-jit.h | 5 +- deps/v8/src/diagnostics/ppc/disasm-ppc.cc | 4 +- deps/v8/src/diagnostics/unwinder.cc | 11 +- .../src/diagnostics/unwinding-info-win64.cc | 33 +- .../v8/src/diagnostics/unwinding-info-win64.h | 6 +- deps/v8/src/diagnostics/x64/disasm-x64.cc | 45 +- deps/v8/src/execution/arguments-inl.h | 18 +- deps/v8/src/execution/arguments.h | 46 +- .../src/execution/arm/frame-constants-arm.h | 39 + deps/v8/src/execution/arm/simulator-arm.cc | 132 +- deps/v8/src/execution/arm/simulator-arm.h | 2 +- .../execution/arm64/frame-constants-arm64.h | 41 + .../arm64/pointer-authentication-arm64.h | 164 +++ .../v8/src/execution/arm64/simulator-arm64.cc | 89 +- deps/v8/src/execution/arm64/simulator-arm64.h | 126 ++ deps/v8/src/execution/execution.cc | 7 +- deps/v8/src/execution/frame-constants.h | 15 +- deps/v8/src/execution/frames-inl.h | 25 +- deps/v8/src/execution/frames.cc | 44 +- deps/v8/src/execution/frames.h | 43 +- deps/v8/src/execution/futex-emulation.cc | 62 +- deps/v8/src/execution/futex-emulation.h | 13 +- .../src/execution/ia32/frame-constants-ia32.h | 37 + deps/v8/src/execution/isolate-data.h | 8 + deps/v8/src/execution/isolate-inl.h | 12 + deps/v8/src/execution/isolate-utils-inl.h | 14 +- deps/v8/src/execution/isolate.cc | 97 +- deps/v8/src/execution/isolate.h | 147 +- deps/v8/src/execution/messages.cc | 68 +- deps/v8/src/execution/messages.h | 4 +- .../src/execution/mips/frame-constants-mips.h | 37 + deps/v8/src/execution/mips/simulator-mips.cc | 26 +- .../execution/mips64/frame-constants-mips64.h | 37 + .../src/execution/mips64/simulator-mips64.cc | 26 +- deps/v8/src/execution/off-thread-isolate.cc | 45 + deps/v8/src/execution/off-thread-isolate.h | 99 ++ .../execution/pointer-authentication-dummy.h | 56 + .../v8/src/execution/pointer-authentication.h | 65 + .../src/execution/ppc/frame-constants-ppc.cc | 4 +- .../src/execution/ppc/frame-constants-ppc.h | 38 + deps/v8/src/execution/ppc/simulator-ppc.cc | 126 +- deps/v8/src/execution/ppc/simulator-ppc.h | 1 + deps/v8/src/execution/runtime-profiler.cc | 22 +- .../src/execution/s390/frame-constants-s390.h | 38 + deps/v8/src/execution/s390/simulator-s390.cc | 471 ++++-- deps/v8/src/execution/s390/simulator-s390.h | 4 +- deps/v8/src/execution/simulator-base.h | 1 + deps/v8/src/execution/simulator.h | 2 +- deps/v8/src/execution/stack-guard.h | 2 +- .../src/execution/x64/frame-constants-x64.h | 37 + .../src/extensions/cputracemark-extension.cc | 10 +- .../externalize-string-extension.cc | 37 +- .../v8/src/extensions/statistics-extension.cc | 20 +- .../vtunedomain-support-extension.cc | 14 +- deps/v8/src/flags/flag-definitions.h | 101 +- deps/v8/src/flags/flags.cc | 9 +- deps/v8/src/handles/factory-handles.h | 23 - deps/v8/src/handles/global-handles.cc | 27 +- deps/v8/src/handles/global-handles.h | 8 +- deps/v8/src/handles/handles-inl.h | 53 +- deps/v8/src/handles/handles.cc | 2 + deps/v8/src/handles/handles.h | 133 +- deps/v8/src/handles/local-handles-inl.h | 61 + deps/v8/src/handles/local-handles.cc | 58 + deps/v8/src/handles/local-handles.h | 57 + deps/v8/src/handles/maybe-handles.h | 8 +- deps/v8/src/heap/OWNERS | 4 + deps/v8/src/heap/array-buffer-sweeper.cc | 114 +- deps/v8/src/heap/array-buffer-sweeper.h | 36 +- deps/v8/src/heap/array-buffer-tracker-inl.h | 18 +- deps/v8/src/heap/array-buffer-tracker.cc | 4 +- deps/v8/src/heap/concurrent-marking.cc | 2 +- deps/v8/src/heap/cppgc/allocation.cc | 23 + .../src/heap/cppgc/asm/x64/push_registers.S | 52 + .../heap/cppgc/asm/x64/push_registers_win.S | 45 + deps/v8/src/heap/cppgc/gc-info-table.cc | 124 ++ deps/v8/src/heap/cppgc/gc-info-table.h | 113 ++ deps/v8/src/heap/cppgc/gc-info.cc | 18 + deps/v8/src/heap/cppgc/globals.h | 39 + deps/v8/src/heap/cppgc/heap-inl.h | 36 + .../src/heap/cppgc/heap-object-header-inl.h | 148 ++ deps/v8/src/heap/cppgc/heap-object-header.cc | 30 + deps/v8/src/heap/cppgc/heap-object-header.h | 127 ++ deps/v8/src/heap/cppgc/heap.cc | 28 + deps/v8/src/heap/cppgc/heap.h | 35 + deps/v8/src/heap/cppgc/platform.cc | 29 + deps/v8/src/heap/cppgc/sanitizers.h | 38 + deps/v8/src/heap/cppgc/stack.cc | 136 ++ deps/v8/src/heap/cppgc/stack.h | 49 + deps/v8/src/heap/embedder-tracing.cc | 1 - deps/v8/src/heap/embedder-tracing.h | 9 +- deps/v8/src/heap/factory-base-inl.h | 99 ++ deps/v8/src/heap/factory-base.cc | 614 +++++++- deps/v8/src/heap/factory-base.h | 187 ++- deps/v8/src/heap/factory-inl.h | 43 +- deps/v8/src/heap/factory.cc | 581 +------- deps/v8/src/heap/factory.h | 169 +-- .../heap/finalization-group-cleanup-task.h | 36 - ... => finalization-registry-cleanup-task.cc} | 43 +- .../heap/finalization-registry-cleanup-task.h | 36 + deps/v8/src/heap/gc-idle-time-handler.cc | 38 +- deps/v8/src/heap/gc-idle-time-handler.h | 33 - deps/v8/src/heap/gc-tracer.cc | 16 +- deps/v8/src/heap/gc-tracer.h | 7 + deps/v8/src/heap/heap-inl.h | 51 +- deps/v8/src/heap/heap-write-barrier-inl.h | 1 + deps/v8/src/heap/heap.cc | 339 +++-- deps/v8/src/heap/heap.h | 107 +- deps/v8/src/heap/incremental-marking-job.cc | 69 +- deps/v8/src/heap/incremental-marking-job.h | 14 +- deps/v8/src/heap/incremental-marking.cc | 222 +-- deps/v8/src/heap/incremental-marking.h | 39 +- deps/v8/src/heap/local-heap.cc | 71 + deps/v8/src/heap/local-heap.h | 89 ++ deps/v8/src/heap/mark-compact-inl.h | 10 +- deps/v8/src/heap/mark-compact.cc | 35 +- deps/v8/src/heap/marking-worklist.h | 4 + deps/v8/src/heap/memory-measurement.cc | 11 +- deps/v8/src/heap/memory-measurement.h | 4 +- deps/v8/src/heap/object-stats.h | 2 +- deps/v8/src/heap/objects-visiting-inl.h | 3 + deps/v8/src/heap/objects-visiting.cc | 27 + deps/v8/src/heap/objects-visiting.h | 5 +- deps/v8/src/heap/off-thread-factory-inl.h | 17 +- deps/v8/src/heap/off-thread-factory.cc | 163 ++- deps/v8/src/heap/off-thread-factory.h | 54 +- deps/v8/src/heap/read-only-heap.cc | 9 +- deps/v8/src/heap/safepoint.cc | 134 ++ deps/v8/src/heap/safepoint.h | 77 + deps/v8/src/heap/scavenge-job.cc | 115 +- deps/v8/src/heap/scavenge-job.h | 66 +- deps/v8/src/heap/setup-heap-internal.cc | 19 +- deps/v8/src/heap/spaces.cc | 53 +- deps/v8/src/heap/spaces.h | 69 +- deps/v8/src/heap/third-party/heap-api.h | 7 +- deps/v8/src/heap/worklist.h | 50 +- deps/v8/src/ic/accessor-assembler.cc | 152 +- deps/v8/src/ic/accessor-assembler.h | 33 +- deps/v8/src/ic/ic.cc | 65 +- deps/v8/src/ic/keyed-store-generic.cc | 11 +- deps/v8/src/ic/stub-cache.h | 15 +- deps/v8/src/init/bootstrapper.cc | 70 +- deps/v8/src/init/heap-symbols.h | 1 + deps/v8/src/inspector/custom-preview.cc | 6 +- deps/v8/src/inspector/injected-script.cc | 160 ++- deps/v8/src/inspector/remote-object-id.cc | 19 +- deps/v8/src/inspector/string-16.cc | 15 +- deps/v8/src/inspector/string-16.h | 6 +- deps/v8/src/inspector/string-util.cc | 36 +- deps/v8/src/inspector/string-util.h | 55 +- .../v8/src/inspector/v8-console-agent-impl.cc | 10 +- deps/v8/src/inspector/v8-console.cc | 2 +- .../src/inspector/v8-debugger-agent-impl.cc | 289 ++-- .../v8/src/inspector/v8-debugger-agent-impl.h | 2 +- deps/v8/src/inspector/v8-debugger-script.cc | 13 + deps/v8/src/inspector/v8-debugger-script.h | 3 + deps/v8/src/inspector/v8-debugger.cc | 28 +- deps/v8/src/inspector/v8-debugger.h | 3 +- .../inspector/v8-heap-profiler-agent-impl.cc | 50 +- deps/v8/src/inspector/v8-inspector-impl.cc | 4 +- .../inspector/v8-inspector-session-impl.cc | 81 +- .../src/inspector/v8-inspector-session-impl.h | 8 +- .../src/inspector/v8-profiler-agent-impl.cc | 79 +- .../v8/src/inspector/v8-profiler-agent-impl.h | 1 + .../v8/src/inspector/v8-runtime-agent-impl.cc | 142 +- deps/v8/src/inspector/v8-schema-agent-impl.cc | 2 +- deps/v8/src/inspector/v8-stack-trace-impl.cc | 21 +- deps/v8/src/inspector/value-mirror.cc | 45 +- .../src/interpreter/bytecode-array-builder.cc | 65 +- .../src/interpreter/bytecode-array-builder.h | 17 +- .../src/interpreter/bytecode-array-writer.cc | 40 +- .../src/interpreter/bytecode-array-writer.h | 14 +- deps/v8/src/interpreter/bytecode-generator.cc | 460 +++--- deps/v8/src/interpreter/bytecode-generator.h | 41 +- deps/v8/src/interpreter/bytecode-operands.h | 2 +- .../bytecode-register-optimizer.cc | 7 +- deps/v8/src/interpreter/bytecode-register.cc | 15 + deps/v8/src/interpreter/bytecodes.h | 10 +- .../src/interpreter/constant-array-builder.cc | 37 +- .../src/interpreter/constant-array-builder.h | 15 +- .../src/interpreter/control-flow-builders.cc | 31 +- .../src/interpreter/control-flow-builders.h | 26 +- .../src/interpreter/handler-table-builder.cc | 7 +- .../src/interpreter/handler-table-builder.h | 3 +- .../src/interpreter/interpreter-assembler.cc | 35 +- .../src/interpreter/interpreter-assembler.h | 3 + .../src/interpreter/interpreter-generator.cc | 137 +- deps/v8/src/interpreter/interpreter.cc | 51 +- deps/v8/src/interpreter/interpreter.h | 3 - deps/v8/src/json/json-parser.cc | 2 +- deps/v8/src/libplatform/tracing/DEPS | 1 + .../tracing/json-trace-event-listener.h | 4 +- .../tracing/trace-event-listener.h | 4 +- deps/v8/src/libsampler/sampler.cc | 6 +- deps/v8/src/logging/counters-definitions.h | 32 +- deps/v8/src/logging/counters.cc | 10 + deps/v8/src/logging/counters.h | 9 +- deps/v8/src/logging/log.cc | 63 +- deps/v8/src/logging/log.h | 21 +- deps/v8/src/logging/off-thread-logger.h | 31 + deps/v8/src/numbers/conversions-inl.h | 4 +- deps/v8/src/numbers/conversions.cc | 183 +-- deps/v8/src/numbers/conversions.h | 6 +- deps/v8/src/objects/allocation-site-inl.h | 4 +- deps/v8/src/objects/api-callbacks-inl.h | 1 - deps/v8/src/objects/api-callbacks.h | 21 +- deps/v8/src/objects/api-callbacks.tq | 16 +- deps/v8/src/objects/arguments-inl.h | 2 - deps/v8/src/objects/arguments.h | 3 - deps/v8/src/objects/backing-store.cc | 59 +- deps/v8/src/objects/backing-store.h | 29 +- deps/v8/src/objects/bigint.cc | 58 +- deps/v8/src/objects/bigint.h | 13 +- deps/v8/src/objects/code-inl.h | 1 + deps/v8/src/objects/code.cc | 17 +- deps/v8/src/objects/code.h | 10 +- deps/v8/src/objects/compilation-cache.h | 4 +- deps/v8/src/objects/contexts.cc | 10 + deps/v8/src/objects/contexts.h | 20 +- deps/v8/src/objects/contexts.tq | 2 + deps/v8/src/objects/debug-objects-inl.h | 11 +- deps/v8/src/objects/debug-objects.cc | 54 +- deps/v8/src/objects/debug-objects.h | 71 +- deps/v8/src/objects/debug-objects.tq | 38 +- deps/v8/src/objects/descriptor-array.h | 8 +- deps/v8/src/objects/descriptor-array.tq | 2 +- deps/v8/src/objects/dictionary-inl.h | 61 +- deps/v8/src/objects/dictionary.h | 80 +- deps/v8/src/objects/elements.cc | 48 +- deps/v8/src/objects/elements.h | 9 +- deps/v8/src/objects/embedder-data-array-inl.h | 1 - deps/v8/src/objects/embedder-data-array.h | 4 - deps/v8/src/objects/embedder-data-array.tq | 1 + deps/v8/src/objects/feedback-cell-inl.h | 14 +- deps/v8/src/objects/feedback-cell.h | 9 +- deps/v8/src/objects/feedback-vector-inl.h | 7 +- deps/v8/src/objects/feedback-vector.cc | 33 +- deps/v8/src/objects/feedback-vector.h | 7 +- deps/v8/src/objects/fixed-array.tq | 6 +- deps/v8/src/objects/free-space-inl.h | 3 +- deps/v8/src/objects/hash-table-inl.h | 18 +- deps/v8/src/objects/hash-table.h | 58 +- deps/v8/src/objects/heap-object.h | 7 +- deps/v8/src/objects/heap-object.tq | 2 +- deps/v8/src/objects/instance-type.h | 1 - deps/v8/src/objects/intl-objects.cc | 132 +- deps/v8/src/objects/intl-objects.h | 36 +- deps/v8/src/objects/intl-objects.tq | 62 +- deps/v8/src/objects/js-array-buffer-inl.h | 63 +- deps/v8/src/objects/js-array-buffer.cc | 17 +- deps/v8/src/objects/js-array-buffer.h | 53 +- deps/v8/src/objects/js-array-buffer.tq | 23 + deps/v8/src/objects/js-break-iterator-inl.h | 10 - deps/v8/src/objects/js-break-iterator.cc | 89 +- deps/v8/src/objects/js-break-iterator.h | 8 - deps/v8/src/objects/js-collator.cc | 52 +- deps/v8/src/objects/js-date-time-format-inl.h | 4 +- deps/v8/src/objects/js-date-time-format.cc | 166 ++- deps/v8/src/objects/js-date-time-format.h | 32 +- deps/v8/src/objects/js-display-names-inl.h | 6 +- deps/v8/src/objects/js-display-names.cc | 15 +- deps/v8/src/objects/js-display-names.h | 12 +- deps/v8/src/objects/js-generator-inl.h | 7 - deps/v8/src/objects/js-generator.h | 17 +- deps/v8/src/objects/js-generator.tq | 6 + deps/v8/src/objects/js-list-format.cc | 45 +- deps/v8/src/objects/js-list-format.h | 8 +- deps/v8/src/objects/js-number-format-inl.h | 14 - deps/v8/src/objects/js-number-format.cc | 379 ++--- deps/v8/src/objects/js-number-format.h | 21 - deps/v8/src/objects/js-objects-inl.h | 11 +- deps/v8/src/objects/js-objects.cc | 53 +- deps/v8/src/objects/js-objects.h | 6 +- deps/v8/src/objects/js-plural-rules-inl.h | 6 +- deps/v8/src/objects/js-plural-rules.cc | 16 +- deps/v8/src/objects/js-plural-rules.h | 13 +- deps/v8/src/objects/js-promise-inl.h | 1 - deps/v8/src/objects/js-promise.h | 2 - .../objects/js-regexp-string-iterator-inl.h | 1 - .../src/objects/js-regexp-string-iterator.h | 2 - .../src/objects/js-relative-time-format-inl.h | 17 +- .../v8/src/objects/js-relative-time-format.cc | 126 +- deps/v8/src/objects/js-relative-time-format.h | 31 +- deps/v8/src/objects/js-segment-iterator-inl.h | 2 +- deps/v8/src/objects/js-segment-iterator.h | 8 +- deps/v8/src/objects/js-segmenter.cc | 15 +- deps/v8/src/objects/js-segmenter.h | 8 +- deps/v8/src/objects/js-weak-refs-inl.h | 131 +- deps/v8/src/objects/js-weak-refs.h | 61 +- deps/v8/src/objects/js-weak-refs.tq | 20 +- deps/v8/src/objects/keys.cc | 37 +- deps/v8/src/objects/keys.h | 1 + deps/v8/src/objects/literal-objects-inl.h | 2 - deps/v8/src/objects/literal-objects.cc | 115 +- deps/v8/src/objects/literal-objects.h | 12 +- deps/v8/src/objects/lookup.cc | 3 +- deps/v8/src/objects/map-inl.h | 2 +- deps/v8/src/objects/map.cc | 47 +- deps/v8/src/objects/map.h | 25 +- deps/v8/src/objects/module-inl.h | 18 +- deps/v8/src/objects/name.h | 18 +- deps/v8/src/objects/object-list-macros.h | 11 +- deps/v8/src/objects/object-macros.h | 8 - .../objects/objects-body-descriptors-inl.h | 53 +- .../v8/src/objects/objects-body-descriptors.h | 4 + deps/v8/src/objects/objects-definitions.h | 13 +- deps/v8/src/objects/objects-inl.h | 11 + deps/v8/src/objects/objects.cc | 434 ++++-- deps/v8/src/objects/objects.h | 25 +- deps/v8/src/objects/oddball-inl.h | 8 +- deps/v8/src/objects/ordered-hash-table-inl.h | 24 +- deps/v8/src/objects/ordered-hash-table.cc | 28 +- deps/v8/src/objects/ordered-hash-table.h | 24 +- deps/v8/src/objects/ordered-hash-table.tq | 6 +- deps/v8/src/objects/promise.tq | 8 + .../src/objects/property-descriptor-object.h | 16 +- .../src/objects/property-descriptor-object.tq | 14 +- deps/v8/src/objects/property-descriptor.cc | 4 +- deps/v8/src/objects/scope-info.cc | 38 +- deps/v8/src/objects/scope-info.h | 8 +- deps/v8/src/objects/script.h | 8 +- .../v8/src/objects/shared-function-info-inl.h | 43 +- deps/v8/src/objects/shared-function-info.h | 45 +- deps/v8/src/objects/shared-function-info.tq | 16 +- deps/v8/src/objects/slots-inl.h | 6 + deps/v8/src/objects/slots.h | 1 + deps/v8/src/objects/source-text-module.cc | 11 +- deps/v8/src/objects/source-text-module.h | 29 +- deps/v8/src/objects/source-text-module.tq | 6 + deps/v8/src/objects/stack-frame-info-inl.h | 3 - deps/v8/src/objects/stack-frame-info.cc | 38 +- deps/v8/src/objects/stack-frame-info.h | 3 +- deps/v8/src/objects/string-inl.h | 23 +- deps/v8/src/objects/string-table-inl.h | 8 +- deps/v8/src/objects/string-table.h | 10 +- deps/v8/src/objects/string.cc | 60 +- deps/v8/src/objects/string.h | 12 +- deps/v8/src/objects/string.tq | 2 +- deps/v8/src/objects/struct-inl.h | 3 - deps/v8/src/objects/struct.h | 3 - deps/v8/src/objects/tagged-index.h | 84 ++ deps/v8/src/objects/template-objects-inl.h | 2 - deps/v8/src/objects/template-objects.h | 2 - deps/v8/src/objects/template.tq | 4 + deps/v8/src/objects/templates-inl.h | 28 +- deps/v8/src/objects/templates.h | 18 +- deps/v8/src/parsing/func-name-inferrer.cc | 4 +- deps/v8/src/parsing/func-name-inferrer.h | 2 +- deps/v8/src/parsing/literal-buffer.cc | 8 +- deps/v8/src/parsing/literal-buffer.h | 3 +- deps/v8/src/parsing/parse-info.cc | 136 +- deps/v8/src/parsing/parse-info.h | 52 +- deps/v8/src/parsing/parser-base.h | 202 ++- deps/v8/src/parsing/parser.cc | 184 ++- deps/v8/src/parsing/parser.h | 78 +- deps/v8/src/parsing/parsing.cc | 31 +- deps/v8/src/parsing/parsing.h | 13 +- .../pending-compilation-error-handler.cc | 10 +- .../pending-compilation-error-handler.h | 1 + deps/v8/src/parsing/preparse-data-impl.h | 1 + deps/v8/src/parsing/preparse-data.cc | 57 + deps/v8/src/parsing/preparse-data.h | 8 + deps/v8/src/parsing/preparser.h | 89 +- deps/v8/src/parsing/rewriter.cc | 2 +- .../src/parsing/scanner-character-streams.cc | 29 +- .../src/parsing/scanner-character-streams.h | 2 + deps/v8/src/parsing/scanner.cc | 13 +- deps/v8/src/parsing/scanner.h | 6 +- .../src/profiler/heap-snapshot-generator.cc | 2 +- deps/v8/src/profiler/profile-generator-inl.h | 10 +- deps/v8/src/profiler/profile-generator.cc | 50 +- deps/v8/src/profiler/profile-generator.h | 10 +- deps/v8/src/profiler/profiler-listener.cc | 24 +- deps/v8/src/profiler/strings-storage.cc | 36 +- deps/v8/src/profiler/strings-storage.h | 7 + deps/v8/src/profiler/tick-sample.cc | 2 +- .../regexp/arm/regexp-macro-assembler-arm.cc | 17 +- .../regexp/arm/regexp-macro-assembler-arm.h | 2 +- .../arm64/regexp-macro-assembler-arm64.cc | 32 +- .../arm64/regexp-macro-assembler-arm64.h | 3 +- deps/v8/src/regexp/gen-regexp-special-case.cc | 150 +- .../ia32/regexp-macro-assembler-ia32.cc | 17 +- .../regexp/ia32/regexp-macro-assembler-ia32.h | 2 +- .../mips/regexp-macro-assembler-mips.cc | 17 +- .../regexp/mips/regexp-macro-assembler-mips.h | 2 +- .../mips64/regexp-macro-assembler-mips64.cc | 17 +- .../mips64/regexp-macro-assembler-mips64.h | 2 +- .../regexp/ppc/regexp-macro-assembler-ppc.cc | 21 +- .../regexp/ppc/regexp-macro-assembler-ppc.h | 2 +- deps/v8/src/regexp/regexp-ast.h | 29 +- .../src/regexp/regexp-bytecode-generator.cc | 8 +- .../v8/src/regexp/regexp-bytecode-generator.h | 2 +- .../v8/src/regexp/regexp-bytecode-peephole.cc | 1 - deps/v8/src/regexp/regexp-bytecodes.h | 8 +- deps/v8/src/regexp/regexp-compiler-tonode.cc | 114 +- deps/v8/src/regexp/regexp-compiler.cc | 115 +- deps/v8/src/regexp/regexp-compiler.h | 16 +- deps/v8/src/regexp/regexp-error.cc | 22 + deps/v8/src/regexp/regexp-error.h | 58 + deps/v8/src/regexp/regexp-interpreter.cc | 45 +- .../src/regexp/regexp-macro-assembler-arch.h | 2 +- .../regexp/regexp-macro-assembler-tracer.cc | 10 +- .../regexp/regexp-macro-assembler-tracer.h | 1 - deps/v8/src/regexp/regexp-macro-assembler.cc | 48 +- deps/v8/src/regexp/regexp-macro-assembler.h | 10 +- deps/v8/src/regexp/regexp-parser.cc | 142 +- deps/v8/src/regexp/regexp-parser.h | 20 +- deps/v8/src/regexp/regexp-stack.h | 6 +- deps/v8/src/regexp/regexp.cc | 45 +- deps/v8/src/regexp/regexp.h | 7 +- .../s390/regexp-macro-assembler-s390.cc | 15 +- .../regexp/s390/regexp-macro-assembler-s390.h | 2 +- deps/v8/src/regexp/special-case.h | 141 +- .../regexp/x64/regexp-macro-assembler-x64.cc | 15 +- .../regexp/x64/regexp-macro-assembler-x64.h | 1 - deps/v8/src/roots/roots-inl.h | 6 +- deps/v8/src/roots/roots.h | 25 +- deps/v8/src/runtime/runtime-array.cc | 9 +- deps/v8/src/runtime/runtime-atomics.cc | 2 +- deps/v8/src/runtime/runtime-classes.cc | 36 +- deps/v8/src/runtime/runtime-compiler.cc | 26 +- deps/v8/src/runtime/runtime-debug.cc | 2 +- deps/v8/src/runtime/runtime-internal.cc | 16 + deps/v8/src/runtime/runtime-literals.cc | 6 +- deps/v8/src/runtime/runtime-object.cc | 17 +- deps/v8/src/runtime/runtime-operators.cc | 8 + deps/v8/src/runtime/runtime-proxy.cc | 20 + deps/v8/src/runtime/runtime-scopes.cc | 101 +- deps/v8/src/runtime/runtime-test.cc | 12 +- deps/v8/src/runtime/runtime-utils.h | 16 +- deps/v8/src/runtime/runtime-wasm.cc | 249 ++-- deps/v8/src/runtime/runtime.cc | 28 + deps/v8/src/runtime/runtime.h | 23 +- deps/v8/src/snapshot/DEPS | 3 + deps/v8/src/snapshot/code-serializer.cc | 16 +- .../v8/src/snapshot/deserializer-allocator.cc | 28 +- deps/v8/src/snapshot/deserializer.cc | 36 +- deps/v8/src/snapshot/deserializer.h | 2 +- .../platform-embedded-file-writer-generic.cc | 4 +- .../platform-embedded-file-writer-win.cc | 354 ++--- .../platform-embedded-file-writer-win.h | 1 + deps/v8/src/snapshot/object-deserializer.cc | 3 +- deps/v8/src/snapshot/partial-serializer.cc | 3 +- deps/v8/src/snapshot/read-only-serializer.cc | 1 + deps/v8/src/snapshot/serializer-common.cc | 3 +- deps/v8/src/snapshot/serializer.cc | 8 + deps/v8/src/snapshot/snapshot-common.cc | 84 +- deps/v8/src/snapshot/snapshot-compression.cc | 95 ++ deps/v8/src/snapshot/snapshot-compression.h | 27 + deps/v8/src/snapshot/snapshot.h | 16 +- deps/v8/src/snapshot/startup-deserializer.cc | 4 + deps/v8/src/snapshot/startup-serializer.cc | 10 + deps/v8/src/snapshot/startup-serializer.h | 4 + deps/v8/src/strings/string-hasher-inl.h | 32 +- deps/v8/src/torque/ast.h | 6 +- deps/v8/src/torque/cfg.cc | 28 + deps/v8/src/torque/cfg.h | 37 + .../torque/class-debug-reader-generator.cc | 136 +- deps/v8/src/torque/constants.h | 10 +- deps/v8/src/torque/csa-generator.cc | 712 ++++++---- deps/v8/src/torque/csa-generator.h | 47 +- deps/v8/src/torque/declarable.h | 2 +- deps/v8/src/torque/declaration-visitor.cc | 16 +- deps/v8/src/torque/global-context.h | 10 - deps/v8/src/torque/implementation-visitor.cc | 907 +++++++++--- deps/v8/src/torque/implementation-visitor.h | 61 +- deps/v8/src/torque/instance-type-generator.cc | 47 +- deps/v8/src/torque/instructions.cc | 341 +++++ deps/v8/src/torque/instructions.h | 173 ++- deps/v8/src/torque/torque-compiler.cc | 2 +- deps/v8/src/torque/torque-parser.cc | 104 +- deps/v8/src/torque/type-oracle.cc | 28 + deps/v8/src/torque/type-oracle.h | 45 +- deps/v8/src/torque/type-visitor.cc | 155 +- deps/v8/src/torque/types.cc | 135 +- deps/v8/src/torque/types.h | 32 +- deps/v8/src/torque/utils.cc | 2 +- deps/v8/src/torque/utils.h | 39 +- deps/v8/src/utils/vector.h | 12 + .../wasm/baseline/arm/liftoff-assembler-arm.h | 400 +++++- .../baseline/arm64/liftoff-assembler-arm64.h | 312 +++- .../baseline/ia32/liftoff-assembler-ia32.h | 619 ++++++-- .../v8/src/wasm/baseline/liftoff-assembler.cc | 163 ++- deps/v8/src/wasm/baseline/liftoff-assembler.h | 126 +- deps/v8/src/wasm/baseline/liftoff-compiler.cc | 1244 ++++++++++++---- deps/v8/src/wasm/baseline/liftoff-compiler.h | 6 +- deps/v8/src/wasm/baseline/liftoff-register.h | 38 +- .../baseline/mips/liftoff-assembler-mips.h | 421 +++++- .../mips64/liftoff-assembler-mips64.h | 417 +++++- .../wasm/baseline/ppc/liftoff-assembler-ppc.h | 236 +++- .../baseline/s390/liftoff-assembler-s390.h | 236 +++- .../wasm/baseline/x64/liftoff-assembler-x64.h | 676 ++++++++- deps/v8/src/wasm/c-api.cc | 95 +- deps/v8/src/wasm/compilation-environment.h | 11 +- deps/v8/src/wasm/decoder.h | 1 + deps/v8/src/wasm/function-body-decoder-impl.h | 106 +- deps/v8/src/wasm/function-body-decoder.cc | 28 +- deps/v8/src/wasm/function-body-decoder.h | 14 +- deps/v8/src/wasm/function-compiler.cc | 8 +- deps/v8/src/wasm/function-compiler.h | 13 +- deps/v8/src/wasm/graph-builder-interface.cc | 47 +- deps/v8/src/wasm/jump-table-assembler.cc | 28 +- deps/v8/src/wasm/jump-table-assembler.h | 12 +- deps/v8/src/wasm/local-decl-encoder.cc | 2 +- deps/v8/src/wasm/local-decl-encoder.h | 11 +- deps/v8/src/wasm/module-compiler.cc | 588 +++++--- deps/v8/src/wasm/module-compiler.h | 9 +- deps/v8/src/wasm/module-decoder.cc | 399 ++++-- deps/v8/src/wasm/module-decoder.h | 29 +- deps/v8/src/wasm/module-instantiate.cc | 89 +- deps/v8/src/wasm/value-type.h | 459 +++--- deps/v8/src/wasm/wasm-arguments.h | 6 +- deps/v8/src/wasm/wasm-code-manager.cc | 483 ++++--- deps/v8/src/wasm/wasm-code-manager.h | 193 +-- deps/v8/src/wasm/wasm-constants.h | 2 +- deps/v8/src/wasm/wasm-debug-evaluate.cc | 274 ++++ deps/v8/src/wasm/wasm-debug-evaluate.h | 25 + deps/v8/src/wasm/wasm-debug.cc | 514 +++++-- deps/v8/src/wasm/wasm-debug.h | 120 +- deps/v8/src/wasm/wasm-engine.cc | 312 ++-- deps/v8/src/wasm/wasm-engine.h | 123 +- deps/v8/src/wasm/wasm-external-refs.cc | 174 ++- deps/v8/src/wasm/wasm-external-refs.h | 12 +- deps/v8/src/wasm/wasm-import-wrapper-cache.cc | 2 +- deps/v8/src/wasm/wasm-import-wrapper-cache.h | 4 +- deps/v8/src/wasm/wasm-interpreter.cc | 226 +-- deps/v8/src/wasm/wasm-js.cc | 134 +- deps/v8/src/wasm/wasm-limits.h | 17 +- deps/v8/src/wasm/wasm-linkage.h | 2 +- deps/v8/src/wasm/wasm-memory.cc | 633 --------- deps/v8/src/wasm/wasm-module-builder.cc | 23 +- deps/v8/src/wasm/wasm-module-sourcemap.cc | 13 +- deps/v8/src/wasm/wasm-module-sourcemap.h | 6 +- deps/v8/src/wasm/wasm-module.cc | 62 +- deps/v8/src/wasm/wasm-module.h | 59 +- deps/v8/src/wasm/wasm-objects-inl.h | 20 +- deps/v8/src/wasm/wasm-objects.cc | 130 +- deps/v8/src/wasm/wasm-objects.h | 50 +- deps/v8/src/wasm/wasm-objects.tq | 11 +- deps/v8/src/wasm/wasm-opcodes.cc | 114 +- deps/v8/src/wasm/wasm-opcodes.h | 398 +++--- deps/v8/src/wasm/wasm-result.cc | 15 + deps/v8/src/wasm/wasm-result.h | 14 + deps/v8/src/wasm/wasm-serialization.cc | 139 +- deps/v8/src/wasm/wasm-tier.h | 2 +- deps/v8/test/benchmarks/csuite/csuite.py | 2 +- deps/v8/test/cctest/BUILD.gn | 39 +- deps/v8/test/cctest/cctest.h | 72 +- deps/v8/test/cctest/cctest.status | 35 +- .../cctest/compiler/test-code-assembler.cc | 141 +- .../cctest/compiler/test-code-generator.cc | 5 +- .../cctest/compiler/test-multiple-return.cc | 4 +- .../cctest/compiler/test-run-jsobjects.cc | 12 +- .../cctest/compiler/test-run-load-store.cc | 16 +- deps/v8/test/cctest/heap/heap-utils.cc | 4 +- deps/v8/test/cctest/heap/test-alloc.cc | 12 +- .../cctest/heap/test-array-buffer-tracker.cc | 13 +- .../heap/test-external-string-tracker.cc | 6 +- deps/v8/test/cctest/heap/test-heap.cc | 114 +- .../cctest/heap/test-invalidated-slots.cc | 9 +- deps/v8/test/cctest/heap/test-spaces.cc | 4 +- .../bytecode-expectations-printer.cc | 3 +- .../ArrayLiterals.golden | 21 +- .../AssignmentsInBinaryExpression.golden | 24 +- .../AsyncGenerators.golden | 106 +- .../bytecode_expectations/AsyncModules.golden | 346 +++-- .../BasicBlockToBoolean.golden | 9 +- .../bytecode_expectations/BasicLoops.golden | 121 +- .../BreakableBlocks.golden | 26 +- .../CallAndSpread.golden | 9 +- .../bytecode_expectations/CallGlobal.golden | 6 +- .../CallLookupSlot.golden | 5 +- .../bytecode_expectations/CallNew.golden | 9 +- .../bytecode_expectations/CallRuntime.golden | 9 +- .../ClassAndSuperClass.golden | 12 +- .../ClassDeclarations.golden | 23 +- .../bytecode_expectations/CompareNil.golden | 41 +- .../CompareTypeOf.golden | 15 +- .../CompoundExpressions.golden | 17 +- .../bytecode_expectations/Conditional.golden | 12 +- .../ConstVariable.golden | 12 +- .../ConstVariableContextSlot.golden | 20 +- .../ContextParameters.golden | 20 +- .../ContextVariables.golden | 30 +- .../CountOperators.golden | 37 +- .../CreateArguments.golden | 30 +- .../CreateRestParameter.golden | 20 +- .../DeadCodeRemoval.golden | 12 +- .../DeclareGlobals.golden | 20 +- .../bytecode_expectations/Delete.golden | 23 +- .../DeleteLookupSlotInEval.golden | 9 +- .../DestructuringAssignment.golden | 30 +- .../bytecode_expectations/DoDebugger.golden | 3 +- .../bytecode_expectations/Eval.golden | 5 +- .../bytecode_expectations/ForAwaitOf.golden | 68 +- .../bytecode_expectations/ForIn.golden | 57 +- .../bytecode_expectations/ForOf.golden | 46 +- .../bytecode_expectations/ForOfLoop.golden | 122 +- .../FunctionLiterals.golden | 9 +- .../GenerateTestUndetectable.golden | 24 +- .../bytecode_expectations/Generators.golden | 31 +- .../GlobalCompoundExpressions.golden | 6 +- .../GlobalCountOperators.golden | 12 +- .../bytecode_expectations/GlobalDelete.golden | 12 +- .../HeapNumberConstants.golden | 9 +- .../IIFEWithOneshotOpt.golden | 90 +- .../IIFEWithoutOneshotOpt.golden | 20 +- .../bytecode_expectations/IfConditions.golden | 36 +- .../IntegerConstants.golden | 9 +- .../bytecode_expectations/LetVariable.golden | 12 +- .../LetVariableContextSlot.golden | 20 +- .../bytecode_expectations/LoadGlobal.golden | 12 +- .../LogicalExpressions.golden | 39 +- .../bytecode_expectations/LookupSlot.golden | 25 +- .../LookupSlotInEval.golden | 12 +- .../bytecode_expectations/Modules.golden | 443 +++--- .../bytecode_expectations/NewAndSpread.golden | 15 +- .../bytecode_expectations/NewTarget.golden | 6 +- .../ObjectLiterals.golden | 45 +- .../OuterContextVariables.golden | 6 +- .../bytecode_expectations/Parameters.golden | 21 +- .../PrimitiveExpressions.golden | 72 +- .../PrimitiveReturnStatements.golden | 33 +- .../PrivateAccessorAccess.golden | 33 +- .../PrivateAccessorDeclaration.golden | 30 +- .../PrivateClassFields.golden | 10 +- .../PrivateMethodAccess.golden | 24 +- .../PrivateMethodDeclaration.golden | 15 +- .../bytecode_expectations/PropertyCall.golden | 15 +- .../PropertyLoadStoreOneShot.golden | 34 +- .../PropertyLoadStoreWithoutOneShot.golden | 6 +- .../PropertyLoads.golden | 21 +- .../PropertyStores.golden | 33 +- .../PublicClassFields.golden | 10 +- .../RegExpLiterals.golden | 9 +- .../RemoveRedundantLdar.golden | 13 +- .../StandardForLoop.golden | 104 +- .../StaticClassFields.golden | 10 +- .../StaticPrivateMethodAccess.golden | 44 +- .../StaticPrivateMethodDeclaration.golden | 25 +- .../bytecode_expectations/StoreGlobal.golden | 18 +- .../bytecode_expectations/StringConcat.golden | 20 +- .../StringConstants.golden | 9 +- .../SuperCallAndSpread.golden | 15 +- .../bytecode_expectations/Switch.golden | 24 +- .../TemplateLiterals.golden | 20 +- .../bytecode_expectations/ThisFunction.golden | 6 +- .../bytecode_expectations/Throw.golden | 9 +- .../TopLevelObjectLiterals.golden | 5 +- .../bytecode_expectations/TryCatch.golden | 12 +- .../bytecode_expectations/TryFinally.golden | 21 +- .../bytecode_expectations/Typeof.golden | 6 +- .../UnaryOperators.golden | 29 +- .../WideRegisters.golden | 35 +- .../WithStatement.golden | 3 +- .../cctest/interpreter/interpreter-tester.h | 57 +- .../test-interpreter-intrinsics.cc | 18 +- .../cctest/interpreter/test-interpreter.cc | 119 +- .../cctest/parsing/test-scanner-streams.cc | 8 +- deps/v8/test/cctest/test-accessors.cc | 9 +- deps/v8/test/cctest/test-api-array-buffer.cc | 77 +- deps/v8/test/cctest/test-api-stack-traces.cc | 6 +- deps/v8/test/cctest/test-api.cc | 515 +++++-- deps/v8/test/cctest/test-assembler-arm64.cc | 139 +- deps/v8/test/cctest/test-code-pages.cc | 23 +- .../test/cctest/test-code-stub-assembler.cc | 69 +- deps/v8/test/cctest/test-constantpool.cc | 4 +- deps/v8/test/cctest/test-debug-helper.cc | 27 +- deps/v8/test/cctest/test-debug.cc | 656 ++++++++- deps/v8/test/cctest/test-decls.cc | 33 +- deps/v8/test/cctest/test-disasm-arm64.cc | 40 +- deps/v8/test/cctest/test-disasm-ia32.cc | 2 + deps/v8/test/cctest/test-disasm-x64.cc | 67 +- deps/v8/test/cctest/test-factory.cc | 3 +- deps/v8/test/cctest/test-feedback-vector.cc | 33 + .../test/cctest/test-field-type-tracking.cc | 2 +- .../test/cctest/test-func-name-inference.cc | 3 +- deps/v8/test/cctest/test-global-handles.cc | 61 +- deps/v8/test/cctest/test-heap-profiler.cc | 7 +- deps/v8/test/cctest/test-icache.cc | 5 +- deps/v8/test/cctest/test-inspector.cc | 15 - deps/v8/test/cctest/test-js-weak-refs.cc | 356 ++--- deps/v8/test/cctest/test-local-handles.cc | 96 ++ deps/v8/test/cctest/test-log.cc | 12 +- deps/v8/test/cctest/test-modules.cc | 261 ++-- deps/v8/test/cctest/test-object.cc | 23 + deps/v8/test/cctest/test-orderedhashtable.cc | 4 +- deps/v8/test/cctest/test-parsing.cc | 43 +- deps/v8/test/cctest/test-regexp.cc | 47 +- deps/v8/test/cctest/test-roots.cc | 1 - deps/v8/test/cctest/test-sampler-api.cc | 63 - deps/v8/test/cctest/test-serialize.cc | 75 +- deps/v8/test/cctest/test-strings.cc | 33 +- .../test/cctest/test-sync-primitives-arm64.cc | 4 +- deps/v8/test/cctest/test-types.cc | 140 +- .../test/cctest/test-unwinder-code-pages.cc | 74 + deps/v8/test/cctest/test-unwinder.cc | 100 +- deps/v8/test/cctest/test-usecounters.cc | 36 + deps/v8/test/cctest/test-v8windbg.cc | 14 + deps/v8/test/cctest/torque/test-torque.cc | 29 + deps/v8/test/cctest/trace-extension.cc | 18 +- deps/v8/test/cctest/wasm/test-c-wasm-entry.cc | 2 +- .../cctest/wasm/test-compilation-cache.cc | 140 +- deps/v8/test/cctest/wasm/test-grow-memory.cc | 2 +- .../cctest/wasm/test-liftoff-inspection.cc | 284 ++-- deps/v8/test/cctest/wasm/test-run-wasm-64.cc | 10 +- .../cctest/wasm/test-run-wasm-atomics64.cc | 46 + .../cctest/wasm/test-run-wasm-exceptions.cc | 37 +- .../v8/test/cctest/wasm/test-run-wasm-simd.cc | 283 ++-- deps/v8/test/cctest/wasm/test-run-wasm.cc | 29 +- .../cctest/wasm/test-streaming-compilation.cc | 33 + .../test/cctest/wasm/test-wasm-breakpoints.cc | 11 +- .../cctest/wasm/test-wasm-debug-evaluate.cc | 315 +++++ deps/v8/test/cctest/wasm/test-wasm-stack.cc | 58 + deps/v8/test/cctest/wasm/wasm-run-utils.cc | 84 +- deps/v8/test/cctest/wasm/wasm-run-utils.h | 79 +- deps/v8/test/common/types-fuzz.h | 68 +- deps/v8/test/common/wasm/wasm-macro-gen.h | 29 +- .../v8/test/common/wasm/wasm-module-runner.cc | 27 +- ...bled-tier-down-wasm-unsupported-liftoff.js | 42 + .../wasm/debug-enabled-tier-down-wasm.js | 62 + deps/v8/test/debugger/debugger.status | 14 +- deps/v8/test/debugging/debugging.status | 5 + deps/v8/test/debugging/testcfg.py | 99 ++ .../test/debugging/wasm/gdb-server/connect.py | 41 + .../test/debugging/wasm/gdb-server/gdb_rsp.py | 73 + .../wasm/gdb-server/test_files/test.js | 33 + deps/v8/test/fuzzer/multi-return.cc | 4 +- deps/v8/test/fuzzer/regexp-builtins.cc | 3 +- deps/v8/test/fuzzer/wasm-compile.cc | 871 ++++++++---- deps/v8/test/fuzzer/wasm-fuzzer-common.cc | 54 +- deps/v8/test/fuzzer/wasm.cc | 2 + .../console-profile-wasm-expected.txt | 2 +- .../cpu-profiler/console-profile-wasm.js | 47 +- ...s-private-methods-empty-inner-expected.txt | 4 + .../class-private-methods-empty-inner.js | 44 + .../class-private-methods-expected.txt | 4 +- .../class-private-methods-static-expected.txt | 148 ++ ...private-methods-static-nested-expected.txt | 17 + .../class-private-methods-static-nested.js | 61 + ...rivate-methods-static-preview-expected.txt | 28 + .../class-private-methods-static-preview.js | 41 + .../debugger/class-private-methods-static.js | 122 ++ .../class-private-methods-unused-expected.txt | 83 ++ .../debugger/class-private-methods-unused.js | 79 ++ .../debugger/class-private-methods.js | 4 + .../es6-module-script-parsed-expected.txt | 3 + ...ssible-breakpoints-lazy-error-expected.txt | 26 +- .../get-possible-breakpoints-lazy-error.js | 34 +- .../pause-on-oom-extrawide-expected.txt | 2 + .../debugger/pause-on-oom-extrawide.js | 39 + .../debugger/pause-on-oom-wide-expected.txt | 2 + .../inspector/debugger/pause-on-oom-wide.js | 37 + .../resource-name-to-url-expected.txt | 4 + .../script-on-after-compile-expected.txt | 40 + .../debugger/script-origin-stack-expected.txt | 1 + ...t-parsed-for-runtime-evaluate-expected.txt | 12 + .../debugger/script-parsed-hash-expected.txt | 3 + .../debugger/wasm-anyref-global-expected.txt | 2 +- .../debugger/wasm-clone-module-expected.txt | 6 +- .../debugger/wasm-debug-command-expected.txt | 4 +- ...akable-locations-byte-offsets-expected.txt | 70 +- .../debugger/wasm-global-names-expected.txt | 7 + .../inspector/debugger/wasm-global-names.js | 82 ++ .../debugger/wasm-imports-expected.txt | 8 +- .../wasm-inspect-many-registers-expected.txt | 103 ++ .../debugger/wasm-inspect-many-registers.js | 122 ++ .../wasm-remove-breakpoint-expected.txt | 4 +- .../debugger/wasm-scope-info-expected.txt | 230 ++- .../wasm-scope-info-liftoff-expected.txt | 167 ++- .../debugger/wasm-scope-info-liftoff.js | 22 +- .../inspector/debugger/wasm-scope-info.js | 22 +- .../debugger/wasm-scripts-expected.txt | 40 +- .../wasm-scripts-with-name-expected.txt | 8 +- .../test/inspector/debugger/wasm-scripts.js | 10 +- .../debugger/wasm-set-breakpoint-expected.txt | 12 +- .../wasm-set-breakpoint-liftoff-expected.txt | 391 ++++- .../debugger/wasm-set-breakpoint-liftoff.js | 93 +- .../debugger/wasm-stack-expected.txt | 4 +- .../wasm-stepping-byte-offsets-expected.txt | 173 ++- .../debugger/wasm-stepping-byte-offsets.js | 19 +- .../wasm-stepping-in-from-js-expected.txt | 8 +- .../debugger/wasm-stepping-in-from-js.js | 36 +- .../wasm-stepping-liftoff-expected.txt | 69 + .../debugger/wasm-stepping-liftoff.js | 146 ++ .../debugger/wasm-stepping-to-js-expected.txt | 13 +- ...wasm-stepping-with-source-map-expected.txt | 167 ++- .../debugger/wasm-stepping-with-source-map.js | 20 +- .../wasm-unnamed-function-names-expected.txt | 10 + .../debugger/wasm-unnamed-function-names.js | 69 + deps/v8/test/inspector/inspector-test.cc | 3 +- deps/v8/test/inspector/inspector.status | 20 +- deps/v8/test/inspector/isolate-data.cc | 16 +- deps/v8/test/inspector/protocol-test.js | 4 +- .../inspector/runtime/es6-module-expected.txt | 4 + deps/v8/test/inspector/testcfg.py | 3 +- deps/v8/test/intl/regress-10248.js | 70 + deps/v8/test/intl/regress-1030160.js | 5 + deps/v8/test/intl/regress-1041319.js | 46 + deps/v8/test/js-perf-test/Scope/with.js | 25 +- ...essors-private-undefined-getter-nested.out | 4 +- ...essors-private-undefined-setter-nested.out | 4 +- ...s-methods-private-brand-check-anonymous.js | 11 + ...-methods-private-brand-check-anonymous.out | 9 + .../fail/class-methods-private-brand-check.js | 11 + .../class-methods-private-brand-check.out | 9 + deps/v8/test/message/fail/spread-call-2.js | 5 + deps/v8/test/message/fail/spread-call-2.out | 5 + deps/v8/test/message/fail/spread-call-3.js | 6 + deps/v8/test/message/fail/spread-call-3.out | 5 + deps/v8/test/message/fail/spread-call.js | 5 + deps/v8/test/message/fail/spread-call.out | 5 + .../test/message/fail/spread-construct-2.js | 6 + .../test/message/fail/spread-construct-2.out | 5 + .../test/message/fail/spread-construct-3.js | 7 + .../test/message/fail/spread-construct-3.out | 5 + deps/v8/test/message/fail/spread-construct.js | 6 + .../v8/test/message/fail/spread-construct.out | 5 + .../message/fail/wasm-exception-rethrow.out | 2 +- .../message/fail/wasm-exception-throw.out | 2 +- .../test/message/fail/wasm-function-name.out | 2 +- .../fail/wasm-module-and-function-name.out | 2 +- .../v8/test/message/fail/wasm-module-name.out | 2 +- deps/v8/test/message/fail/wasm-no-name.out | 2 +- deps/v8/test/message/fail/wasm-trap.out | 2 +- .../fail/weak-refs-finalizationgroup1.out | 6 - .../fail/weak-refs-finalizationgroup2.out | 6 - ....js => weak-refs-finalizationregistry1.js} | 2 +- .../fail/weak-refs-finalizationregistry1.out | 6 + ....js => weak-refs-finalizationregistry2.js} | 2 +- .../fail/weak-refs-finalizationregistry2.out | 6 + .../test/message/fail/weak-refs-register1.js | 2 +- .../test/message/fail/weak-refs-register1.out | 6 +- .../test/message/fail/weak-refs-register2.js | 2 +- .../test/message/fail/weak-refs-register2.out | 6 +- .../test/message/fail/weak-refs-unregister.js | 2 +- .../message/fail/weak-refs-unregister.out | 2 +- .../test/message/wasm-function-name-async.out | 2 +- .../message/wasm-function-name-streaming.out | 2 +- .../wasm-module-and-function-name-async.out | 2 +- ...asm-module-and-function-name-streaming.out | 2 +- .../test/message/wasm-module-name-async.out | 2 +- .../message/wasm-module-name-streaming.out | 2 +- deps/v8/test/message/wasm-no-name-async.out | 2 +- .../test/message/wasm-no-name-streaming.out | 2 +- .../message/wasm-trace-memory-interpreted.out | 3 + .../message/wasm-trace-memory-liftoff.out | 5 +- deps/v8/test/message/wasm-trace-memory.js | 14 + deps/v8/test/message/wasm-trace-memory.out | 3 + ... => weakref-finalizationregistry-error.js} | 4 +- ...=> weakref-finalizationregistry-error.out} | 1 + deps/v8/test/mjsunit/BUILD.gn | 3 + deps/v8/test/mjsunit/array-reduce.js | 8 +- deps/v8/test/mjsunit/asm/regress-674089.js | 5 +- .../call-intrinsic-differential-fuzzing.js | 8 + .../v8/test/mjsunit/call-intrinsic-fuzzing.js | 26 + .../compiler/inlined-call-polymorphic.js | 24 + .../mjsunit/compiler/osr-block-scope-id.js | 1 + .../test/mjsunit/compiler/regress-1061678.js | 20 + .../test/mjsunit/compiler/regress-1061803.js | 15 + .../test/mjsunit/compiler/regress-1062916.js | 20 + .../test/mjsunit/compiler/regress-1063661.js | 18 + .../test/mjsunit/compiler/regress-1072171.js | 45 + .../es6/unicode-regexp-ignore-case-noi18n.js | 23 +- deps/v8/test/mjsunit/for-in-special-cases.js | 70 +- deps/v8/test/mjsunit/frozen-array-reduce.js | 8 +- .../harmony/async-generators-throw-caught.js | 24 + .../mjsunit/harmony/bigint/property-names.js | 2 + .../harmony/private-methods-empty-inner.js | 30 + .../test/mjsunit/harmony/private-methods.js | 7 +- .../test/mjsunit/harmony/weakrefs/basics.js | 68 +- .../cleanup-doesnt-iterate-all-holdings.js | 4 +- .../weakrefs/cleanup-from-different-realm.js | 4 +- .../weakrefs/cleanup-is-not-a-microtask.js | 2 +- .../weakrefs/cleanup-on-detached-realm.js | 2 +- .../cleanup-proxy-from-different-realm.js | 4 +- .../mjsunit/harmony/weakrefs/cleanupsome-2.js | 2 +- .../weakrefs/cleanupsome-after-unregister.js | 2 +- .../mjsunit/harmony/weakrefs/cleanupsome.js | 2 +- ...ef.js => finalizationregistry-and-weakref} | 4 +- ...nalizationregistry-independent-lifetime.js | 26 + ...alizationregistry-keeps-holdings-alive.js} | 13 +- ...y-scheduled-for-cleanup-multiple-times.js} | 17 +- .../harmony/weakrefs/iterating-in-cleanup.js | 19 +- .../multiple-dirty-finalization-groups.js | 6 +- ...leanup.js => reentrant-gc-from-cleanup.js} | 2 +- .../harmony/weakrefs/undefined-holdings.js | 4 +- .../weakrefs/unregister-after-cleanup.js | 4 +- .../weakrefs/unregister-before-cleanup.js | 4 +- .../weakrefs/unregister-called-twice.js | 4 +- .../weakrefs/unregister-inside-cleanup1.js | 4 +- .../weakrefs/unregister-inside-cleanup2.js | 4 +- .../weakrefs/unregister-inside-cleanup3.js | 4 +- .../weakrefs/unregister-inside-cleanup4.js | 4 +- .../weakrefs/unregister-inside-cleanup5.js | 4 +- .../harmony/weakrefs/unregister-many.js | 4 +- ...register-when-cleanup-already-scheduled.js | 6 +- .../harmony/weakrefs/weak-cell-basics.js | 12 +- .../harmony/weakrefs/weak-unregistertoken.js | 4 +- deps/v8/test/mjsunit/mjsunit.js | 11 +- deps/v8/test/mjsunit/mjsunit.status | 43 +- .../mjsunit/non-extensible-array-reduce.js | 8 +- deps/v8/test/mjsunit/optimized-array-every.js | 6 +- deps/v8/test/mjsunit/optimized-array-find.js | 6 +- .../test/mjsunit/optimized-array-findindex.js | 6 +- deps/v8/test/mjsunit/optimized-array-some.js | 6 +- deps/v8/test/mjsunit/optimized-filter.js | 6 +- deps/v8/test/mjsunit/optimized-foreach.js | 5 + deps/v8/test/mjsunit/optimized-map.js | 6 +- .../prepare-missing-label-syntax-error.js | 8 + deps/v8/test/mjsunit/regexp.js | 12 + .../test/mjsunit/regress/regress-1049982-1.js | 2 +- .../test/mjsunit/regress/regress-1049982-2.js | 2 +- .../mjsunit/{ => regress}/regress-906893.js | 0 .../mjsunit/{ => regress}/regress-918763.js | 0 .../mjsunit/{ => regress}/regress-930045.js | 0 .../mjsunit/{ => regress}/regress-932101.js | 0 .../mjsunit/{ => regress}/regress-952682.js | 0 .../mjsunit/{ => regress}/regress-956426.js | 0 .../mjsunit/{ => regress}/regress-958725.js | 0 .../mjsunit/{ => regress}/regress-963346.js | 0 .../mjsunit/{ => regress}/regress-966460.js | 0 .../{ => regress}/regress-crbug-1025468.js | 0 .../mjsunit/regress/regress-crbug-1047368.js | 14 + .../mjsunit/regress/regress-crbug-1057653.js | 8 + .../mjsunit/regress/regress-crbug-1059738.js | 5 + .../mjsunit/regress/regress-crbug-1072947.js | 31 + .../regress-regexp-functional-replace-slow.js | 0 .../{ => regress}/regress-v8-8445-2.js | 0 .../mjsunit/{ => regress}/regress-v8-8445.js | 0 .../regress/wasm/regress-10126-streaming.js | 7 + .../mjsunit/regress/wasm/regress-10126.js | 32 + .../mjsunit/regress/wasm/regress-10309.js | 64 + .../mjsunit/regress/wasm/regress-1045225.js | 28 + .../mjsunit/regress/wasm/regress-1046472.js | 33 + .../mjsunit/regress/wasm/regress-1048241.js | 19 + .../mjsunit/regress/wasm/regress-1051912.js | 17 + .../mjsunit/regress/wasm/regress-1054466.js | 52 + .../mjsunit/regress/wasm/regress-1055692.js | 35 + .../mjsunit/regress/wasm/regress-724846.js | 2 +- .../mjsunit/regress/wasm/regress-789952.js | 40 - .../regress/wasm/regress-crbug-1057094.js | 14 + deps/v8/test/mjsunit/sealed-array-reduce.js | 7 +- deps/v8/test/mjsunit/tools/foozzie.js | 79 ++ deps/v8/test/mjsunit/tools/foozzie_archs.js | 84 ++ .../test/mjsunit/tools/foozzie_webassembly.js | 18 + deps/v8/test/mjsunit/wasm/anyfunc.js | 2 + deps/v8/test/mjsunit/wasm/anyref-globals.js | 15 +- deps/v8/test/mjsunit/wasm/anyref-table.js | 34 +- deps/v8/test/mjsunit/wasm/asm-wasm-f32.js | 22 +- deps/v8/test/mjsunit/wasm/asm-wasm-f64.js | 22 +- deps/v8/test/mjsunit/wasm/bulk-memory.js | 17 + .../v8/test/mjsunit/wasm/exceptions-anyref.js | 95 ++ deps/v8/test/mjsunit/wasm/exceptions.js | 104 ++ deps/v8/test/mjsunit/wasm/grow-huge-memory.js | 35 + deps/v8/test/mjsunit/wasm/grow-memory.js | 378 ++--- deps/v8/test/mjsunit/wasm/import-memory.js | 2 +- .../v8/test/mjsunit/wasm/interpreter-mixed.js | 10 +- deps/v8/test/mjsunit/wasm/interpreter.js | 48 +- .../test/mjsunit/wasm/liftoff-simd-params.js | 77 + deps/v8/test/mjsunit/wasm/many-modules.js | 2 +- .../test/mjsunit/wasm/memory-external-call.js | 2 +- .../test/mjsunit/wasm/multiple-code-spaces.js | 2 +- deps/v8/test/mjsunit/wasm/stack.js | 12 +- deps/v8/test/mjsunit/wasm/table-access.js | 1 + deps/v8/test/mjsunit/wasm/table-fill.js | 14 +- .../test/mjsunit/wasm/tier-down-to-liftoff.js | 32 +- deps/v8/test/mjsunit/wasm/type-reflection.js | 33 + .../mjsunit/wasm/user-properties-exported.js | 2 +- .../mjsunit/wasm/user-properties-module.js | 2 +- .../mjsunit/wasm/user-properties-reexport.js | 2 +- .../test/mjsunit/wasm/wasm-module-builder.js | 74 +- deps/v8/test/test262/test262.status | 30 +- deps/v8/test/test262/testcfg.py | 2 +- deps/v8/test/torque/test-torque.tq | 110 +- deps/v8/test/unittests/BUILD.gn | 52 +- .../unittests/api/access-check-unittest.cc | 7 +- .../v8/test/unittests/api/isolate-unittest.cc | 3 +- .../unittests/api/remote-object-unittest.cc | 3 +- .../test/unittests/api/v8-object-unittest.cc | 42 +- .../assembler/turbo-assembler-arm-unittest.cc | 10 +- .../turbo-assembler-arm64-unittest.cc | 15 +- .../turbo-assembler-ia32-unittest.cc | 21 +- .../turbo-assembler-mips-unittest.cc | 10 +- .../turbo-assembler-mips64-unittest.cc | 10 +- .../assembler/turbo-assembler-ppc-unittest.cc | 12 +- .../turbo-assembler-s390-unittest.cc | 10 +- .../assembler/turbo-assembler-x64-unittest.cc | 21 +- .../base/platform/platform-unittest.cc | 13 + .../base/region-allocator-unittest.cc | 26 +- .../backend/instruction-selector-unittest.cc | 22 +- .../compiler/bytecode-analysis-unittest.cc | 8 +- .../constant-folding-reducer-unittest.cc | 109 +- .../test/unittests/compiler/graph-unittest.cc | 2 +- .../compiler/int64-lowering-unittest.cc | 12 +- .../compiler/js-typed-lowering-unittest.cc | 3 +- .../machine-operator-reducer-unittest.cc | 70 + .../unittests/compiler/node-cache-unittest.cc | 38 +- .../redundancy-elimination-unittest.cc | 14 +- .../compiler/state-values-utils-unittest.cc | 8 +- .../test/unittests/compiler/typer-unittest.cc | 116 +- .../execution/microtask-queue-unittest.cc | 145 +- .../heap/cppgc/allocation_unittest.cc | 42 + .../heap/cppgc/finalizer-trait_unittest.cc | 118 ++ .../heap/cppgc/garbage-collected_unittest.cc | 26 + .../unittests/heap/cppgc/gc-info_unittest.cc | 153 ++ .../heap/cppgc/heap-object-header_unittest.cc | 181 +++ .../unittests/heap/cppgc/run-all-unittests.cc | 17 + .../unittests/heap/cppgc/stack_unittest.cc | 256 ++++ deps/v8/test/unittests/heap/cppgc/tests.cc | 36 + deps/v8/test/unittests/heap/cppgc/tests.h | 39 + .../heap/gc-idle-time-handler-unittest.cc | 15 - .../unittests/heap/local-heap-unittest.cc | 38 + .../heap/off-thread-factory-unittest.cc | 304 +++- .../test/unittests/heap/safepoint-unittest.cc | 139 ++ .../unittests/heap/scavenge-job-unittest.cc | 114 -- .../test/unittests/heap/worklist-unittest.cc | 15 + .../bytecode-array-builder-unittest.cc | 24 +- .../bytecode-array-iterator-unittest.cc | 20 +- ...bytecode-array-random-iterator-unittest.cc | 146 +- .../bytecode-array-writer-unittest.cc | 118 +- .../constant-array-builder-unittest.cc | 14 +- .../objects/value-serializer-unittest.cc | 9 +- .../profiler/strings-storage-unittest.cc | 49 + deps/v8/test/unittests/test-utils.h | 9 +- .../test/unittests/torque/torque-unittest.cc | 142 ++ .../wasm/function-body-decoder-unittest.cc | 280 ++-- .../unittests/wasm/module-decoder-unittest.cc | 162 ++- .../unittests/wasm/wasm-compiler-unittest.cc | 4 +- deps/v8/test/wasm-js/tests.tar.gz.sha1 | 2 +- deps/v8/test/wasm-js/wasm-js.status | 13 +- .../v8/test/wasm-spec-tests/tests.tar.gz.sha1 | 2 +- .../wasm-spec-tests/wasm-spec-tests.status | 9 - .../third_party/inspector_protocol/BUILD.gn | 21 +- .../third_party/inspector_protocol/README.v8 | 2 +- .../inspector_protocol/code_generator.py | 7 - .../inspector_protocol/crdtp/dispatch.cc | 576 ++++++++ .../inspector_protocol/crdtp/dispatch.h | 311 ++++ .../inspector_protocol/crdtp/dispatch_test.cc | 445 ++++++ .../inspector_protocol/crdtp/error_support.cc | 59 + .../inspector_protocol/crdtp/error_support.h | 62 + .../crdtp/error_support_test.cc | 45 + .../inspector_protocol/crdtp/find_by_first.h | 58 + .../crdtp/find_by_first_test.cc | 76 + .../crdtp/frontend_channel.h | 47 + .../inspector_protocol/crdtp/json.cc | 15 + .../inspector_protocol/crdtp/json.h | 1 + .../inspector_protocol/crdtp/json_test.cc | 26 + .../inspector_protocol/crdtp/serializable.cc | 21 +- .../inspector_protocol/crdtp/serializable.h | 12 +- .../crdtp/serializable_test.cc | 5 +- .../inspector_protocol/crdtp/span.cc | 24 + .../inspector_protocol/crdtp/span.h | 24 +- .../inspector_protocol/crdtp/span_test.cc | 39 - .../inspector_protocol/crdtp/status.cc | 106 +- .../inspector_protocol/crdtp/status.h | 60 +- .../inspector_protocol/inspector_protocol.gni | 11 +- .../lib/DispatcherBase_cpp.template | 355 ----- .../lib/DispatcherBase_h.template | 178 --- .../lib/ErrorSupport_cpp.template | 73 - .../lib/ErrorSupport_h.template | 39 - .../inspector_protocol/lib/Forward_h.template | 12 +- .../lib/FrontendChannel_h.template | 33 - .../lib/Object_cpp.template | 2 +- .../lib/Parser_cpp.template | 548 ------- .../inspector_protocol/lib/Parser_h.template | 24 - .../lib/ValueConversions_h.template | 38 +- .../lib/Values_cpp.template | 305 ++-- .../inspector_protocol/lib/Values_h.template | 2 + .../lib/base_string_adapter_cc.template | 34 +- .../lib/base_string_adapter_h.template | 59 +- .../v8/third_party/inspector_protocol/roll.py | 11 + .../templates/Imported_h.template | 4 +- .../templates/TypeBuilder_cpp.template | 209 +-- .../templates/TypeBuilder_h.template | 12 +- deps/v8/third_party/v8/builtins/array-sort.tq | 2 +- deps/v8/third_party/zlib/BUILD.gn | 5 +- .../zlib/contrib/minizip/iowin32.c | 8 +- deps/v8/third_party/zlib/cpu_features.c | 3 + deps/v8/third_party/zlib/crc32_simd.h | 1 + deps/v8/third_party/zlib/deflate.c | 2 +- .../third_party/zlib/patches/0000-build.patch | 42 +- .../third_party/zlib/patches/0001-simd.patch | 42 +- .../zlib/patches/0003-uninitializedjump.patch | 2 +- .../zlib/patches/0004-fix-uwp.patch | 22 + deps/v8/third_party/zlib/trees.h | 1 + deps/v8/tools/BUILD.gn | 20 +- deps/v8/tools/callstats.html | 59 +- deps/v8/tools/callstats.py | 6 +- deps/v8/tools/clusterfuzz/BUILD.gn | 3 + .../clusterfuzz/testdata/failure_output.txt | 4 +- .../testdata/sanity_check_output.txt | 4 +- deps/v8/tools/clusterfuzz/v8_commands.py | 34 +- deps/v8/tools/clusterfuzz/v8_foozzie.py | 78 +- deps/v8/tools/clusterfuzz/v8_foozzie_test.py | 211 ++- deps/v8/tools/clusterfuzz/v8_fuzz_config.py | 72 +- .../clusterfuzz/v8_fuzz_experiments.json | 17 + deps/v8/tools/clusterfuzz/v8_fuzz_flags.json | 34 + deps/v8/tools/clusterfuzz/v8_mock.js | 118 +- deps/v8/tools/clusterfuzz/v8_mock_archs.js | 59 +- .../tools/clusterfuzz/v8_mock_webassembly.js | 18 + deps/v8/tools/clusterfuzz/v8_suppressions.js | 25 - deps/v8/tools/clusterfuzz/v8_suppressions.py | 106 +- deps/v8/tools/codemap.js | 4 +- deps/v8/tools/debug_helper/BUILD.gn | 22 +- .../debug_helper/debug-helper-internal.cc | 8 +- .../debug_helper/debug-helper-internal.h | 18 +- deps/v8/tools/debug_helper/debug-helper.h | 7 +- .../tools/debug_helper/gen-heap-constants.py | 6 +- .../debug_helper/get-object-properties.cc | 11 +- deps/v8/tools/debug_helper/heap-constants.cc | 8 +- deps/v8/tools/debug_helper/heap-constants.h | 8 +- .../tools/debug_helper/list-object-classes.cc | 2 +- deps/v8/tools/dev/gm.py | 7 +- deps/v8/tools/gdb-v8-support.py | 9 +- deps/v8/tools/gen-postmortem-metadata.py | 1 - deps/v8/tools/generate-runtime-call-stats.py | 36 +- deps/v8/tools/heap-stats/categories.js | 4 +- ...n.html => details-selection-template.html} | 5 - deps/v8/tools/heap-stats/details-selection.js | 19 +- ...ine.html => global-timeline-template.html} | 3 - deps/v8/tools/heap-stats/global-timeline.js | 19 +- deps/v8/tools/heap-stats/helper.js | 7 + ...er.html => histogram-viewer-template.html} | 3 - deps/v8/tools/heap-stats/histogram-viewer.js | 19 +- deps/v8/tools/heap-stats/index.html | 10 +- deps/v8/tools/heap-stats/model.js | 2 +- ...r.html => trace-file-reader-template.html} | 5 - deps/v8/tools/heap-stats/trace-file-reader.js | 140 +- deps/v8/tools/map-processor.html | 21 +- deps/v8/tools/mb/mb.py | 46 +- deps/v8/tools/mb/mb_unittest.py | 9 +- deps/v8/tools/profile.js | 16 +- deps/v8/tools/release/git_recipes.py | 1 - deps/v8/tools/release/test_scripts.py | 8 +- deps/v8/tools/testrunner/base_runner.py | 23 +- .../v8/tools/testrunner/local/junit_output.py | 49 - deps/v8/tools/testrunner/local/pool.py | 8 +- deps/v8/tools/testrunner/local/variants.py | 1 + deps/v8/tools/testrunner/outproc/base.py | 17 +- deps/v8/tools/testrunner/standard_runner.py | 6 + deps/v8/tools/testrunner/test_config.py | 4 +- deps/v8/tools/testrunner/testproc/fuzzer.py | 4 + deps/v8/tools/testrunner/testproc/progress.py | 71 +- deps/v8/tools/tickprocessor-driver.js | 2 +- deps/v8/tools/tickprocessor.js | 25 +- deps/v8/tools/unittests/run_tests_test.py | 18 + deps/v8/tools/v8_presubmit.py | 8 +- deps/v8/tools/v8heapconst.py | 445 +++--- deps/v8/tools/v8windbg/BUILD.gn | 116 ++ deps/v8/tools/v8windbg/README.md | 151 ++ deps/v8/tools/v8windbg/base/dbgext.cc | 75 + deps/v8/tools/v8windbg/base/dbgext.def | 5 + deps/v8/tools/v8windbg/base/dbgext.h | 34 + deps/v8/tools/v8windbg/base/utilities.cc | 246 ++++ deps/v8/tools/v8windbg/base/utilities.h | 85 ++ deps/v8/tools/v8windbg/copy-prereqs.py | 38 + deps/v8/tools/v8windbg/src/cur-isolate.cc | 94 ++ deps/v8/tools/v8windbg/src/cur-isolate.h | 34 + deps/v8/tools/v8windbg/src/list-chunks.cc | 238 ++++ deps/v8/tools/v8windbg/src/list-chunks.h | 100 ++ deps/v8/tools/v8windbg/src/local-variables.cc | 120 ++ deps/v8/tools/v8windbg/src/local-variables.h | 36 + .../tools/v8windbg/src/object-inspection.cc | 622 ++++++++ .../v8/tools/v8windbg/src/object-inspection.h | 261 ++++ .../v8windbg/src/v8-debug-helper-interop.cc | 157 ++ .../v8windbg/src/v8-debug-helper-interop.h | 138 ++ .../tools/v8windbg/src/v8windbg-extension.cc | 340 +++++ .../tools/v8windbg/src/v8windbg-extension.h | 81 ++ .../v8/tools/v8windbg/test/debug-callbacks.cc | 94 ++ deps/v8/tools/v8windbg/test/debug-callbacks.h | 90 ++ deps/v8/tools/v8windbg/test/script.js | 14 + deps/v8/tools/v8windbg/test/v8windbg-test.cc | 243 ++++ deps/v8/tools/v8windbg/test/v8windbg-test.h | 18 + deps/v8/tools/whitespace.txt | 6 +- 1518 files changed, 56777 insertions(+), 26526 deletions(-) create mode 100644 deps/v8/include/cppgc/README.md create mode 100644 deps/v8/include/cppgc/allocation.h create mode 100644 deps/v8/include/cppgc/finalizer-trait.h create mode 100644 deps/v8/include/cppgc/garbage-collected.h create mode 100644 deps/v8/include/cppgc/gc-info.h create mode 100644 deps/v8/include/cppgc/heap.h create mode 100644 deps/v8/include/cppgc/internals.h create mode 100644 deps/v8/include/cppgc/platform.h create mode 100644 deps/v8/include/v8-fast-api-calls.h create mode 100644 deps/v8/src/base/bits-iterator.h delete mode 100644 deps/v8/src/compiler/node-cache.cc create mode 100644 deps/v8/src/debug/wasm/gdb-server/gdb-server-thread.cc create mode 100644 deps/v8/src/debug/wasm/gdb-server/gdb-server-thread.h create mode 100644 deps/v8/src/debug/wasm/gdb-server/gdb-server.cc create mode 100644 deps/v8/src/debug/wasm/gdb-server/gdb-server.h create mode 100644 deps/v8/src/debug/wasm/gdb-server/session.cc create mode 100644 deps/v8/src/debug/wasm/gdb-server/session.h create mode 100644 deps/v8/src/debug/wasm/gdb-server/target.cc create mode 100644 deps/v8/src/debug/wasm/gdb-server/target.h create mode 100644 deps/v8/src/debug/wasm/gdb-server/transport.cc create mode 100644 deps/v8/src/debug/wasm/gdb-server/transport.h create mode 100644 deps/v8/src/debug/wasm/gdb-server/util.h create mode 100644 deps/v8/src/execution/arm64/pointer-authentication-arm64.h create mode 100644 deps/v8/src/execution/off-thread-isolate.cc create mode 100644 deps/v8/src/execution/off-thread-isolate.h create mode 100644 deps/v8/src/execution/pointer-authentication-dummy.h create mode 100644 deps/v8/src/execution/pointer-authentication.h delete mode 100644 deps/v8/src/handles/factory-handles.h create mode 100644 deps/v8/src/handles/local-handles-inl.h create mode 100644 deps/v8/src/handles/local-handles.cc create mode 100644 deps/v8/src/handles/local-handles.h create mode 100644 deps/v8/src/heap/cppgc/allocation.cc create mode 100644 deps/v8/src/heap/cppgc/asm/x64/push_registers.S create mode 100644 deps/v8/src/heap/cppgc/asm/x64/push_registers_win.S create mode 100644 deps/v8/src/heap/cppgc/gc-info-table.cc create mode 100644 deps/v8/src/heap/cppgc/gc-info-table.h create mode 100644 deps/v8/src/heap/cppgc/gc-info.cc create mode 100644 deps/v8/src/heap/cppgc/globals.h create mode 100644 deps/v8/src/heap/cppgc/heap-inl.h create mode 100644 deps/v8/src/heap/cppgc/heap-object-header-inl.h create mode 100644 deps/v8/src/heap/cppgc/heap-object-header.cc create mode 100644 deps/v8/src/heap/cppgc/heap-object-header.h create mode 100644 deps/v8/src/heap/cppgc/heap.cc create mode 100644 deps/v8/src/heap/cppgc/heap.h create mode 100644 deps/v8/src/heap/cppgc/platform.cc create mode 100644 deps/v8/src/heap/cppgc/sanitizers.h create mode 100644 deps/v8/src/heap/cppgc/stack.cc create mode 100644 deps/v8/src/heap/cppgc/stack.h create mode 100644 deps/v8/src/heap/factory-base-inl.h delete mode 100644 deps/v8/src/heap/finalization-group-cleanup-task.h rename deps/v8/src/heap/{finalization-group-cleanup-task.cc => finalization-registry-cleanup-task.cc} (53%) create mode 100644 deps/v8/src/heap/finalization-registry-cleanup-task.h create mode 100644 deps/v8/src/heap/local-heap.cc create mode 100644 deps/v8/src/heap/local-heap.h create mode 100644 deps/v8/src/heap/safepoint.cc create mode 100644 deps/v8/src/heap/safepoint.h create mode 100644 deps/v8/src/logging/off-thread-logger.h create mode 100644 deps/v8/src/objects/tagged-index.h create mode 100644 deps/v8/src/regexp/regexp-error.cc create mode 100644 deps/v8/src/regexp/regexp-error.h create mode 100644 deps/v8/src/snapshot/snapshot-compression.cc create mode 100644 deps/v8/src/snapshot/snapshot-compression.h create mode 100644 deps/v8/src/wasm/wasm-debug-evaluate.cc create mode 100644 deps/v8/src/wasm/wasm-debug-evaluate.h delete mode 100644 deps/v8/src/wasm/wasm-memory.cc create mode 100644 deps/v8/test/cctest/test-local-handles.cc create mode 100644 deps/v8/test/cctest/test-v8windbg.cc create mode 100644 deps/v8/test/cctest/wasm/test-wasm-debug-evaluate.cc create mode 100644 deps/v8/test/debugger/debug/wasm/debug-enabled-tier-down-wasm-unsupported-liftoff.js create mode 100644 deps/v8/test/debugger/debug/wasm/debug-enabled-tier-down-wasm.js create mode 100644 deps/v8/test/debugging/debugging.status create mode 100644 deps/v8/test/debugging/testcfg.py create mode 100644 deps/v8/test/debugging/wasm/gdb-server/connect.py create mode 100644 deps/v8/test/debugging/wasm/gdb-server/gdb_rsp.py create mode 100644 deps/v8/test/debugging/wasm/gdb-server/test_files/test.js create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-empty-inner-expected.txt create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-empty-inner.js create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-static-expected.txt create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-static-nested-expected.txt create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-static-nested.js create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-static-preview-expected.txt create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-static-preview.js create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-static.js create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-unused-expected.txt create mode 100644 deps/v8/test/inspector/debugger/class-private-methods-unused.js create mode 100644 deps/v8/test/inspector/debugger/pause-on-oom-extrawide-expected.txt create mode 100644 deps/v8/test/inspector/debugger/pause-on-oom-extrawide.js create mode 100644 deps/v8/test/inspector/debugger/pause-on-oom-wide-expected.txt create mode 100644 deps/v8/test/inspector/debugger/pause-on-oom-wide.js create mode 100644 deps/v8/test/inspector/debugger/wasm-global-names-expected.txt create mode 100644 deps/v8/test/inspector/debugger/wasm-global-names.js create mode 100644 deps/v8/test/inspector/debugger/wasm-inspect-many-registers-expected.txt create mode 100644 deps/v8/test/inspector/debugger/wasm-inspect-many-registers.js create mode 100644 deps/v8/test/inspector/debugger/wasm-stepping-liftoff-expected.txt create mode 100644 deps/v8/test/inspector/debugger/wasm-stepping-liftoff.js create mode 100644 deps/v8/test/inspector/debugger/wasm-unnamed-function-names-expected.txt create mode 100644 deps/v8/test/inspector/debugger/wasm-unnamed-function-names.js create mode 100644 deps/v8/test/intl/regress-10248.js create mode 100644 deps/v8/test/intl/regress-1030160.js create mode 100644 deps/v8/test/intl/regress-1041319.js create mode 100644 deps/v8/test/message/fail/class-methods-private-brand-check-anonymous.js create mode 100644 deps/v8/test/message/fail/class-methods-private-brand-check-anonymous.out create mode 100644 deps/v8/test/message/fail/class-methods-private-brand-check.js create mode 100644 deps/v8/test/message/fail/class-methods-private-brand-check.out create mode 100644 deps/v8/test/message/fail/spread-call-2.js create mode 100644 deps/v8/test/message/fail/spread-call-2.out create mode 100644 deps/v8/test/message/fail/spread-call-3.js create mode 100644 deps/v8/test/message/fail/spread-call-3.out create mode 100644 deps/v8/test/message/fail/spread-call.js create mode 100644 deps/v8/test/message/fail/spread-call.out create mode 100644 deps/v8/test/message/fail/spread-construct-2.js create mode 100644 deps/v8/test/message/fail/spread-construct-2.out create mode 100644 deps/v8/test/message/fail/spread-construct-3.js create mode 100644 deps/v8/test/message/fail/spread-construct-3.out create mode 100644 deps/v8/test/message/fail/spread-construct.js create mode 100644 deps/v8/test/message/fail/spread-construct.out delete mode 100644 deps/v8/test/message/fail/weak-refs-finalizationgroup1.out delete mode 100644 deps/v8/test/message/fail/weak-refs-finalizationgroup2.out rename deps/v8/test/message/fail/{weak-refs-finalizationgroup1.js => weak-refs-finalizationregistry1.js} (84%) create mode 100644 deps/v8/test/message/fail/weak-refs-finalizationregistry1.out rename deps/v8/test/message/fail/{weak-refs-finalizationgroup2.js => weak-refs-finalizationregistry2.js} (83%) create mode 100644 deps/v8/test/message/fail/weak-refs-finalizationregistry2.out rename deps/v8/test/message/{weakref-finalizationgroup-error.js => weakref-finalizationregistry-error.js} (85%) rename deps/v8/test/message/{weakref-finalizationgroup-error.out => weakref-finalizationregistry-error.out} (99%) create mode 100644 deps/v8/test/mjsunit/call-intrinsic-differential-fuzzing.js create mode 100644 deps/v8/test/mjsunit/call-intrinsic-fuzzing.js create mode 100644 deps/v8/test/mjsunit/compiler/inlined-call-polymorphic.js create mode 100644 deps/v8/test/mjsunit/compiler/regress-1061678.js create mode 100644 deps/v8/test/mjsunit/compiler/regress-1061803.js create mode 100644 deps/v8/test/mjsunit/compiler/regress-1062916.js create mode 100644 deps/v8/test/mjsunit/compiler/regress-1063661.js create mode 100644 deps/v8/test/mjsunit/compiler/regress-1072171.js create mode 100644 deps/v8/test/mjsunit/harmony/async-generators-throw-caught.js create mode 100644 deps/v8/test/mjsunit/harmony/private-methods-empty-inner.js rename deps/v8/test/mjsunit/harmony/weakrefs/{finalizationgroup-and-weakref.js => finalizationregistry-and-weakref} (89%) create mode 100644 deps/v8/test/mjsunit/harmony/weakrefs/finalizationregistry-independent-lifetime.js rename deps/v8/test/mjsunit/harmony/weakrefs/{finalization-group-keeps-holdings-alive.js => finalizationregistry-keeps-holdings-alive.js} (67%) rename deps/v8/test/mjsunit/harmony/weakrefs/{finalizationgroup-scheduled-for-cleanup-multiple-times.js => finalizationregistry-scheduled-for-cleanup-multiple-times.js} (83%) rename deps/v8/test/mjsunit/harmony/weakrefs/{reentrant-task-abort-from-cleanup.js => reentrant-gc-from-cleanup.js} (90%) create mode 100644 deps/v8/test/mjsunit/prepare-missing-label-syntax-error.js rename deps/v8/test/mjsunit/{ => regress}/regress-906893.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-918763.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-930045.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-932101.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-952682.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-956426.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-958725.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-963346.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-966460.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-crbug-1025468.js (100%) create mode 100644 deps/v8/test/mjsunit/regress/regress-crbug-1047368.js create mode 100644 deps/v8/test/mjsunit/regress/regress-crbug-1057653.js create mode 100644 deps/v8/test/mjsunit/regress/regress-crbug-1059738.js create mode 100644 deps/v8/test/mjsunit/regress/regress-crbug-1072947.js rename deps/v8/test/mjsunit/{ => regress}/regress-regexp-functional-replace-slow.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-v8-8445-2.js (100%) rename deps/v8/test/mjsunit/{ => regress}/regress-v8-8445.js (100%) create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-10126-streaming.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-10126.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-10309.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-1045225.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-1046472.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-1048241.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-1051912.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-1054466.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-1055692.js delete mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-789952.js create mode 100644 deps/v8/test/mjsunit/regress/wasm/regress-crbug-1057094.js create mode 100644 deps/v8/test/mjsunit/tools/foozzie.js create mode 100644 deps/v8/test/mjsunit/tools/foozzie_archs.js create mode 100644 deps/v8/test/mjsunit/tools/foozzie_webassembly.js create mode 100644 deps/v8/test/mjsunit/wasm/grow-huge-memory.js create mode 100644 deps/v8/test/mjsunit/wasm/liftoff-simd-params.js create mode 100644 deps/v8/test/unittests/heap/cppgc/allocation_unittest.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/finalizer-trait_unittest.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/garbage-collected_unittest.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/gc-info_unittest.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/heap-object-header_unittest.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/run-all-unittests.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/stack_unittest.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/tests.cc create mode 100644 deps/v8/test/unittests/heap/cppgc/tests.h create mode 100644 deps/v8/test/unittests/heap/local-heap-unittest.cc create mode 100644 deps/v8/test/unittests/heap/safepoint-unittest.cc delete mode 100644 deps/v8/test/unittests/heap/scavenge-job-unittest.cc create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/dispatch.cc create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/dispatch.h create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/dispatch_test.cc create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/error_support.cc create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/error_support.h create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/error_support_test.cc create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/find_by_first.h create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/find_by_first_test.cc create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/frontend_channel.h create mode 100644 deps/v8/third_party/inspector_protocol/crdtp/span.cc delete mode 100644 deps/v8/third_party/inspector_protocol/lib/DispatcherBase_cpp.template delete mode 100644 deps/v8/third_party/inspector_protocol/lib/DispatcherBase_h.template delete mode 100644 deps/v8/third_party/inspector_protocol/lib/ErrorSupport_cpp.template delete mode 100644 deps/v8/third_party/inspector_protocol/lib/ErrorSupport_h.template delete mode 100644 deps/v8/third_party/inspector_protocol/lib/FrontendChannel_h.template delete mode 100644 deps/v8/third_party/inspector_protocol/lib/Parser_cpp.template delete mode 100644 deps/v8/third_party/inspector_protocol/lib/Parser_h.template create mode 100644 deps/v8/third_party/zlib/patches/0004-fix-uwp.patch create mode 100644 deps/v8/tools/clusterfuzz/v8_fuzz_experiments.json create mode 100644 deps/v8/tools/clusterfuzz/v8_fuzz_flags.json create mode 100644 deps/v8/tools/clusterfuzz/v8_mock_webassembly.js rename deps/v8/tools/heap-stats/{details-selection.html => details-selection-template.html} (93%) rename deps/v8/tools/heap-stats/{global-timeline.html => global-timeline-template.html} (73%) rename deps/v8/tools/heap-stats/{histogram-viewer.html => histogram-viewer-template.html} (75%) rename deps/v8/tools/heap-stats/{trace-file-reader.html => trace-file-reader-template.html} (90%) delete mode 100644 deps/v8/tools/testrunner/local/junit_output.py create mode 100644 deps/v8/tools/v8windbg/BUILD.gn create mode 100644 deps/v8/tools/v8windbg/README.md create mode 100644 deps/v8/tools/v8windbg/base/dbgext.cc create mode 100644 deps/v8/tools/v8windbg/base/dbgext.def create mode 100644 deps/v8/tools/v8windbg/base/dbgext.h create mode 100644 deps/v8/tools/v8windbg/base/utilities.cc create mode 100644 deps/v8/tools/v8windbg/base/utilities.h create mode 100644 deps/v8/tools/v8windbg/copy-prereqs.py create mode 100644 deps/v8/tools/v8windbg/src/cur-isolate.cc create mode 100644 deps/v8/tools/v8windbg/src/cur-isolate.h create mode 100644 deps/v8/tools/v8windbg/src/list-chunks.cc create mode 100644 deps/v8/tools/v8windbg/src/list-chunks.h create mode 100644 deps/v8/tools/v8windbg/src/local-variables.cc create mode 100644 deps/v8/tools/v8windbg/src/local-variables.h create mode 100644 deps/v8/tools/v8windbg/src/object-inspection.cc create mode 100644 deps/v8/tools/v8windbg/src/object-inspection.h create mode 100644 deps/v8/tools/v8windbg/src/v8-debug-helper-interop.cc create mode 100644 deps/v8/tools/v8windbg/src/v8-debug-helper-interop.h create mode 100644 deps/v8/tools/v8windbg/src/v8windbg-extension.cc create mode 100644 deps/v8/tools/v8windbg/src/v8windbg-extension.h create mode 100644 deps/v8/tools/v8windbg/test/debug-callbacks.cc create mode 100644 deps/v8/tools/v8windbg/test/debug-callbacks.h create mode 100644 deps/v8/tools/v8windbg/test/script.js create mode 100644 deps/v8/tools/v8windbg/test/v8windbg-test.cc create mode 100644 deps/v8/tools/v8windbg/test/v8windbg-test.h diff --git a/deps/v8/.git-blame-ignore-revs b/deps/v8/.git-blame-ignore-revs index 5ae39770316425..4c53e208e3acec 100644 --- a/deps/v8/.git-blame-ignore-revs +++ b/deps/v8/.git-blame-ignore-revs @@ -23,3 +23,6 @@ e50b49a0e38b34e2b28e026f4d1c7e0da0c7bb1a # Rewrite code base to use "." instead of "->" to access Object members. 878ccb33bd3cf0e6dc018ff8d15843f585ac07be + +# Move test/mjsunit/regress-*.js => test/mjsunit/regress/ +cb67be1a3842fcf6a0da18aee444e3b7ea789e04 diff --git a/deps/v8/AUTHORS b/deps/v8/AUTHORS index 819d147096c496..7036ecd42bc461 100644 --- a/deps/v8/AUTHORS +++ b/deps/v8/AUTHORS @@ -77,11 +77,13 @@ Daniel Andersson Daniel Bevenius Daniel James David Carlier +David Manouchehri Deepak Mohan Deon Dior Dominic Farolini Douglas Crosher Dusan Milosavljevic +Eric Rannaud Erich Ocean Evan Lucas Fedor Indutny @@ -97,12 +99,14 @@ Henrique Ferreiro Hirofumi Mako Honggyu Kim Huáng Jùnliàng +Iain Ireland Ingvar Stepanyan Ioseb Dzmanashvili Isiah Meadows Jaime Bernardo Jan de Mooij Jan Krems +Janusz Majnert Jay Freeman James Pike James M Snell @@ -151,6 +155,7 @@ Oliver Dunk Paolo Giarrusso Patrick Gansterer Peng Fei +Peng-Yu Chen Peter Rybin Peter Varga Peter Wong @@ -195,6 +200,7 @@ Vladimir Krivosheev Vladimir Shutoff Wenlu Wang Wiktor Garbacz +Wouter Vermeiren Xiaoyin Liu Yannic Bonenberger Yong Wang diff --git a/deps/v8/BUILD.gn b/deps/v8/BUILD.gn index 13bf2b0fc344b4..b2dde3f9d70312 100644 --- a/deps/v8/BUILD.gn +++ b/deps/v8/BUILD.gn @@ -107,7 +107,7 @@ declare_args() { # Enable pointer compression (sets -dV8_COMPRESS_POINTERS). v8_enable_pointer_compression = "" - v8_enable_31bit_smis_on_64bit_arch = true + v8_enable_31bit_smis_on_64bit_arch = false # Sets -dOBJECT_PRINT. v8_enable_object_print = "" @@ -128,7 +128,7 @@ declare_args() { v8_enable_concurrent_marking = true # Sets -dV8_ARRAY_BUFFER_EXTENSION - v8_enable_array_buffer_extension = false + v8_enable_array_buffer_extension = true # Enables various testing features. v8_enable_test_features = "" @@ -211,6 +211,13 @@ declare_args() { # Enable additional targets necessary for verification of torque # file generation v8_verify_torque_generation_invariance = false + + # Disable all snapshot compression. + v8_enable_snapshot_compression = true + + # Enable control-flow integrity features, such as pointer authentication for + # ARM64. + v8_control_flow_integrity = false } # Derived defaults. @@ -270,6 +277,9 @@ assert(!v8_disable_write_barriers || v8_enable_single_generation, assert(v8_current_cpu != "x86" || !v8_untrusted_code_mitigations, "Untrusted code mitigations are unsupported on ia32") +assert(v8_current_cpu == "arm64" || !v8_control_flow_integrity, + "Control-flow integrity is only supported on arm64") + assert( !v8_enable_pointer_compression || !v8_enable_shared_ro_heap, "Pointer compression is not supported with shared read-only heap enabled") @@ -298,6 +308,7 @@ config("internal_config") { "//build/config/compiler:wexit_time_destructors", ":internal_config_base", ":v8_header_features", + ":v8_tracing_config", ] if (is_component_build) { @@ -305,6 +316,17 @@ config("internal_config") { } } +# Should be applied to all targets that write trace events. +config("v8_tracing_config") { + if (v8_use_perfetto) { + include_dirs = [ + "third_party/perfetto/include", + "$root_gen_dir/third_party/perfetto", + "$root_gen_dir/third_party/perfetto/build_config", + ] + } +} + # This config should be applied to code using the libplatform. config("libplatform_config") { include_dirs = [ "include" ] @@ -501,6 +523,15 @@ config("features") { if (v8_enable_regexp_interpreter_threaded_dispatch) { defines += [ "V8_ENABLE_REGEXP_INTERPRETER_THREADED_DISPATCH" ] } + if (v8_enable_snapshot_compression) { + defines += [ "V8_SNAPSHOT_COMPRESSION" ] + } + if (v8_control_flow_integrity) { + defines += [ "V8_ENABLE_CONTROL_FLOW_INTEGRITY" ] + } + if (v8_enable_wasm_gdb_remote_debugging) { + defines += [ "V8_ENABLE_WASM_GDB_REMOTE_DEBUGGING" ] + } } config("toolchain") { @@ -543,6 +574,12 @@ config("toolchain") { } if (v8_current_cpu == "arm64") { defines += [ "V8_TARGET_ARCH_ARM64" ] + if (v8_control_flow_integrity) { + # TODO(v8:10026): Enable this in src/build. + if (current_cpu == "arm64") { + cflags += [ "-mbranch-protection=standard" ] + } + } } # Mips64el/mipsel simulators. @@ -618,6 +655,7 @@ config("toolchain") { } if (v8_current_cpu == "s390" || v8_current_cpu == "s390x") { defines += [ "V8_TARGET_ARCH_S390" ] + cflags += [ "-ffp-contract=off" ] if (v8_current_cpu == "s390x") { defines += [ "V8_TARGET_ARCH_S390X" ] } @@ -628,8 +666,9 @@ config("toolchain") { } } if (v8_current_cpu == "ppc" || v8_current_cpu == "ppc64") { - defines += [ "V8_TARGET_ARCH_PPC" ] - if (v8_current_cpu == "ppc64") { + if (v8_current_cpu == "ppc") { + defines += [ "V8_TARGET_ARCH_PPC" ] + } else if (v8_current_cpu == "ppc64") { defines += [ "V8_TARGET_ARCH_PPC64" ] } if (host_byteorder == "little") { @@ -1138,11 +1177,14 @@ template("run_torque") { "bit-fields-tq.h", "builtin-definitions-tq.h", "interface-descriptors-tq.inc", + "factory-tq.cc", + "factory-tq.inc", "field-offsets-tq.h", "class-verifiers-tq.cc", "class-verifiers-tq.h", "enum-verifiers-tq.cc", "objects-printer-tq.cc", + "objects-body-descriptors-tq-inl.h", "class-definitions-tq.cc", "class-definitions-tq-inl.h", "class-definitions-tq.h", @@ -1264,6 +1306,7 @@ v8_source_set("torque_generated_definitions") { "$target_gen_dir/torque-generated/class-definitions-tq.cc", "$target_gen_dir/torque-generated/class-verifiers-tq.cc", "$target_gen_dir/torque-generated/class-verifiers-tq.h", + "$target_gen_dir/torque-generated/factory-tq.cc", "$target_gen_dir/torque-generated/objects-printer-tq.cc", ] @@ -1631,11 +1674,16 @@ v8_source_set("v8_initializers") { ### gcmole(arch:mips64el) ### "src/builtins/mips64/builtins-mips64.cc", ] - } else if (v8_current_cpu == "ppc" || v8_current_cpu == "ppc64") { + } else if (v8_current_cpu == "ppc") { sources += [ ### gcmole(arch:ppc) ### "src/builtins/ppc/builtins-ppc.cc", ] + } else if (v8_current_cpu == "ppc64") { + sources += [ + ### gcmole(arch:ppc64) ### + "src/builtins/ppc/builtins-ppc.cc", + ] } else if (v8_current_cpu == "s390" || v8_current_cpu == "s390x") { sources += [ ### gcmole(arch:s390) ### @@ -1684,6 +1732,7 @@ v8_header_set("v8_headers") { public_configs = [ ":v8_header_features" ] sources = [ + "include/v8-fast-api-calls.h", "include/v8-internal.h", "include/v8.h", "include/v8config.h", @@ -1865,7 +1914,6 @@ v8_compiler_sources = [ "src/compiler/memory-optimizer.cc", "src/compiler/memory-optimizer.h", "src/compiler/node-aux-data.h", - "src/compiler/node-cache.cc", "src/compiler/node-cache.h", "src/compiler/node-marker.cc", "src/compiler/node-marker.h", @@ -2005,6 +2053,7 @@ v8_source_set("v8_base_without_compiler") { ### gcmole(all) ### "$target_gen_dir/builtins-generated/bytecodes-builtins-list.h", + "include/v8-fast-api-calls.h", "include/v8-inspector-protocol.h", "include/v8-inspector.h", "include/v8-internal.h", @@ -2235,6 +2284,9 @@ v8_source_set("v8_base_without_compiler") { "src/execution/messages.h", "src/execution/microtask-queue.cc", "src/execution/microtask-queue.h", + "src/execution/off-thread-isolate.cc", + "src/execution/off-thread-isolate.h", + "src/execution/pointer-authentication.h", "src/execution/protectors-inl.h", "src/execution/protectors.cc", "src/execution/protectors.h", @@ -2273,6 +2325,9 @@ v8_source_set("v8_base_without_compiler") { "src/handles/handles-inl.h", "src/handles/handles.cc", "src/handles/handles.h", + "src/handles/local-handles-inl.h", + "src/handles/local-handles.cc", + "src/handles/local-handles.h", "src/handles/maybe-handles-inl.h", "src/handles/maybe-handles.h", "src/heap/array-buffer-collector.cc", @@ -2298,8 +2353,8 @@ v8_source_set("v8_base_without_compiler") { "src/heap/factory-inl.h", "src/heap/factory.cc", "src/heap/factory.h", - "src/heap/finalization-group-cleanup-task.cc", - "src/heap/finalization-group-cleanup-task.h", + "src/heap/finalization-registry-cleanup-task.cc", + "src/heap/finalization-registry-cleanup-task.h", "src/heap/gc-idle-time-handler.cc", "src/heap/gc-idle-time-handler.h", "src/heap/gc-tracer.cc", @@ -2323,6 +2378,8 @@ v8_source_set("v8_base_without_compiler") { "src/heap/item-parallel-job.h", "src/heap/local-allocator-inl.h", "src/heap/local-allocator.h", + "src/heap/local-heap.cc", + "src/heap/local-heap.h", "src/heap/mark-compact-inl.h", "src/heap/mark-compact.cc", "src/heap/mark-compact.h", @@ -2348,6 +2405,8 @@ v8_source_set("v8_base_without_compiler") { "src/heap/read-only-heap.cc", "src/heap/read-only-heap.h", "src/heap/remembered-set.h", + "src/heap/safepoint.cc", + "src/heap/safepoint.h", "src/heap/scavenge-job.cc", "src/heap/scavenge-job.h", "src/heap/scavenger-inl.h", @@ -2448,6 +2507,7 @@ v8_source_set("v8_base_without_compiler") { "src/logging/log-utils.h", "src/logging/log.cc", "src/logging/log.h", + "src/logging/off-thread-logger.h", "src/numbers/bignum-dtoa.cc", "src/numbers/bignum-dtoa.h", "src/numbers/bignum.cc", @@ -2690,6 +2750,7 @@ v8_source_set("v8_base_without_compiler") { "src/objects/tagged-impl-inl.h", "src/objects/tagged-impl.cc", "src/objects/tagged-impl.h", + "src/objects/tagged-index.h", "src/objects/tagged-value-inl.h", "src/objects/tagged-value.h", "src/objects/template-objects-inl.h", @@ -2775,6 +2836,8 @@ v8_source_set("v8_base_without_compiler") { "src/regexp/regexp-compiler.h", "src/regexp/regexp-dotprinter.cc", "src/regexp/regexp-dotprinter.h", + "src/regexp/regexp-error.cc", + "src/regexp/regexp-error.h", "src/regexp/regexp-interpreter.cc", "src/regexp/regexp-interpreter.h", "src/regexp/regexp-macro-assembler-arch.h", @@ -2860,6 +2923,8 @@ v8_source_set("v8_base_without_compiler") { "src/snapshot/serializer.cc", "src/snapshot/serializer.h", "src/snapshot/snapshot-common.cc", + "src/snapshot/snapshot-compression.cc", + "src/snapshot/snapshot-compression.h", "src/snapshot/snapshot-source-sink.cc", "src/snapshot/snapshot-source-sink.h", "src/snapshot/snapshot.h", @@ -2966,6 +3031,8 @@ v8_source_set("v8_base_without_compiler") { "src/wasm/wasm-code-manager.cc", "src/wasm/wasm-code-manager.h", "src/wasm/wasm-constants.h", + "src/wasm/wasm-debug-evaluate.cc", + "src/wasm/wasm-debug-evaluate.h", "src/wasm/wasm-debug.cc", "src/wasm/wasm-engine.cc", "src/wasm/wasm-engine.h", @@ -3012,10 +3079,30 @@ v8_source_set("v8_base_without_compiler") { "src/zone/zone.h", ] + if (!v8_control_flow_integrity) { + sources += [ "src/execution/pointer-authentication-dummy.h" ] + } + if (v8_enable_third_party_heap) { sources += v8_third_party_heap_files } + if (v8_enable_wasm_gdb_remote_debugging) { + sources += [ + "src/debug/wasm/gdb-server/gdb-server-thread.cc", + "src/debug/wasm/gdb-server/gdb-server-thread.h", + "src/debug/wasm/gdb-server/gdb-server.cc", + "src/debug/wasm/gdb-server/gdb-server.h", + "src/debug/wasm/gdb-server/session.cc", + "src/debug/wasm/gdb-server/session.h", + "src/debug/wasm/gdb-server/target.cc", + "src/debug/wasm/gdb-server/target.h", + "src/debug/wasm/gdb-server/transport.cc", + "src/debug/wasm/gdb-server/transport.h", + "src/debug/wasm/gdb-server/util.h", + ] + } + if (v8_check_header_includes) { # This file will be generated by tools/generate-header-include-checks.py # if the "check_v8_header_includes" gclient variable is set. @@ -3169,6 +3256,9 @@ v8_source_set("v8_base_without_compiler") { "src/regexp/arm64/regexp-macro-assembler-arm64.h", "src/wasm/baseline/arm64/liftoff-assembler-arm64.h", ] + if (v8_control_flow_integrity) { + sources += [ "src/execution/arm64/pointer-authentication-arm64.h" ] + } if (is_win) { sources += [ "src/diagnostics/unwinding-info-win64.cc", @@ -3229,7 +3319,7 @@ v8_source_set("v8_base_without_compiler") { "src/regexp/mips64/regexp-macro-assembler-mips64.h", "src/wasm/baseline/mips64/liftoff-assembler-mips64.h", ] - } else if (v8_current_cpu == "ppc" || v8_current_cpu == "ppc64") { + } else if (v8_current_cpu == "ppc") { sources += [ ### gcmole(arch:ppc) ### "src/codegen/ppc/assembler-ppc-inl.h", "src/codegen/ppc/assembler-ppc.cc", @@ -3259,6 +3349,36 @@ v8_source_set("v8_base_without_compiler") { "src/regexp/ppc/regexp-macro-assembler-ppc.h", "src/wasm/baseline/ppc/liftoff-assembler-ppc.h", ] + } else if (v8_current_cpu == "ppc64") { + sources += [ ### gcmole(arch:ppc64) ### + "src/codegen/ppc/assembler-ppc-inl.h", + "src/codegen/ppc/assembler-ppc.cc", + "src/codegen/ppc/assembler-ppc.h", + "src/codegen/ppc/constants-ppc.cc", + "src/codegen/ppc/constants-ppc.h", + "src/codegen/ppc/cpu-ppc.cc", + "src/codegen/ppc/interface-descriptors-ppc.cc", + "src/codegen/ppc/macro-assembler-ppc.cc", + "src/codegen/ppc/macro-assembler-ppc.h", + "src/codegen/ppc/register-ppc.h", + "src/compiler/backend/ppc/code-generator-ppc.cc", + "src/compiler/backend/ppc/instruction-codes-ppc.h", + "src/compiler/backend/ppc/instruction-scheduler-ppc.cc", + "src/compiler/backend/ppc/instruction-selector-ppc.cc", + "src/compiler/backend/ppc/unwinding-info-writer-ppc.cc", + "src/compiler/backend/ppc/unwinding-info-writer-ppc.h", + "src/debug/ppc/debug-ppc.cc", + "src/deoptimizer/ppc/deoptimizer-ppc.cc", + "src/diagnostics/ppc/disasm-ppc.cc", + "src/diagnostics/ppc/eh-frame-ppc.cc", + "src/execution/ppc/frame-constants-ppc.cc", + "src/execution/ppc/frame-constants-ppc.h", + "src/execution/ppc/simulator-ppc.cc", + "src/execution/ppc/simulator-ppc.h", + "src/regexp/ppc/regexp-macro-assembler-ppc.cc", + "src/regexp/ppc/regexp-macro-assembler-ppc.h", + "src/wasm/baseline/ppc/liftoff-assembler-ppc.h", + ] } else if (v8_current_cpu == "s390" || v8_current_cpu == "s390x") { sources += [ ### gcmole(arch:s390) ### "src/codegen/s390/assembler-s390-inl.h", @@ -3359,7 +3479,10 @@ v8_source_set("v8_base_without_compiler") { ] } - deps += [ "//third_party/zlib" ] + deps += [ + "//third_party/zlib", + "//third_party/zlib/google:compression_utils_portable", + ] if (v8_postmortem_support) { sources += [ "$target_gen_dir/debug-support.cc" ] @@ -3521,6 +3644,7 @@ v8_component("v8_libbase") { "src/base/atomicops_internals_std.h", "src/base/base-export.h", "src/base/bit-field.h", + "src/base/bits-iterator.h", "src/base/bits.cc", "src/base/bits.h", "src/base/bounded-page-allocator.cc", @@ -3799,6 +3923,47 @@ v8_source_set("fuzzer_support") { ] } +v8_source_set("cppgc_base") { + visibility = [ ":*" ] + + sources = [ + "include/cppgc/allocation.h", + "include/cppgc/api-constants.h", + "include/cppgc/finalizer-trait.h", + "include/cppgc/garbage-collected.h", + "include/cppgc/gc-info.h", + "include/cppgc/heap.h", + "include/cppgc/platform.h", + "include/v8config.h", + "src/heap/cppgc/allocation.cc", + "src/heap/cppgc/gc-info-table.cc", + "src/heap/cppgc/gc-info-table.h", + "src/heap/cppgc/gc-info.cc", + "src/heap/cppgc/heap-inl.h", + "src/heap/cppgc/heap-object-header-inl.h", + "src/heap/cppgc/heap-object-header.cc", + "src/heap/cppgc/heap-object-header.h", + "src/heap/cppgc/heap.cc", + "src/heap/cppgc/heap.h", + "src/heap/cppgc/platform.cc", + "src/heap/cppgc/sanitizers.h", + "src/heap/cppgc/stack.cc", + "src/heap/cppgc/stack.h", + ] + + if (target_cpu == "x64") { + if (is_win) { + sources += [ "src/heap/cppgc/asm/x64/push_registers_win.S" ] + } else { + sources += [ "src/heap/cppgc/asm/x64/push_registers.S" ] + } + } + + configs = [ ":internal_config" ] + + public_deps = [ ":v8_libbase" ] +} + ############################################################################### # Produce a single static library for embedders # @@ -3845,6 +4010,12 @@ v8_static_library("wee8") { ] } +v8_static_library("cppgc") { + deps = [ ":cppgc_base" ] + + configs = [ ":internal_config" ] +} + ############################################################################### # Executables # @@ -4076,7 +4247,7 @@ group("v8_archive") { if (is_fuchsia && !build_with_chromium) { import("//build/config/fuchsia/rules.gni") - fuchsia_package("d8_fuchsia_pkg") { + cr_fuchsia_package("d8_fuchsia_pkg") { testonly = true binary = ":d8" package_name_override = "d8" @@ -4136,6 +4307,15 @@ if (is_component_build) { public_configs = [ ":external_config" ] } + + v8_component("cppgc_for_testing") { + testonly = true + + public_deps = [ ":cppgc_base" ] + + configs = [ ":internal_config" ] + public_configs = [ ":external_config" ] + } } else { group("v8") { public_deps = [ @@ -4159,6 +4339,14 @@ if (is_component_build) { public_configs = [ ":external_config" ] } + + group("cppgc_for_testing") { + testonly = true + + public_deps = [ ":cppgc_base" ] + + public_configs = [ ":external_config" ] + } } v8_executable("d8") { @@ -4179,6 +4367,7 @@ v8_executable("d8") { # the :external_config applied to it by virtue of depending on :v8, and # you can't have both applied to the same target. ":internal_config_base", + ":v8_tracing_config", ] deps = [ @@ -4205,7 +4394,7 @@ v8_executable("d8") { } if (v8_use_perfetto) { - deps += [ "//third_party/perfetto/include/perfetto/tracing" ] + deps += [ "//third_party/perfetto/src/tracing:in_process_backend" ] } } diff --git a/deps/v8/COMMON_OWNERS b/deps/v8/COMMON_OWNERS index cf53fe80e0bad7..1eee48173a1576 100644 --- a/deps/v8/COMMON_OWNERS +++ b/deps/v8/COMMON_OWNERS @@ -29,9 +29,11 @@ petermarshall@chromium.org rmcilroy@chromium.org sigurds@chromium.org solanes@chromium.org +syg@chromium.org szuend@chromium.org tebbi@chromium.org -titzer@chromium.org ulan@chromium.org verwaest@chromium.org +victorgomes@chromium.org yangguo@chromium.org +zhin@chromium.org diff --git a/deps/v8/DEPS b/deps/v8/DEPS index 880ff6c4b82d59..1bc687beaf6ead 100644 --- a/deps/v8/DEPS +++ b/deps/v8/DEPS @@ -4,13 +4,9 @@ gclient_gn_args_file = 'v8/build/config/gclient_args.gni' gclient_gn_args = [ - 'checkout_aemu' ] vars = { - # By Default, do not checkout AEMU, as it is too big, as is done in Chromium. - 'checkout_aemu': False, - # Fetches only the SDK boot images which match at least one of the whitelist # entries in a comma-separated list. # @@ -35,10 +31,10 @@ vars = { 'check_v8_header_includes': False, # GN CIPD package version. - 'gn_version': 'git_revision:97cc440d84f050f99ff0161f9414bfa2ffa38f65', + 'gn_version': 'git_revision:5ed3c9cc67b090d5e311e4bd2aba072173e82db9', # luci-go CIPD package version. - 'luci_go': 'git_revision:37a855b64d59b7f079c9a0e5368f2757099d14d3', + 'luci_go': 'git_revision:de73cf6c4bde86f0a9c8d54151b69b0154a398f1', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling android_sdk_build-tools_version @@ -69,10 +65,6 @@ vars = { # and whatever else without interference from each other. 'android_sdk_sources_version': '4gxhM8E62bvZpQs7Q3d0DinQaW0RLCIefhXrQBFkNy8C', # Three lines of non-changing comments so that - # the commit queue can handle CLs rolling android_sdk_tools_version - # and whatever else without interference from each other. - 'android_sdk_tools_version': 'wYcRQC2WHsw2dKWs4EA7fw9Qsyzu1ds1_fRjKmGxe5QC', - # Three lines of non-changing comments so that # the commit queue can handle CLs rolling android_sdk_tools-lint_version # and whatever else without interference from each other. 'android_sdk_tools-lint_version': '89hXqZYzCum3delB5RV7J_QyWkaRodqdtQS0s3LMh3wC', @@ -80,15 +72,15 @@ vars = { deps = { 'v8/build': - Var('chromium_url') + '/chromium/src/build.git' + '@' + '2f17606c25956e800b6c4670c294a03620e78551', + Var('chromium_url') + '/chromium/src/build.git' + '@' + '26e9d485d01d6e0eb9dadd21df767a63494c8fea', 'v8/third_party/depot_tools': - Var('chromium_url') + '/chromium/tools/depot_tools.git' + '@' + 'ea8b58b970c0c94b4a36270b806ee307547cd77e', + Var('chromium_url') + '/chromium/tools/depot_tools.git' + '@' + '2b2aec6506a810f8d7bd018609de2c2450b3c121', 'v8/third_party/icu': - Var('chromium_url') + '/chromium/deps/icu.git' + '@' + 'dbd3825b31041d782c5b504c59dcfb5ac7dda08c', + Var('chromium_url') + '/chromium/deps/icu.git' + '@' + 'd7aff76cf6bb0fbef3afa6c07718f78a80a70f8f', 'v8/third_party/instrumented_libraries': Var('chromium_url') + '/chromium/src/third_party/instrumented_libraries.git' + '@' + 'bb3f1802c237dd19105dd0f7919f99e536a39d10', 'v8/buildtools': - Var('chromium_url') + '/chromium/src/buildtools.git' + '@' + 'afc5b798c72905e85f9991152be878714c579958', + Var('chromium_url') + '/chromium/src/buildtools.git' + '@' + '7977eb176752aeec29d888cfe8e677ac12ed1c41', 'v8/buildtools/clang_format/script': Var('chromium_url') + '/chromium/llvm-project/cfe/tools/clang-format.git' + '@' + '96636aa0e9f047f17447f2d45a094d0b59ed7917', 'v8/buildtools/linux64': { @@ -112,11 +104,11 @@ deps = { 'condition': 'host_os == "mac"', }, 'v8/buildtools/third_party/libc++/trunk': - Var('chromium_url') + '/chromium/llvm-project/libcxx.git' + '@' + '78d6a7767ed57b50122a161b91f59f19c9bd0d19', + Var('chromium_url') + '/external/github.com/llvm/llvm-project/libcxx.git' + '@' + 'd9040c75cfea5928c804ab7c235fed06a63f743a', 'v8/buildtools/third_party/libc++abi/trunk': - Var('chromium_url') + '/chromium/llvm-project/libcxxabi.git' + '@' + '0d529660e32d77d9111912d73f2c74fc5fa2a858', + Var('chromium_url') + '/external/github.com/llvm/llvm-project/libcxxabi.git' + '@' + '196ba1aaa8ac285d94f4ea8d9836390a45360533', 'v8/buildtools/third_party/libunwind/trunk': - Var('chromium_url') + '/external/llvm.org/libunwind.git' + '@' + '69d9b84cca8354117b9fe9705a4430d789ee599b', + Var('chromium_url') + '/external/github.com/llvm/llvm-project/libunwind.git' + '@' + '43bb9f872232f531bac80093ceb4de61c64b9ab7', 'v8/buildtools/win': { 'packages': [ { @@ -128,7 +120,7 @@ deps = { 'condition': 'host_os == "win"', }, 'v8/base/trace_event/common': - Var('chromium_url') + '/chromium/src/base/trace_event/common.git' + '@' + 'bd79231eb1f9e7de2efb4ad79e530d9a7e70d9a5', + Var('chromium_url') + '/chromium/src/base/trace_event/common.git' + '@' + 'dab187b372fc17e51f5b9fad8201813d0aed5129', 'v8/third_party/android_ndk': { 'url': Var('chromium_url') + '/android_ndk.git' + '@' + '27c0a8d090c666a50e40fceb4ee5b40b1a2d3f87', 'condition': 'checkout_android', @@ -167,10 +159,6 @@ deps = { 'package': 'chromium/third_party/android_sdk/public/sources/android-29', 'version': Var('android_sdk_sources_version'), }, - { - 'package': 'chromium/third_party/android_sdk/public/tools', - 'version': Var('android_sdk_tools_version'), - }, { 'package': 'chromium/third_party/android_sdk/public/tools-lint', 'version': Var('android_sdk_tools-lint_version'), @@ -180,7 +168,7 @@ deps = { 'dep_type': 'cipd', }, 'v8/third_party/catapult': { - 'url': Var('chromium_url') + '/catapult.git' + '@' + '2e0a0cb9ad546be8c835e65d7537507cb7896e03', + 'url': Var('chromium_url') + '/catapult.git' + '@' + '032c78376792ef343ea361bca2181ba6dec6b95f', 'condition': 'checkout_android', }, 'v8/third_party/colorama/src': { @@ -188,23 +176,23 @@ deps = { 'condition': 'checkout_android', }, 'v8/third_party/fuchsia-sdk': { - 'url': Var('chromium_url') + '/chromium/src/third_party/fuchsia-sdk.git' + '@' + '19c8ac5e150fbd147ec5987425a41aa9e97098b2', + 'url': Var('chromium_url') + '/chromium/src/third_party/fuchsia-sdk.git' + '@' + '2457e41d8dc379f74662d3157e76339ba92cee06', 'condition': 'checkout_fuchsia', }, 'v8/third_party/googletest/src': - Var('chromium_url') + '/external/github.com/google/googletest.git' + '@' + '306f3754a71d6d1ac644681d3544d06744914228', + Var('chromium_url') + '/external/github.com/google/googletest.git' + '@' + '10b1902d893ea8cc43c69541d70868f91af3646b', 'v8/third_party/jinja2': Var('chromium_url') + '/chromium/src/third_party/jinja2.git' + '@' + 'b41863e42637544c2941b574c7877d3e1f663e25', 'v8/third_party/markupsafe': Var('chromium_url') + '/chromium/src/third_party/markupsafe.git' + '@' + '8f45f5cfa0009d2a70589bcda0349b8cb2b72783', 'v8/tools/swarming_client': - Var('chromium_url') + '/infra/luci/client-py.git' + '@' + '885b3febcc170a60f25795304e60927b77d1e92d', + Var('chromium_url') + '/infra/luci/client-py.git' + '@' + 'cc958279ffd6853e0a1b227a7e957ca334fe56af', 'v8/test/benchmarks/data': Var('chromium_url') + '/v8/deps/third_party/benchmarks.git' + '@' + '05d7188267b4560491ff9155c5ee13e207ecd65f', 'v8/test/mozilla/data': Var('chromium_url') + '/v8/deps/third_party/mozilla-tests.git' + '@' + 'f6c578a10ea707b1a8ab0b88943fe5115ce2b9be', 'v8/test/test262/data': - Var('chromium_url') + '/external/github.com/tc39/test262.git' + '@' + '28b4fcca4b1b1d278dfe0cc0e69c7d9d59b31aab', + Var('chromium_url') + '/external/github.com/tc39/test262.git' + '@' + 'f6b2ccdd091ff82da54150796297c3a96d7edb41', 'v8/test/test262/harness': Var('chromium_url') + '/external/github.com/test262-utils/test262-harness-py.git' + '@' + '4555345a943d0c99a9461182705543fb171dda4b', 'v8/third_party/qemu-linux-x64': { @@ -227,8 +215,28 @@ deps = { 'condition': 'host_os == "mac" and checkout_fuchsia', 'dep_type': 'cipd', }, + 'v8/third_party/aemu-linux-x64': { + 'packages': [ + { + 'package': 'fuchsia/third_party/aemu/linux-amd64', + 'version': '7YlCgase5GlIanqHn-nZClSlZ5kQETJyVUYRF7Jjy6UC' + }, + ], + 'condition': 'host_os == "linux" and checkout_fuchsia', + 'dep_type': 'cipd', + }, + 'v8/third_party/aemu-mac-x64': { + 'packages': [ + { + 'package': 'fuchsia/third_party/aemu/mac-amd64', + 'version': 'T9bWxf8aUC5TwCFgPxpuW29Mfy-7Z9xCfXB9QO8MfU0C' + }, + ], + 'condition': 'host_os == "mac" and checkout_fuchsia', + 'dep_type': 'cipd', + }, 'v8/tools/clang': - Var('chromium_url') + '/chromium/src/tools/clang.git' + '@' + '535dbf16a84c7fc238f7ed11b5a75381407e38f6', + Var('chromium_url') + '/chromium/src/tools/clang.git' + '@' + '105a8460911176861a422738eee4daad8dfe88a2', 'v8/tools/luci-go': { 'packages': [ { @@ -258,11 +266,11 @@ deps = { 'dep_type': 'cipd', }, 'v8/third_party/perfetto': - Var('android_url') + '/platform/external/perfetto.git' + '@' + '12dc10e0278cded35205cf84f80a821348cb6c56', + Var('android_url') + '/platform/external/perfetto.git' + '@' + 'b9b24d1b0b80aafec393af085067e9eae829412f', 'v8/third_party/protobuf': Var('chromium_url') + '/external/github.com/google/protobuf'+ '@' + 'b68a347f56137b4b1a746e8c7438495a6ac1bd91', 'v8/third_party/zlib': - Var('chromium_url') + '/chromium/src/third_party/zlib.git'+ '@' + 'b9b9a5af7cca2e683e5f2aead8418e5bf9d5a7d5', + Var('chromium_url') + '/chromium/src/third_party/zlib.git'+ '@' + '156be8c52f80cde343088b4a69a80579101b6e67', 'v8/third_party/ittapi': { # Force checkout ittapi libraries to pass v8 header includes check on # bots that has check_v8_header_includes enabled. diff --git a/deps/v8/base/trace_event/common/trace_event_common.h b/deps/v8/base/trace_event/common/trace_event_common.h index 3f741d816f722d..a7bffbdbeb44c7 100644 --- a/deps/v8/base/trace_event/common/trace_event_common.h +++ b/deps/v8/base/trace_event/common/trace_event_common.h @@ -61,28 +61,30 @@ // current process id, thread id, and a timestamp in microseconds. // // To trace an asynchronous procedure such as an IPC send/receive, use -// ASYNC_BEGIN and ASYNC_END: +// NESTABLE_ASYNC_BEGIN and NESTABLE_ASYNC_END: // [single threaded sender code] // static int send_count = 0; // ++send_count; -// TRACE_EVENT_ASYNC_BEGIN0("ipc", "message", send_count); +// TRACE_EVENT_NESTABLE_ASYNC_BEGIN0( +// "ipc", "message", TRACE_ID_LOCAL(send_count)); // Send(new MyMessage(send_count)); // [receive code] // void OnMyMessage(send_count) { -// TRACE_EVENT_ASYNC_END0("ipc", "message", send_count); +// TRACE_NESTABLE_EVENT_ASYNC_END0( +// "ipc", "message", TRACE_ID_LOCAL(send_count)); // } -// The third parameter is a unique ID to match ASYNC_BEGIN/ASYNC_END pairs. -// ASYNC_BEGIN and ASYNC_END can occur on any thread of any traced process. -// Pointers can be used for the ID parameter, and they will be annotated -// internally so that the same pointer on two different processes will not -// match. For example: +// The third parameter is a unique ID to match NESTABLE_ASYNC_BEGIN/ASYNC_END +// pairs. NESTABLE_ASYNC_BEGIN and ASYNC_END can occur on any thread of any +// traced process. // Pointers can be used for the ID parameter, and they will +// be annotated internally so that the same pointer on two different processes +// will not match. For example: // class MyTracedClass { // public: // MyTracedClass() { -// TRACE_EVENT_ASYNC_BEGIN0("category", "MyTracedClass", this); +// TRACE_EVENT_NESTABLE_ASYNC_BEGIN0("category", "MyTracedClass", this); // } // ~MyTracedClass() { -// TRACE_EVENT_ASYNC_END0("category", "MyTracedClass", this); +// TRACE_EVENT_NESTABLE_ASYNC_END0("category", "MyTracedClass", this); // } // } // @@ -512,9 +514,11 @@ name, id, TRACE_EVENT_FLAG_NONE, arg1_name, \ arg1_val) -// ASYNC_STEP_* APIs should be only used by legacy code. New code should -// consider using NESTABLE_ASYNC_* APIs to describe substeps within an async -// event. +// -- TRACE_EVENT_ASYNC is DEPRECATED! -- +// +// TRACE_EVENT_ASYNC_* APIs should be only used by legacy code. New code should +// use TRACE_EVENT_NESTABLE_ASYNC_* APIs instead. +// // Records a single ASYNC_BEGIN event called "name" immediately, with 0, 1 or 2 // associated arguments. If the category is not enabled, then this // does nothing. @@ -566,9 +570,6 @@ INTERNAL_TRACE_EVENT_ADD_WITH_ID( \ TRACE_EVENT_PHASE_ASYNC_BEGIN, category_group, name, id, \ TRACE_EVENT_FLAG_COPY, arg1_name, arg1_val, arg2_name, arg2_val) -#define TRACE_EVENT_ASYNC_BEGIN_WITH_FLAGS0(category_group, name, id, flags) \ - INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_ASYNC_BEGIN, \ - category_group, name, id, flags) // Similar to TRACE_EVENT_ASYNC_BEGINx but with a custom |at| timestamp // provided. @@ -595,11 +596,6 @@ INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ TRACE_EVENT_PHASE_ASYNC_BEGIN, category_group, name, id, \ TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, TRACE_EVENT_FLAG_COPY) -#define TRACE_EVENT_ASYNC_BEGIN_WITH_TIMESTAMP_AND_FLAGS0( \ - category_group, name, id, timestamp, flags) \ - INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ - TRACE_EVENT_PHASE_ASYNC_BEGIN, category_group, name, id, \ - TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, flags) // Records a single ASYNC_STEP_INTO event for |step| immediately. If the // category is not enabled, then this does nothing. The |name| and |id| must @@ -671,9 +667,6 @@ INTERNAL_TRACE_EVENT_ADD_WITH_ID( \ TRACE_EVENT_PHASE_ASYNC_END, category_group, name, id, \ TRACE_EVENT_FLAG_COPY, arg1_name, arg1_val, arg2_name, arg2_val) -#define TRACE_EVENT_ASYNC_END_WITH_FLAGS0(category_group, name, id, flags) \ - INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_ASYNC_END, \ - category_group, name, id, flags) // Similar to TRACE_EVENT_ASYNC_ENDx but with a custom |at| timestamp provided. #define TRACE_EVENT_ASYNC_END_WITH_TIMESTAMP0(category_group, name, id, \ @@ -699,11 +692,6 @@ INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ TRACE_EVENT_PHASE_ASYNC_END, category_group, name, id, \ TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, TRACE_EVENT_FLAG_COPY) -#define TRACE_EVENT_ASYNC_END_WITH_TIMESTAMP_AND_FLAGS0(category_group, name, \ - id, timestamp, flags) \ - INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ - TRACE_EVENT_PHASE_ASYNC_END, category_group, name, id, \ - TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, flags) // NESTABLE_ASYNC_* APIs are used to describe an async operation, which can // be nested within a NESTABLE_ASYNC event and/or have inner NESTABLE_ASYNC @@ -742,6 +730,10 @@ INTERNAL_TRACE_EVENT_ADD_WITH_ID( \ TRACE_EVENT_PHASE_NESTABLE_ASYNC_BEGIN, category_group, name, id, \ TRACE_EVENT_FLAG_NONE, arg1_name, arg1_val, arg2_name, arg2_val) +#define TRACE_EVENT_NESTABLE_ASYNC_BEGIN_WITH_FLAGS0(category_group, name, id, \ + flags) \ + INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_NESTABLE_ASYNC_BEGIN, \ + category_group, name, id, flags) // Records a single NESTABLE_ASYNC_END event called "name" immediately, with 0 // or 2 associated arguments. If the category is not enabled, then this does // nothing. @@ -761,6 +753,10 @@ INTERNAL_TRACE_EVENT_ADD_WITH_ID( \ TRACE_EVENT_PHASE_NESTABLE_ASYNC_END, category_group, name, id, \ TRACE_EVENT_FLAG_NONE, arg1_name, arg1_val, arg2_name, arg2_val) +#define TRACE_EVENT_NESTABLE_ASYNC_END_WITH_FLAGS0(category_group, name, id, \ + flags) \ + INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_NESTABLE_ASYNC_END, \ + category_group, name, id, flags) // Records a single NESTABLE_ASYNC_INSTANT event called "name" immediately, // with none, one or two associated argument. If the category is not enabled, @@ -808,6 +804,11 @@ TRACE_EVENT_PHASE_NESTABLE_ASYNC_BEGIN, category_group, name, id, \ TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, TRACE_EVENT_FLAG_NONE, \ arg1_name, arg1_val) +#define TRACE_EVENT_NESTABLE_ASYNC_BEGIN_WITH_TIMESTAMP_AND_FLAGS0( \ + category_group, name, id, timestamp, flags) \ + INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ + TRACE_EVENT_PHASE_NESTABLE_ASYNC_BEGIN, category_group, name, id, \ + TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, flags) #define TRACE_EVENT_NESTABLE_ASYNC_END_WITH_TIMESTAMP0(category_group, name, \ id, timestamp) \ INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ @@ -826,6 +827,11 @@ TRACE_EVENT_PHASE_NESTABLE_ASYNC_END, category_group, name, id, \ TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, TRACE_EVENT_FLAG_NONE, \ arg1_name, arg1_val, arg2_name, arg2_val) +#define TRACE_EVENT_NESTABLE_ASYNC_END_WITH_TIMESTAMP_AND_FLAGS0( \ + category_group, name, id, timestamp, flags) \ + INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ + TRACE_EVENT_PHASE_NESTABLE_ASYNC_END, category_group, name, id, \ + TRACE_EVENT_API_CURRENT_THREAD_ID, timestamp, flags) #define TRACE_EVENT_NESTABLE_ASYNC_INSTANT_WITH_TIMESTAMP0( \ category_group, name, id, timestamp) \ INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \ diff --git a/deps/v8/gni/proto_library.gni b/deps/v8/gni/proto_library.gni index b16d8f93bd8fcd..eca3ffb84e55ac 100644 --- a/deps/v8/gni/proto_library.gni +++ b/deps/v8/gni/proto_library.gni @@ -124,9 +124,13 @@ template("proto_library") { rebase_path(proto_in_dir, root_build_dir), ] if (generate_cc) { + cc_generator_options_ = "" + if (defined(invoker.cc_generator_options)) { + cc_generator_options_ = invoker.cc_generator_options + } args += [ "--cpp_out", - rel_cc_out_dir, + cc_generator_options_ + rel_cc_out_dir, ] } if (generate_descriptor != "") { @@ -153,13 +157,9 @@ template("proto_library") { args += rebase_path(proto_sources, root_build_dir) - inputs = [ - protoc_path, - ] + inputs = [ protoc_path ] - deps = [ - protoc_label, - ] + deps = [ protoc_label ] if (generate_with_plugin) { inputs += [ plugin_path ] if (defined(plugin_host_label)) { @@ -201,21 +201,23 @@ template("proto_library") { public_configs = [] } - public_configs += [ - "//:protobuf_gen_config", - ":$config_name", - ] + public_configs += [ "//:protobuf_gen_config" ] + + propagate_imports_configs = !defined(invoker.propagate_imports_configs) || + invoker.propagate_imports_configs + if (propagate_imports_configs) { + public_configs += [ ":$config_name" ] + } else { + # Embedder handles include directory propagation to dependents. + configs += [ ":$config_name" ] + } # Use protobuf_full only for tests. if (defined(invoker.use_protobuf_full) && invoker.use_protobuf_full == true) { - deps = [ - "//:protobuf_full", - ] + deps = [ "//:protobuf_full" ] } else { - deps = [ - "//:protobuf_lite", - ] + deps = [ "//:protobuf_lite" ] } deps += [ ":$action_name" ] diff --git a/deps/v8/gni/v8.gni b/deps/v8/gni/v8.gni index eaf76a471b3395..0b2806ca949b77 100644 --- a/deps/v8/gni/v8.gni +++ b/deps/v8/gni/v8.gni @@ -57,6 +57,12 @@ declare_args() { # Use Perfetto (https://perfetto.dev) as the default TracingController. Not # currently implemented. v8_use_perfetto = false + + # Override global symbol level setting for v8 + v8_symbol_level = symbol_level + + # Enable WebAssembly debugging via GDB-remote protocol. + v8_enable_wasm_gdb_remote_debugging = false } if (v8_use_external_startup_data == "") { @@ -109,6 +115,13 @@ if (is_debug && !v8_optimized_debug) { } } +if (!is_debug) { + v8_remove_configs += [ + # Too much performance impact, unclear security benefit. + "//build/config/compiler:default_init_stack_vars", + ] +} + if (v8_code_coverage && !is_clang) { v8_add_configs += [ v8_path_prefix + ":v8_gcov_coverage_cflags", @@ -116,6 +129,19 @@ if (v8_code_coverage && !is_clang) { ] } +if (v8_symbol_level != symbol_level) { + v8_remove_configs += [ "//build/config/compiler:default_symbols" ] + if (v8_symbol_level == 0) { + v8_add_configs += [ "//build/config/compiler:no_symbols" ] + } else if (v8_symbol_level == 1) { + v8_add_configs += [ "//build/config/compiler:minimal_symbols" ] + } else if (v8_symbol_level == 2) { + v8_add_configs += [ "//build/config/compiler:symbols" ] + } else { + assert(false) + } +} + if ((is_posix || is_fuchsia) && (v8_enable_backtrace || v8_monolithic || v8_expose_symbols)) { v8_remove_configs += [ "//build/config/gcc:symbol_visibility_hidden" ] @@ -217,6 +243,25 @@ template("v8_component") { } } +template("v8_shared_library") { + shared_library(target_name) { + forward_variables_from(invoker, + "*", + [ + "configs", + "remove_configs", + ]) + configs -= v8_remove_configs + configs += v8_add_configs + if (defined(invoker.remove_configs)) { + configs -= invoker.remove_configs + } + if (defined(invoker.configs)) { + configs += invoker.configs + } + } +} + template("v8_static_library") { static_library(target_name) { complete_static_lib = true diff --git a/deps/v8/include/OWNERS b/deps/v8/include/OWNERS index 1e0794df7a2796..4f90a5c8c70692 100644 --- a/deps/v8/include/OWNERS +++ b/deps/v8/include/OWNERS @@ -1,5 +1,6 @@ adamk@chromium.org danno@chromium.org +mlippautz@chromium.org ulan@chromium.org verwaest@chromium.org yangguo@chromium.org diff --git a/deps/v8/include/cppgc/README.md b/deps/v8/include/cppgc/README.md new file mode 100644 index 00000000000000..3a2db6dfa97ece --- /dev/null +++ b/deps/v8/include/cppgc/README.md @@ -0,0 +1,5 @@ +# C++ Garbage Collection + +This directory provides an open-source garbage collection library for C++. + +The library is under construction, meaning that *all APIs in this directory are incomplete and considered unstable and should not be used*. \ No newline at end of file diff --git a/deps/v8/include/cppgc/allocation.h b/deps/v8/include/cppgc/allocation.h new file mode 100644 index 00000000000000..3e717ad7d428f8 --- /dev/null +++ b/deps/v8/include/cppgc/allocation.h @@ -0,0 +1,91 @@ +// Copyright 2020 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. + +#ifndef INCLUDE_CPPGC_ALLOCATION_H_ +#define INCLUDE_CPPGC_ALLOCATION_H_ + +#include +#include + +#include "include/cppgc/garbage-collected.h" +#include "include/cppgc/gc-info.h" +#include "include/cppgc/heap.h" +#include "include/cppgc/internals.h" + +namespace cppgc { + +template +class MakeGarbageCollectedTraitBase; + +namespace internal { + +class V8_EXPORT MakeGarbageCollectedTraitInternal { + protected: + static inline void MarkObjectAsFullyConstructed(const void* payload) { + // See api_constants for an explanation of the constants. + std::atomic* atomic_mutable_bitfield = + reinterpret_cast*>( + const_cast(reinterpret_cast( + reinterpret_cast(payload) - + api_constants::kFullyConstructedBitFieldOffsetFromPayload))); + uint16_t value = atomic_mutable_bitfield->load(std::memory_order_relaxed); + value = value | api_constants::kFullyConstructedBitMask; + atomic_mutable_bitfield->store(value, std::memory_order_release); + } + + static void* Allocate(cppgc::Heap* heap, size_t size, GCInfoIndex index); + + friend class HeapObjectHeader; +}; + +} // namespace internal + +// Users with custom allocation needs (e.g. overriding size) should override +// MakeGarbageCollectedTrait (see below) and inherit their trait from +// MakeGarbageCollectedTraitBase to get access to low-level primitives. +template +class MakeGarbageCollectedTraitBase + : private internal::MakeGarbageCollectedTraitInternal { + protected: + // Allocates an object of |size| bytes on |heap|. + // + // TODO(mlippautz): Allow specifying arena for specific embedder uses. + static void* Allocate(Heap* heap, size_t size) { + return internal::MakeGarbageCollectedTraitInternal::Allocate( + heap, size, internal::GCInfoTrait::Index()); + } + + // Marks an object as being fully constructed, resulting in precise handling + // by the garbage collector. + static void MarkObjectAsFullyConstructed(const void* payload) { + // internal::MarkObjectAsFullyConstructed(payload); + internal::MakeGarbageCollectedTraitInternal::MarkObjectAsFullyConstructed( + payload); + } +}; + +template +class MakeGarbageCollectedTrait : public MakeGarbageCollectedTraitBase { + public: + template + static T* Call(Heap* heap, Args&&... args) { + static_assert(internal::IsGarbageCollectedType::value, + "T needs to be a garbage collected object"); + void* memory = MakeGarbageCollectedTraitBase::Allocate(heap, sizeof(T)); + T* object = ::new (memory) T(std::forward(args)...); + MakeGarbageCollectedTraitBase::MarkObjectAsFullyConstructed(object); + return object; + } +}; + +// Default MakeGarbageCollected: Constructs an instance of T, which is a garbage +// collected type. +template +T* MakeGarbageCollected(Heap* heap, Args&&... args) { + return MakeGarbageCollectedTrait::Call(heap, std::forward(args)...); +} + +} // namespace cppgc + +#endif // INCLUDE_CPPGC_ALLOCATION_H_ diff --git a/deps/v8/include/cppgc/finalizer-trait.h b/deps/v8/include/cppgc/finalizer-trait.h new file mode 100644 index 00000000000000..12216ed84ed9f6 --- /dev/null +++ b/deps/v8/include/cppgc/finalizer-trait.h @@ -0,0 +1,90 @@ +// Copyright 2020 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. + +#ifndef INCLUDE_CPPGC_FINALIZER_TRAIT_H_ +#define INCLUDE_CPPGC_FINALIZER_TRAIT_H_ + +#include + +#include "include/cppgc/internals.h" + +namespace cppgc { +namespace internal { + +using FinalizationCallback = void (*)(void*); + +template +struct HasFinalizeGarbageCollectedObject : std::false_type {}; + +template +struct HasFinalizeGarbageCollectedObject< + T, void_t().FinalizeGarbageCollectedObject())>> + : std::true_type {}; + +// The FinalizerTraitImpl specifies how to finalize objects. +template +struct FinalizerTraitImpl; + +template +struct FinalizerTraitImpl { + private: + // Dispatch to custom FinalizeGarbageCollectedObject(). + struct Custom { + static void Call(void* obj) { + static_cast(obj)->FinalizeGarbageCollectedObject(); + } + }; + + // Dispatch to regular destructor. + struct Destructor { + static void Call(void* obj) { static_cast(obj)->~T(); } + }; + + using FinalizeImpl = + std::conditional_t::value, Custom, + Destructor>; + + public: + static void Finalize(void* obj) { + static_assert(sizeof(T), "T must be fully defined"); + FinalizeImpl::Call(obj); + } +}; + +template +struct FinalizerTraitImpl { + static void Finalize(void* obj) { + static_assert(sizeof(T), "T must be fully defined"); + } +}; + +// The FinalizerTrait is used to determine if a type requires finalization and +// what finalization means. +template +struct FinalizerTrait { + private: + // Object has a finalizer if it has + // - a custom FinalizeGarbageCollectedObject method, or + // - a destructor. + static constexpr bool kNonTrivialFinalizer = + internal::HasFinalizeGarbageCollectedObject::value || + !std::is_trivially_destructible::type>::value; + + static void Finalize(void* obj) { + internal::FinalizerTraitImpl::Finalize(obj); + } + + public: + // The callback used to finalize an object of type T. + static constexpr FinalizationCallback kCallback = + kNonTrivialFinalizer ? Finalize : nullptr; +}; + +template +constexpr FinalizationCallback FinalizerTrait::kCallback; + +} // namespace internal +} // namespace cppgc + +#endif // INCLUDE_CPPGC_FINALIZER_TRAIT_H_ diff --git a/deps/v8/include/cppgc/garbage-collected.h b/deps/v8/include/cppgc/garbage-collected.h new file mode 100644 index 00000000000000..6c62daafdc5d8d --- /dev/null +++ b/deps/v8/include/cppgc/garbage-collected.h @@ -0,0 +1,53 @@ +// Copyright 2020 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. + +#ifndef INCLUDE_CPPGC_GARBAGE_COLLECTED_H_ +#define INCLUDE_CPPGC_GARBAGE_COLLECTED_H_ + +#include + +#include "include/cppgc/internals.h" +#include "include/cppgc/platform.h" + +namespace cppgc { +namespace internal { + +template +struct IsGarbageCollectedType : std::false_type { + static_assert(sizeof(T), "T must be fully defined"); +}; + +template +struct IsGarbageCollectedType< + T, void_t::IsGarbageCollectedTypeMarker>> + : std::true_type { + static_assert(sizeof(T), "T must be fully defined"); +}; + +} // namespace internal + +template +class GarbageCollected { + public: + using IsGarbageCollectedTypeMarker = void; + + // Must use MakeGarbageCollected. + void* operator new(size_t) = delete; + void* operator new[](size_t) = delete; + // The garbage collector is taking care of reclaiming the object. Also, + // virtual destructor requires an unambiguous, accessible 'operator delete'. + void operator delete(void*) { +#ifdef V8_ENABLE_CHECKS + internal::Abort(); +#endif // V8_ENABLE_CHECKS + } + void operator delete[](void*) = delete; + + protected: + GarbageCollected() = default; +}; + +} // namespace cppgc + +#endif // INCLUDE_CPPGC_GARBAGE_COLLECTED_H_ diff --git a/deps/v8/include/cppgc/gc-info.h b/deps/v8/include/cppgc/gc-info.h new file mode 100644 index 00000000000000..987ba34fa4254c --- /dev/null +++ b/deps/v8/include/cppgc/gc-info.h @@ -0,0 +1,43 @@ +// Copyright 2020 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. + +#ifndef INCLUDE_CPPGC_GC_INFO_H_ +#define INCLUDE_CPPGC_GC_INFO_H_ + +#include + +#include "include/cppgc/finalizer-trait.h" +#include "include/v8config.h" + +namespace cppgc { +namespace internal { + +using GCInfoIndex = uint16_t; + +class V8_EXPORT RegisteredGCInfoIndex final { + public: + RegisteredGCInfoIndex(FinalizationCallback finalization_callback, + bool has_v_table); + GCInfoIndex GetIndex() const { return index_; } + + private: + const GCInfoIndex index_; +}; + +// Trait determines how the garbage collector treats objects wrt. to traversing, +// finalization, and naming. +template +struct GCInfoTrait { + static GCInfoIndex Index() { + static_assert(sizeof(T), "T must be fully defined"); + static const RegisteredGCInfoIndex registered_index( + FinalizerTrait::kCallback, std::is_polymorphic::value); + return registered_index.GetIndex(); + } +}; + +} // namespace internal +} // namespace cppgc + +#endif // INCLUDE_CPPGC_GC_INFO_H_ diff --git a/deps/v8/include/cppgc/heap.h b/deps/v8/include/cppgc/heap.h new file mode 100644 index 00000000000000..a0568d534fbee2 --- /dev/null +++ b/deps/v8/include/cppgc/heap.h @@ -0,0 +1,31 @@ +// Copyright 2020 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. + +#ifndef INCLUDE_CPPGC_HEAP_H_ +#define INCLUDE_CPPGC_HEAP_H_ + +#include + +#include "include/v8config.h" + +namespace cppgc { +namespace internal { +class Heap; +} // namespace internal + +class V8_EXPORT Heap { + public: + static std::unique_ptr Create(); + + virtual ~Heap() = default; + + private: + Heap() = default; + + friend class internal::Heap; +}; + +} // namespace cppgc + +#endif // INCLUDE_CPPGC_HEAP_H_ diff --git a/deps/v8/include/cppgc/internals.h b/deps/v8/include/cppgc/internals.h new file mode 100644 index 00000000000000..1e57779758b6c7 --- /dev/null +++ b/deps/v8/include/cppgc/internals.h @@ -0,0 +1,41 @@ +// Copyright 2020 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. + +#ifndef INCLUDE_CPPGC_INTERNALS_H_ +#define INCLUDE_CPPGC_INTERNALS_H_ + +#include +#include + +#include "include/v8config.h" + +namespace cppgc { +namespace internal { + +// Pre-C++17 custom implementation of std::void_t. +template +struct make_void { + typedef void type; +}; +template +using void_t = typename make_void::type; + +// Embedders should not rely on this code! + +// Internal constants to avoid exposing internal types on the API surface. +namespace api_constants { +// Offset of the uint16_t bitfield from the payload contaning the +// in-construction bit. This is subtracted from the payload pointer to get +// to the right bitfield. +static constexpr size_t kFullyConstructedBitFieldOffsetFromPayload = + 2 * sizeof(uint16_t); +// Mask for in-construction bit. +static constexpr size_t kFullyConstructedBitMask = size_t{1}; + +} // namespace api_constants + +} // namespace internal +} // namespace cppgc + +#endif // INCLUDE_CPPGC_INTERNALS_H_ diff --git a/deps/v8/include/cppgc/platform.h b/deps/v8/include/cppgc/platform.h new file mode 100644 index 00000000000000..f216c2730a4dea --- /dev/null +++ b/deps/v8/include/cppgc/platform.h @@ -0,0 +1,31 @@ +// Copyright 2020 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. + +#ifndef INCLUDE_CPPGC_PLATFORM_H_ +#define INCLUDE_CPPGC_PLATFORM_H_ + +#include "include/v8-platform.h" +#include "include/v8config.h" + +namespace cppgc { + +// TODO(v8:10346): Put PageAllocator in a non-V8 include header to avoid +// depending on namespace v8. +using PageAllocator = v8::PageAllocator; + +// Initializes the garbage collector with the provided platform. Must be called +// before creating a Heap. +V8_EXPORT void InitializePlatform(PageAllocator* page_allocator); + +// Must be called after destroying the last used heap. +V8_EXPORT void ShutdownPlatform(); + +namespace internal { + +V8_EXPORT void Abort(); + +} // namespace internal +} // namespace cppgc + +#endif // INCLUDE_CPPGC_PLATFORM_H_ diff --git a/deps/v8/include/js_protocol.pdl b/deps/v8/include/js_protocol.pdl index 28b8e610767142..3f5410d1e1f787 100644 --- a/deps/v8/include/js_protocol.pdl +++ b/deps/v8/include/js_protocol.pdl @@ -119,6 +119,7 @@ domain Debugger script eval module + wasm-expression-stack # Object representing the scope. For `global` and `with` scopes it represents the actual # object; for the rest of the scopes, it is artificial transient object enumerating scope # variables as its properties. @@ -273,6 +274,13 @@ domain Debugger # Resumes JavaScript execution. command resume + parameters + # Set to true to terminate execution upon resuming execution. In contrast + # to Runtime.terminateExecution, this will allows to execute further + # JavaScript (i.e. via evaluation) until execution of the paused code + # is actually resumed, at which point termination is triggered. + # If execution is currently not paused, this parameter has no effect. + optional boolean terminateOnResume # Searches for given string in script content. command searchInContent @@ -496,6 +504,12 @@ domain Debugger # Fired when the virtual machine resumed execution. event resumed + # Enum of possible script languages. + type ScriptLanguage extends string + enum + JavaScript + WebAssembly + # Fired when virtual machine fails to parse the script. event scriptFailedToParse parameters @@ -527,6 +541,10 @@ domain Debugger optional integer length # JavaScript top stack frame of where the script parsed event was triggered if available. experimental optional Runtime.StackTrace stackTrace + # If the scriptLanguage is WebAssembly, the code section offset in the module. + experimental optional integer codeOffset + # The language of the script. + experimental optional Debugger.ScriptLanguage scriptLanguage # Fired when virtual machine parses script. This event is also fired for all known and uncollected # scripts upon enabling debugger. @@ -562,6 +580,10 @@ domain Debugger optional integer length # JavaScript top stack frame of where the script parsed event was triggered if available. experimental optional Runtime.StackTrace stackTrace + # If the scriptLanguage is WebAssembly, the code section offset in the module. + experimental optional integer codeOffset + # The language of the script. + experimental optional Debugger.ScriptLanguage scriptLanguage experimental domain HeapProfiler depends on Runtime @@ -824,6 +846,8 @@ domain Profiler optional boolean callCount # Collect block-based coverage. optional boolean detailed + # Allow the backend to send updates on its own initiative + optional boolean allowTriggeredUpdates returns # Monotonically increasing time (in seconds) when the coverage update was taken in the backend. number timestamp @@ -931,7 +955,8 @@ domain Runtime boolean symbol bigint - # Object subtype hint. Specified for `object` type values only. + wasm + # Object subtype hint. Specified for `object` or `wasm` type values only. optional enum subtype array null @@ -950,6 +975,11 @@ domain Runtime typedarray arraybuffer dataview + i32 + i64 + f32 + f64 + v128 # Object class (constructor) name. Specified for `object` type values only. optional string className # Remote object value in case of primitive values or JSON values (if it was requested). @@ -1306,7 +1336,9 @@ domain Runtime experimental optional TimeDelta timeout # Disable breakpoints during execution. experimental optional boolean disableBreaks - # Reserved flag for future REPL mode support. Setting this flag has currently no effect. + # Setting this flag to true enables `let` re-declaration and top-level `await`. + # Note that `let` variables can only be re-declared if they originate from + # `replMode` themselves. experimental optional boolean replMode returns # Evaluation result. diff --git a/deps/v8/include/v8-fast-api-calls.h b/deps/v8/include/v8-fast-api-calls.h new file mode 100644 index 00000000000000..bfce66b652dd2d --- /dev/null +++ b/deps/v8/include/v8-fast-api-calls.h @@ -0,0 +1,408 @@ +// Copyright 2020 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. + +/** + * This file provides additional API on top of the default one for making + * API calls, which come from embedder C++ functions. The functions are being + * called directly from optimized code, doing all the necessary typechecks + * in the compiler itself, instead of on the embedder side. Hence the "fast" + * in the name. Example usage might look like: + * + * \code + * void FastMethod(int param, bool another_param); + * + * v8::FunctionTemplate::New(isolate, SlowCallback, data, + * signature, length, constructor_behavior + * side_effect_type, + * &v8::CFunction::Make(FastMethod)); + * \endcode + * + * An example for custom embedder type support might employ a way to wrap/ + * unwrap various C++ types in JSObject instances, e.g: + * + * \code + * + * // Represents the way this type system maps C++ and JS values. + * struct WrapperTypeInfo { + * // Store e.g. a method to map from exposed C++ types to the already + * // created v8::FunctionTemplate's for instantiating them. + * }; + * + * // Helper method with a sanity check. + * template + * inline T* GetInternalField(v8::Local wrapper) { + * assert(offset < wrapper->InternalFieldCount()); + * return reinterpret_cast( + * wrapper->GetAlignedPointerFromInternalField(offset)); + * } + * + * // Returns the type info from a wrapper JS object. + * inline const WrapperTypeInfo* ToWrapperTypeInfo( + * v8::Local wrapper) { + * return GetInternalField(wrapper); + * } + * + * class CustomEmbedderType { + * public: + * static constexpr const WrapperTypeInfo* GetWrapperTypeInfo() { + * return &custom_type_wrapper_type_info; + * } + * // Returns the raw C object from a wrapper JS object. + * static CustomEmbedderType* Unwrap(v8::Local wrapper) { + * return GetInternalField(wrapper); + * } + * static void FastMethod(CustomEmbedderType* receiver, int param) { + * assert(receiver != nullptr); + * // Type checks are already done by the optimized code. + * // Then call some performance-critical method like: + * // receiver->Method(param); + * } + * + * static void SlowMethod( + * const v8::FunctionCallbackInfo& info) { + * v8::Local instance = + * v8::Local::Cast(info.Holder()); + * CustomEmbedderType* receiver = Unwrap(instance); + * // TODO: Do type checks and extract {param}. + * FastMethod(receiver, param); + * } + * + * private: + * static const WrapperTypeInfo custom_type_wrapper_type_info; + * }; + * + * // Support for custom embedder types via specialization of WrapperTraits. + * namespace v8 { + * template <> + * class WrapperTraits { + * public: + * static const void* GetTypeInfo() { + * // We use the already defined machinery for the custom type. + * return CustomEmbedderType::GetWrapperTypeInfo(); + * } + * }; + * } // namespace v8 + * + * // The constants kV8EmbedderWrapperTypeIndex and + * // kV8EmbedderWrapperObjectIndex describe the offsets for the type info + * // struct (the one returned by WrapperTraits::GetTypeInfo) and the + * // native object, when expressed as internal field indices within a + * // JSObject. The existance of this helper function assumes that all + * // embedder objects have their JSObject-side type info at the same + * // offset, but this is not a limitation of the API itself. For a detailed + * // use case, see the third example. + * static constexpr int kV8EmbedderWrapperTypeIndex = 0; + * static constexpr int kV8EmbedderWrapperObjectIndex = 1; + * + * // The following setup function can be templatized based on + * // the {embedder_object} argument. + * void SetupCustomEmbedderObject(v8::Isolate* isolate, + * v8::Local context, + * CustomEmbedderType* embedder_object) { + * isolate->set_embedder_wrapper_type_index( + * kV8EmbedderWrapperTypeIndex); + * isolate->set_embedder_wrapper_object_index( + * kV8EmbedderWrapperObjectIndex); + * + * v8::CFunction c_func = + * MakeV8CFunction(CustomEmbedderType::FastMethod); + * + * Local method_template = + * v8::FunctionTemplate::New( + * isolate, CustomEmbedderType::SlowMethod, v8::Local(), + * v8::Local(), 1, v8::ConstructorBehavior::kAllow, + * v8::SideEffectType::kHasSideEffect, &c_func); + * + * v8::Local object_template = + * v8::ObjectTemplate::New(isolate); + * object_template->SetInternalFieldCount( + * kV8EmbedderWrapperObjectIndex + 1); + * object_template->Set( + v8::String::NewFromUtf8Literal(isolate, "method"), method_template); + * + * // Instantiate the wrapper JS object. + * v8::Local object = + * object_template->NewInstance(context).ToLocalChecked(); + * object->SetAlignedPointerInInternalField( + * kV8EmbedderWrapperObjectIndex, + * reinterpret_cast(embedder_object)); + * + * // TODO: Expose {object} where it's necessary. + * } + * \endcode + * + * For instance if {object} is exposed via a global "obj" variable, + * one could write in JS: + * function hot_func() { + * obj.method(42); + * } + * and once {hot_func} gets optimized, CustomEmbedderType::FastMethod + * will be called instead of the slow version, with the following arguments: + * receiver := the {embedder_object} from above + * param := 42 + * + * Currently only void return types are supported. + * Currently supported argument types: + * - pointer to an embedder type + * - bool + * - int32_t + * - uint32_t + * To be supported types: + * - int64_t + * - uint64_t + * - float32_t + * - float64_t + * - arrays of C types + * - arrays of embedder types + */ + +#ifndef INCLUDE_V8_FAST_API_CALLS_H_ +#define INCLUDE_V8_FAST_API_CALLS_H_ + +#include +#include + +#include "v8config.h" // NOLINT(build/include) + +namespace v8 { + +class CTypeInfo { + public: + enum class Type : char { + kVoid, + kBool, + kInt32, + kUint32, + kInt64, + kUint64, + kFloat32, + kFloat64, + kUnwrappedApiObject, + }; + + enum ArgFlags : char { + None = 0, + IsArrayBit = 1 << 0, // This argument is first in an array of values. + }; + + static CTypeInfo FromWrapperType(const void* wrapper_type_info, + ArgFlags flags = ArgFlags::None) { + uintptr_t wrapper_type_info_ptr = + reinterpret_cast(wrapper_type_info); + // Check that the lower kIsWrapperTypeBit bits are 0's. + CHECK_EQ( + wrapper_type_info_ptr & ~(static_cast(~0) + << static_cast(kIsWrapperTypeBit)), + 0); + // TODO(mslekova): Refactor the manual bit manipulations to use + // PointerWithPayload instead. + return CTypeInfo(wrapper_type_info_ptr | flags | kIsWrapperTypeBit); + } + + static constexpr CTypeInfo FromCType(Type ctype, + ArgFlags flags = ArgFlags::None) { + // ctype cannot be Type::kUnwrappedApiObject. + return CTypeInfo( + ((static_cast(ctype) << kTypeOffset) & kTypeMask) | flags); + } + + const void* GetWrapperInfo() const; + + constexpr Type GetType() const { + if (payload_ & kIsWrapperTypeBit) { + return Type::kUnwrappedApiObject; + } + return static_cast((payload_ & kTypeMask) >> kTypeOffset); + } + + constexpr bool IsArray() const { return payload_ & ArgFlags::IsArrayBit; } + + private: + explicit constexpr CTypeInfo(uintptr_t payload) : payload_(payload) {} + + // That must be the last bit after ArgFlags. + static constexpr uintptr_t kIsWrapperTypeBit = 1 << 1; + static constexpr uintptr_t kWrapperTypeInfoMask = static_cast(~0) + << 2; + + static constexpr unsigned int kTypeOffset = kIsWrapperTypeBit; + static constexpr unsigned int kTypeSize = 8 - kTypeOffset; + static constexpr uintptr_t kTypeMask = + (~(static_cast(~0) << kTypeSize)) << kTypeOffset; + + const uintptr_t payload_; +}; + +class CFunctionInfo { + public: + virtual const CTypeInfo& ReturnInfo() const = 0; + virtual unsigned int ArgumentCount() const = 0; + virtual const CTypeInfo& ArgumentInfo(unsigned int index) const = 0; +}; + +template +class WrapperTraits { + public: + static const void* GetTypeInfo() { + static_assert(sizeof(T) != sizeof(T), + "WrapperTraits must be specialized for this type."); + return nullptr; + } +}; + +namespace internal { + +template +struct GetCType { + static_assert(sizeof(T) != sizeof(T), "Unsupported CType"); +}; + +#define SPECIALIZE_GET_C_TYPE_FOR(ctype, ctypeinfo) \ + template <> \ + struct GetCType { \ + static constexpr CTypeInfo Get() { \ + return CTypeInfo::FromCType(CTypeInfo::Type::ctypeinfo); \ + } \ + }; + +#define SUPPORTED_C_TYPES(V) \ + V(void, kVoid) \ + V(bool, kBool) \ + V(int32_t, kInt32) \ + V(uint32_t, kUint32) \ + V(int64_t, kInt64) \ + V(uint64_t, kUint64) \ + V(float, kFloat32) \ + V(double, kFloat64) + +SUPPORTED_C_TYPES(SPECIALIZE_GET_C_TYPE_FOR) + +template +struct EnableIfHasWrapperTypeInfo {}; + +template <> +struct EnableIfHasWrapperTypeInfo {}; + +template +struct EnableIfHasWrapperTypeInfo::GetTypeInfo(), + void())> { + typedef void type; +}; + +// T* where T is a primitive (array of primitives). +template +struct GetCTypePointerImpl { + static constexpr CTypeInfo Get() { + return CTypeInfo::FromCType(GetCType::Get().GetType(), + CTypeInfo::IsArrayBit); + } +}; + +// T* where T is an API object. +template +struct GetCTypePointerImpl::type> { + static constexpr CTypeInfo Get() { + return CTypeInfo::FromWrapperType(WrapperTraits::GetTypeInfo()); + } +}; + +// T** where T is a primitive. Not allowed. +template +struct GetCTypePointerPointerImpl { + static_assert(sizeof(T**) != sizeof(T**), "Unsupported type"); +}; + +// T** where T is an API object (array of API objects). +template +struct GetCTypePointerPointerImpl< + T, typename EnableIfHasWrapperTypeInfo::type> { + static constexpr CTypeInfo Get() { + return CTypeInfo::FromWrapperType(WrapperTraits::GetTypeInfo(), + CTypeInfo::IsArrayBit); + } +}; + +template +struct GetCType : public GetCTypePointerPointerImpl {}; + +template +struct GetCType : public GetCTypePointerImpl {}; + +template +class CFunctionInfoImpl : public CFunctionInfo { + public: + CFunctionInfoImpl() + : return_info_(i::GetCType::Get()), + arg_count_(sizeof...(Args)), + arg_info_{i::GetCType::Get()...} { + static_assert(i::GetCType::Get().GetType() == CTypeInfo::Type::kVoid, + "Only void return types are currently supported."); + } + + const CTypeInfo& ReturnInfo() const override { return return_info_; } + unsigned int ArgumentCount() const override { return arg_count_; } + const CTypeInfo& ArgumentInfo(unsigned int index) const override { + CHECK_LT(index, ArgumentCount()); + return arg_info_[index]; + } + + private: + CTypeInfo return_info_; + const unsigned int arg_count_; + CTypeInfo arg_info_[sizeof...(Args)]; +}; + +} // namespace internal + +class V8_EXPORT CFunction { + public: + const CTypeInfo& ReturnInfo() const { return type_info_->ReturnInfo(); } + + const CTypeInfo& ArgumentInfo(unsigned int index) const { + return type_info_->ArgumentInfo(index); + } + + unsigned int ArgumentCount() const { return type_info_->ArgumentCount(); } + + const void* GetAddress() const { return address_; } + const CFunctionInfo* GetTypeInfo() const { return type_info_; } + + template + static CFunction Make(F* func) { + return ArgUnwrap::Make(func); + } + + private: + const void* address_; + const CFunctionInfo* type_info_; + + CFunction(const void* address, const CFunctionInfo* type_info); + + template + static CFunctionInfo* GetCFunctionInfo() { + static internal::CFunctionInfoImpl instance; + return &instance; + } + + template + class ArgUnwrap { + static_assert(sizeof(F) != sizeof(F), + "CFunction must be created from a function pointer."); + }; + + template + class ArgUnwrap { + public: + static CFunction Make(R (*func)(Args...)) { + return CFunction(reinterpret_cast(func), + GetCFunctionInfo()); + } + }; +}; + +} // namespace v8 + +#endif // INCLUDE_V8_FAST_API_CALLS_H_ diff --git a/deps/v8/include/v8-inspector.h b/deps/v8/include/v8-inspector.h index 99333cb7319e62..01274625c1f476 100644 --- a/deps/v8/include/v8-inspector.h +++ b/deps/v8/include/v8-inspector.h @@ -145,9 +145,6 @@ class V8_EXPORT V8InspectorSession { virtual void breakProgram(StringView breakReason, StringView breakDetails) = 0; virtual void setSkipAllPauses(bool) = 0; - - // NOTE: setTerminateOnResume is not implemented on the base version of - // Node.js v14.0.0 / V8 8.1. virtual void resume(bool setTerminateOnResume = false) = 0; virtual void stepOver() = 0; virtual std::vector> diff --git a/deps/v8/include/v8-internal.h b/deps/v8/include/v8-internal.h index 52ee403f526d06..876408ebba98f9 100644 --- a/deps/v8/include/v8-internal.h +++ b/deps/v8/include/v8-internal.h @@ -106,10 +106,6 @@ const int kApiTaggedSize = kApiInt32Size; const int kApiTaggedSize = kApiSystemPointerSize; #endif -constexpr bool PointerCompressionIsEnabled() { - return kApiTaggedSize != kApiSystemPointerSize; -} - #ifdef V8_31BIT_SMIS_ON_64BIT_ARCH using PlatformSmiTagging = SmiTagging; #else diff --git a/deps/v8/include/v8-version.h b/deps/v8/include/v8-version.h index f21a0b8dd0fd69..64f184866537b5 100644 --- a/deps/v8/include/v8-version.h +++ b/deps/v8/include/v8-version.h @@ -9,9 +9,9 @@ // NOTE these macros are used by some of the tool scripts and the build // system so their names cannot be changed without changing the scripts. #define V8_MAJOR_VERSION 8 -#define V8_MINOR_VERSION 1 -#define V8_BUILD_NUMBER 307 -#define V8_PATCH_LEVEL 31 +#define V8_MINOR_VERSION 3 +#define V8_BUILD_NUMBER 110 +#define V8_PATCH_LEVEL 9 // Use 1 for candidates and 0 otherwise. // (Boolean macro values are not supported by all preprocessors.) diff --git a/deps/v8/include/v8.h b/deps/v8/include/v8.h index d09055e15d2fbd..9926b308b15cda 100644 --- a/deps/v8/include/v8.h +++ b/deps/v8/include/v8.h @@ -120,6 +120,8 @@ class EscapableHandleScope; template class ReturnValue; namespace internal { +enum class ArgumentsType; +template class Arguments; class DeferredHandles; class Heap; @@ -149,11 +151,6 @@ class ConsoleCallArguments; // --- Handles --- -#define TYPE_CHECK(T, S) \ - while (false) { \ - *(static_cast(0)) = static_cast(0); \ - } - /** * An object reference managed by the v8 garbage collector. * @@ -197,7 +194,7 @@ class Local { * handles. For example, converting from a Local to a * Local. */ - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } /** @@ -363,7 +360,7 @@ class MaybeLocal { template V8_INLINE MaybeLocal(Local that) : val_(reinterpret_cast(*that)) { - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } V8_INLINE bool IsEmpty() const { return val_ == nullptr; } @@ -532,11 +529,16 @@ template class PersistentBase { } /** - * Install a finalization callback on this object. - * NOTE: There is no guarantee as to *when* or even *if* the callback is - * invoked. The invocation is performed solely on a best effort basis. - * As always, GC-based finalization should *not* be relied upon for any - * critical form of resource management! + * Install a finalization callback on this object. + * NOTE: There is no guarantee as to *when* or even *if* the callback is + * invoked. The invocation is performed solely on a best effort basis. + * As always, GC-based finalization should *not* be relied upon for any + * critical form of resource management! + * + * The callback is supposed to reset the handle. No further V8 API may be + * called in this callback. In case additional work involving V8 needs to be + * done, a second callback can be scheduled using + * WeakCallbackInfo::SetSecondPassCallback. */ template V8_INLINE void SetWeak(P* parameter, @@ -618,11 +620,8 @@ class NonCopyablePersistentTraits { template V8_INLINE static void Copy(const Persistent& source, NonCopyablePersistent* dest) { - Uncompilable(); - } - // TODO(dcarney): come up with a good compile error here. - template V8_INLINE static void Uncompilable() { - TYPE_CHECK(O, Primitive); + static_assert(sizeof(S) < 0, + "NonCopyablePersistentTraits::Copy is not instantiable"); } }; @@ -665,7 +664,7 @@ template class Persistent : public PersistentBase { template V8_INLINE Persistent(Isolate* isolate, Local that) : PersistentBase(PersistentBase::New(isolate, *that)) { - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } /** * Construct a Persistent from a Persistent. @@ -675,7 +674,7 @@ template class Persistent : public PersistentBase { template V8_INLINE Persistent(Isolate* isolate, const Persistent& that) : PersistentBase(PersistentBase::New(isolate, *that)) { - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } /** * The copy constructors and assignment operator create a Persistent @@ -760,7 +759,7 @@ class Global : public PersistentBase { template V8_INLINE Global(Isolate* isolate, Local that) : PersistentBase(PersistentBase::New(isolate, *that)) { - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } /** @@ -771,7 +770,7 @@ class Global : public PersistentBase { template V8_INLINE Global(Isolate* isolate, const PersistentBase& that) : PersistentBase(PersistentBase::New(isolate, that.val_)) { - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } /** @@ -951,7 +950,7 @@ class TracedGlobal : public TracedReferenceBase { TracedGlobal(Isolate* isolate, Local that) : TracedReferenceBase() { this->val_ = this->New(isolate, that.val_, &this->val_, TracedReferenceBase::kWithDestructor); - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } /** @@ -1074,7 +1073,7 @@ class TracedReference : public TracedReferenceBase { TracedReference(Isolate* isolate, Local that) : TracedReferenceBase() { this->val_ = this->New(isolate, that.val_, &this->val_, TracedReferenceBase::kWithoutDestructor); - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } /** @@ -1753,11 +1752,9 @@ class V8_EXPORT ScriptCompiler { public: enum Encoding { ONE_BYTE, TWO_BYTE, UTF8 }; -#if defined(_MSC_VER) && _MSC_VER >= 1910 /* Disable on VS2015 */ V8_DEPRECATE_SOON( "This class takes ownership of source_stream, so use the constructor " "taking a unique_ptr to make these semantics clearer") -#endif StreamedSource(ExternalSourceStream* source_stream, Encoding encoding); StreamedSource(std::unique_ptr source_stream, Encoding encoding); @@ -3176,6 +3173,23 @@ class V8_EXPORT String : public Name { V8_INLINE static String* Cast(v8::Value* obj); + /** + * Allocates a new string from a UTF-8 literal. This is equivalent to calling + * String::NewFromUtf(isolate, "...").ToLocalChecked(), but without the check + * overhead. + * + * When called on a string literal containing '\0', the inferred length is the + * length of the input array minus 1 (for the final '\0') and not the value + * returned by strlen. + **/ + template + static V8_WARN_UNUSED_RESULT Local NewFromUtf8Literal( + Isolate* isolate, const char (&literal)[N], + NewStringType type = NewStringType::kNormal) { + static_assert(N <= kMaxLength, "String is too long"); + return NewFromUtf8Literal(isolate, literal, type, N - 1); + } + /** Allocates a new string from UTF-8 data. Only returns an empty value when * length > kMaxLength. **/ static V8_WARN_UNUSED_RESULT MaybeLocal NewFromUtf8( @@ -3310,9 +3324,20 @@ class V8_EXPORT String : public Name { ExternalStringResourceBase* GetExternalStringResourceBaseSlow( String::Encoding* encoding_out) const; + static Local NewFromUtf8Literal(Isolate* isolate, + const char* literal, + NewStringType type, int length); + static void CheckCast(v8::Value* obj); }; +// Zero-length string specialization (templated string size includes +// terminator). +template <> +inline V8_WARN_UNUSED_RESULT Local String::NewFromUtf8Literal( + Isolate* isolate, const char (&literal)[1], NewStringType type) { + return String::Empty(isolate); +} /** * A JavaScript symbol (ECMA-262 edition 6) @@ -4019,6 +4044,13 @@ class V8_EXPORT Object : public Value { */ bool IsApiWrapper(); + /** + * True if this object was created from an object template which was marked + * as undetectable. See v8::ObjectTemplate::MarkAsUndetectable for more + * information. + */ + bool IsUndetectable(); + /** * Call an Object as a function if a callback is set by the * ObjectTemplate::SetCallAsFunctionHandler method. @@ -4175,7 +4207,7 @@ class ReturnValue { public: template V8_INLINE ReturnValue(const ReturnValue& that) : value_(that.value_) { - TYPE_CHECK(T, S); + static_assert(std::is_base_of::value, "type check"); } // Local setters template @@ -4939,6 +4971,25 @@ class V8_EXPORT BackingStore : public v8::internal::BackingStoreBase { v8::Isolate* isolate, std::unique_ptr backing_store, size_t byte_length); + /** + * This callback is used only if the memory block for a BackingStore cannot be + * allocated with an ArrayBuffer::Allocator. In such cases the destructor of + * the BackingStore invokes the callback to free the memory block. + */ + using DeleterCallback = void (*)(void* data, size_t length, + void* deleter_data); + + /** + * If the memory block of a BackingStore is static or is managed manually, + * then this empty deleter along with nullptr deleter_data can be passed to + * ArrayBuffer::NewBackingStore to indicate that. + * + * The manually managed case should be used with caution and only when it + * is guaranteed that the memory block freeing happens after detaching its + * ArrayBuffer. + */ + static void EmptyDeleter(void* data, size_t length, void* deleter_data); + private: /** * See [Shared]ArrayBuffer::GetBackingStore and @@ -4947,14 +4998,13 @@ class V8_EXPORT BackingStore : public v8::internal::BackingStoreBase { BackingStore(); }; -/** - * This callback is used only if the memory block for this backing store cannot - * be allocated with an ArrayBuffer::Allocator. In such cases the destructor - * of this backing store object invokes the callback to free the memory block. - */ +#if !defined(V8_IMMINENT_DEPRECATION_WARNINGS) +// Use v8::BackingStore::DeleterCallback instead. using BackingStoreDeleterCallback = void (*)(void* data, size_t length, void* deleter_data); +#endif + /** * An instance of the built-in ArrayBuffer constructor (ES6 draft 15.13.5). */ @@ -5142,7 +5192,7 @@ class V8_EXPORT ArrayBuffer : public Object { * to the buffer must not be passed again to any V8 API function. */ static std::unique_ptr NewBackingStore( - void* data, size_t byte_length, BackingStoreDeleterCallback deleter, + void* data, size_t byte_length, v8::BackingStore::DeleterCallback deleter, void* deleter_data); /** @@ -5624,7 +5674,7 @@ class V8_EXPORT SharedArrayBuffer : public Object { * to the buffer must not be passed again to any V8 functions. */ static std::unique_ptr NewBackingStore( - void* data, size_t byte_length, BackingStoreDeleterCallback deleter, + void* data, size_t byte_length, v8::BackingStore::DeleterCallback deleter, void* deleter_data); /** @@ -5884,14 +5934,15 @@ class V8_EXPORT RegExp : public Object { }; /** - * An instance of the built-in FinalizationGroup constructor. + * An instance of the built-in FinalizationRegistry constructor. * - * This API is experimental and may change significantly. + * The C++ name is FinalizationGroup for backwards compatibility. This API is + * experimental and deprecated. */ class V8_EXPORT FinalizationGroup : public Object { public: /** - * Runs the cleanup callback of the given FinalizationGroup. + * Runs the cleanup callback of the given FinalizationRegistry. * * V8 will inform the embedder that there are finalizer callbacks be * called through HostCleanupFinalizationGroupCallback. @@ -6315,11 +6366,12 @@ class CFunction; * proto_t->Set(isolate, "proto_const", v8::Number::New(isolate, 2)); * * v8::Local instance_t = t->InstanceTemplate(); - * instance_t->SetAccessor(String::NewFromUtf8(isolate, "instance_accessor"), - * InstanceAccessorCallback); + * instance_t->SetAccessor( + String::NewFromUtf8Literal(isolate, "instance_accessor"), + * InstanceAccessorCallback); * instance_t->SetHandler( * NamedPropertyHandlerConfiguration(PropertyHandlerCallback)); - * instance_t->Set(String::NewFromUtf8(isolate, "instance_property"), + * instance_t->Set(String::NewFromUtf8Literal(isolate, "instance_property"), * Number::New(isolate, 3)); * * v8::Local function = t->GetFunction(); @@ -6379,6 +6431,12 @@ class CFunction; * child_instance.instance_accessor calls 'InstanceAccessorCallback' * child_instance.instance_property == 3; * \endcode + * + * The additional 'c_function' parameter refers to a fast API call, which + * must not trigger GC or JavaScript execution, or call into V8 in other + * ways. For more information how to define them, see + * include/v8-fast-api-calls.h. Please note that this feature is still + * experimental. */ class V8_EXPORT FunctionTemplate : public Template { public: @@ -6389,7 +6447,12 @@ class V8_EXPORT FunctionTemplate : public Template { Local signature = Local(), int length = 0, ConstructorBehavior behavior = ConstructorBehavior::kAllow, SideEffectType side_effect_type = SideEffectType::kHasSideEffect, - const CFunction* not_available_in_node_v14_yet = nullptr); + const CFunction* c_function = nullptr); + + /** Get a template included in the snapshot by index. */ + V8_DEPRECATED("Use v8::Isolate::GetDataFromSnapshotOnce instead") + static MaybeLocal FromSnapshot(Isolate* isolate, + size_t index); /** * Creates a function template backed/cached by a private property. @@ -6416,12 +6479,13 @@ class V8_EXPORT FunctionTemplate : public Template { /** * Set the call-handler callback for a FunctionTemplate. This * callback is called whenever the function created from this - * FunctionTemplate is called. + * FunctionTemplate is called. The 'c_function' represents a fast + * API call, see the comment above the class declaration. */ void SetCallHandler( FunctionCallback callback, Local data = Local(), SideEffectType side_effect_type = SideEffectType::kHasSideEffect, - const CFunction* not_available_in_node_v14_yet = nullptr); + const CFunction* c_function = nullptr); /** Set the predefined length property for the FunctionTemplate. */ void SetLength(int length); @@ -6679,6 +6743,11 @@ class V8_EXPORT ObjectTemplate : public Template { Isolate* isolate, Local constructor = Local()); + /** Get a template included in the snapshot by index. */ + V8_DEPRECATED("Use v8::Isolate::GetDataFromSnapshotOnce instead") + static MaybeLocal FromSnapshot(Isolate* isolate, + size_t index); + /** Creates a new instance of this template.*/ V8_WARN_UNUSED_RESULT MaybeLocal NewInstance(Local context); @@ -7265,6 +7334,7 @@ class PromiseRejectMessage { typedef void (*PromiseRejectCallback)(PromiseRejectMessage message); // --- Microtasks Callbacks --- +V8_DEPRECATE_SOON("Use *WithData version.") typedef void (*MicrotasksCompletedCallback)(Isolate*); typedef void (*MicrotasksCompletedCallbackWithData)(Isolate*, void*); typedef void (*MicrotaskCallback)(void* data); @@ -7452,7 +7522,7 @@ typedef void (*WasmStreamingCallback)(const FunctionCallbackInfo&); // --- Callback for checking if WebAssembly threads are enabled --- typedef bool (*WasmThreadsEnabledCallback)(Local context); -// --- Callback for loading source map file for WASM profiling support +// --- Callback for loading source map file for Wasm profiling support typedef Local (*WasmLoadSourceMapCallback)(Isolate* isolate, const char* name); @@ -8113,10 +8183,7 @@ class V8_EXPORT Isolate { array_buffer_allocator_shared(), external_references(nullptr), allow_atomics_wait(true), - only_terminate_in_safe_scope(false), - embedder_wrapper_type_index(-1), - embedder_wrapper_object_index(-1) {} - + only_terminate_in_safe_scope(false) {} /** * Allows the host application to provide the address of a function that is @@ -8180,10 +8247,6 @@ class V8_EXPORT Isolate { * Termination is postponed when there is no active SafeForTerminationScope. */ bool only_terminate_in_safe_scope; - - // Not available in Node v14 yet. - int embedder_wrapper_type_index; - int embedder_wrapper_object_index; }; @@ -8486,12 +8549,12 @@ class V8_EXPORT Isolate { AbortOnUncaughtExceptionCallback callback); /** - * This specifies the callback to be called when finalization groups + * This specifies the callback to be called when FinalizationRegistries * are ready to be cleaned up and require FinalizationGroup::Cleanup() * to be called in a future task. */ V8_DEPRECATED( - "FinalizationGroup cleanup is automatic if " + "FinalizationRegistry cleanup is automatic if " "HostCleanupFinalizationGroupCallback is not set") void SetHostCleanupFinalizationGroupCallback( HostCleanupFinalizationGroupCallback callback); @@ -9106,7 +9169,7 @@ class V8_EXPORT Isolate { /** * Optional notification that a context has been disposed. V8 uses these - * notifications to guide the GC heuristic and cancel FinalizationGroup + * notifications to guide the GC heuristic and cancel FinalizationRegistry * cleanup tasks. Returns the number of context disposals - including this one * - since the last time V8 had a chance to clean up. * @@ -9534,12 +9597,7 @@ class V8_EXPORT V8 { * Initializes V8. This function needs to be called before the first Isolate * is created. It always returns true. */ - V8_INLINE static bool Initialize() { - const int kBuildConfiguration = - (internal::PointerCompressionIsEnabled() ? kPointerCompression : 0) | - (internal::SmiValuesAre31Bits() ? k31BitSmis : 0); - return Initialize(kBuildConfiguration); - } + static bool Initialize(); /** * Allows the host application to provide a callback which can be used @@ -9673,17 +9731,6 @@ class V8_EXPORT V8 { private: V8(); - enum BuildConfigurationFeatures { - kPointerCompression = 1 << 0, - k31BitSmis = 1 << 1, - }; - - /** - * Checks that the embedder build configuration is compatible with - * the V8 binary and if so initializes V8. - */ - static bool Initialize(int build_config); - static internal::Address* GlobalizeReference(internal::Isolate* isolate, internal::Address* handle); static internal::Address* GlobalizeTracedReference(internal::Isolate* isolate, @@ -9798,6 +9845,13 @@ class V8_EXPORT SnapshotCreator { SerializeInternalFieldsCallback callback = SerializeInternalFieldsCallback()); + /** + * Add a template to be included in the snapshot blob. + * \returns the index of the template in the snapshot blob. + */ + V8_DEPRECATED("use AddData instead") + size_t AddTemplate(Local