diff --git a/WORKSPACE b/WORKSPACE index f1c43bee691..c4426562874 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -146,13 +146,6 @@ git_repository( remote = "https://chromium.googlesource.com/chromium/src/third_party/abseil-cpp.git", ) -git_repository( - name = "fast_float", - build_file_content = "exports_files(glob([\"**\"]))", - commit = "d7417618f93d2c47e9bbde561510f9fc8bafe003", - remote = "https://chromium.googlesource.com/external/github.com/fastfloat/fast_float.git", -) - git_repository( name = "fp16", build_file_content = "exports_files(glob([\"**\"]))", @@ -336,7 +329,7 @@ npm_repositories() http_archive( name = "v8", - integrity = "sha256-xrrRWhvzf0Kl9FVZ8xO7zb07gefU3sx6uLiPdQ6VV0E=", + integrity = "sha256-OTr3bwOCu50VAtMUd7d1kZXIkT1OoF9+zo9g3E7Vyvo=", patch_args = ["-p1"], patches = [ "//:patches/v8/0001-Allow-manually-setting-ValueDeserializer-format-vers.patch", @@ -358,10 +351,9 @@ http_archive( "//:patches/v8/0017-Revert-heap-Add-masm-specific-unwinding-annotations-.patch", "//:patches/v8/0018-Update-illegal-invocation-error-message-in-v8.patch", "//:patches/v8/0019-Implement-cross-request-context-promise-resolve-hand.patch", - "//:patches/v8/0020-Modify-where-to-look-for-fast_float-dependency.patch", ], - strip_prefix = "v8-13.0.245.1", - url = "https://github.com/v8/v8/archive/refs/tags/13.0.245.1.tar.gz", + strip_prefix = "v8-12.9.202.27", + url = "https://github.com/v8/v8/archive/refs/tags/12.9.202.27.tar.gz", ) git_repository( diff --git a/docs/v8-updates.md b/docs/v8-updates.md index b26a5785e83..7b8d04dd9c4 100644 --- a/docs/v8-updates.md +++ b/docs/v8-updates.md @@ -36,14 +36,14 @@ To update the version of V8 used by workerd, the steps are: ``` 6. Rebase the workerd V8 changes onto the new version of V8. For example, assuming - we are updating to 11.4.183.8 and there are 8 workerd patches for V8, the + we are updating to 11.4.183.8 and there are 19 workerd patches for V8, the command would be: ```sh - git rebase --onto 11.4.183.8 HEAD~8 + git rebase --onto 11.4.183.8 HEAD~19 ``` - Note that `HEAD~8`, here and elsewhere, could be replaced with + Note that `HEAD~19`, here and elsewhere, could be replaced with `$(git describe --tags --abbrev=0)`, which prints the name of the tag on which the branch is based. @@ -52,11 +52,11 @@ To update the version of V8 used by workerd, the steps are: Ideally at this stage, you should be able to build and test the local V8 with the patches applied. See the V8 [Testing](https://v8.dev/docs/test) page. -7. Re-generate workerd's V8 patches. Assuming there are 8 workerd patches for V8, +7. Re-generate workerd's V8 patches. Assuming there are 19 workerd patches for V8, the command would be: ```sh - git format-patch --full-index -k --no-signature --no-stat HEAD~8 + git format-patch --full-index -k --no-signature --no-stat HEAD~19 ``` 8. Remove the existing patches from `workerd/patches/v8` and copy over the latest generated patches diff --git a/patches/v8/0001-Allow-manually-setting-ValueDeserializer-format-vers.patch b/patches/v8/0001-Allow-manually-setting-ValueDeserializer-format-vers.patch index d72f9f4d63f..17585a3494a 100644 --- a/patches/v8/0001-Allow-manually-setting-ValueDeserializer-format-vers.patch +++ b/patches/v8/0001-Allow-manually-setting-ValueDeserializer-format-vers.patch @@ -1,4 +1,4 @@ -From ab1c70706bef5ba96894e955724f61df62daec8b Mon Sep 17 00:00:00 2001 +From 1716f5dcb290435138f2d2c9b15f7260da8f0934 Mon Sep 17 00:00:00 2001 From: Alex Robinson Date: Wed, 2 Mar 2022 15:58:04 -0600 Subject: Allow manually setting ValueDeserializer format version @@ -35,10 +35,10 @@ index 0cb3e045bc46ec732956318b980e749d1847d06d..40ad805c7970cc9379e69f046205836d * Reads raw data in various common formats to the buffer. * Note that integer types are read in base-128 varint format, not with a diff --git a/src/api/api.cc b/src/api/api.cc -index eddb472d5608567255c5f55f4ae8b451abe5f6d3..c86687981fab3ed28306ada00c9d5dff5c594377 100644 +index 5ab671c8c4168ac7ccd9d18ea4b9fda16734e4ad..eb880d8e77b80f941c6920c8f5b85896b6334cf0 100644 --- a/src/api/api.cc +++ b/src/api/api.cc -@@ -3605,6 +3605,10 @@ uint32_t ValueDeserializer::GetWireFormatVersion() const { +@@ -3603,6 +3603,10 @@ uint32_t ValueDeserializer::GetWireFormatVersion() const { return private_->deserializer.GetWireFormatVersion(); } diff --git a/patches/v8/0002-Allow-manually-setting-ValueSerializer-format-versio.patch b/patches/v8/0002-Allow-manually-setting-ValueSerializer-format-versio.patch index 3b5dd632877..e1d9cd4f9df 100644 --- a/patches/v8/0002-Allow-manually-setting-ValueSerializer-format-versio.patch +++ b/patches/v8/0002-Allow-manually-setting-ValueSerializer-format-versio.patch @@ -1,4 +1,4 @@ -From acdf8354d09cccdc782dfb00a208e3cf63d6f941 Mon Sep 17 00:00:00 2001 +From 761b74e4f5c0298dc28ea84ec27050c1503bc196 Mon Sep 17 00:00:00 2001 From: James M Snell Date: Wed, 16 Mar 2022 08:59:21 -0700 Subject: Allow manually setting ValueSerializer format version @@ -22,10 +22,10 @@ index 40ad805c7970cc9379e69f046205836dbd760373..596be18adeb3a5a81794aaa44b1d347d * Writes out a header, which includes the format version. */ diff --git a/src/api/api.cc b/src/api/api.cc -index c86687981fab3ed28306ada00c9d5dff5c594377..7058f9a13cb73cbbd0602ddeb589268306ee45ea 100644 +index eb880d8e77b80f941c6920c8f5b85896b6334cf0..6e2191ef66d5c04b99f7d314df6fb4b75de3fd7a 100644 --- a/src/api/api.cc +++ b/src/api/api.cc -@@ -3473,6 +3473,10 @@ ValueSerializer::ValueSerializer(Isolate* v8_isolate, Delegate* delegate) +@@ -3471,6 +3471,10 @@ ValueSerializer::ValueSerializer(Isolate* v8_isolate, Delegate* delegate) ValueSerializer::~ValueSerializer() { delete private_; } @@ -37,7 +37,7 @@ index c86687981fab3ed28306ada00c9d5dff5c594377..7058f9a13cb73cbbd0602ddeb5892683 void ValueSerializer::SetTreatArrayBufferViewsAsHostObjects(bool mode) { diff --git a/src/objects/value-serializer.cc b/src/objects/value-serializer.cc -index 51abbe13a599ce3a0f1b7d6fffea3abcfbfbafa4..eeb74aa42a9d783bbfdedc171717422321435c3a 100644 +index 89c0d96baff05ce3b2cf506386149c14ed81779e..f7da4eefa361807dec4a76bfaf0025299cfb6b86 100644 --- a/src/objects/value-serializer.cc +++ b/src/objects/value-serializer.cc @@ -291,6 +291,7 @@ ValueSerializer::ValueSerializer(Isolate* isolate, diff --git a/patches/v8/0003-Add-ArrayBuffer-MaybeNew.patch b/patches/v8/0003-Add-ArrayBuffer-MaybeNew.patch index 243cb9a37a3..9fce4942ff5 100644 --- a/patches/v8/0003-Add-ArrayBuffer-MaybeNew.patch +++ b/patches/v8/0003-Add-ArrayBuffer-MaybeNew.patch @@ -1,4 +1,4 @@ -From 559da3ef33b370a64e2dd8b58cb840b3e594cdbe Mon Sep 17 00:00:00 2001 +From 5f11274f4eadae25a81124d03dca88348d7c072c Mon Sep 17 00:00:00 2001 From: Kenton Varda Date: Fri, 16 Sep 2022 21:41:45 -0500 Subject: Add `ArrayBuffer::MaybeNew()`. diff --git a/patches/v8/0004-Allow-Windows-builds-under-Bazel.patch b/patches/v8/0004-Allow-Windows-builds-under-Bazel.patch index 70a9d65dcd9..19a07769abf 100644 --- a/patches/v8/0004-Allow-Windows-builds-under-Bazel.patch +++ b/patches/v8/0004-Allow-Windows-builds-under-Bazel.patch @@ -1,14 +1,14 @@ -From 7958c73efccb179171fcf9072a179f6b1aa67e24 Mon Sep 17 00:00:00 2001 +From 9fa08868bc3ef667fbe0c1d4922bdd2f8f43acfa Mon Sep 17 00:00:00 2001 From: Brendan Coll Date: Thu, 16 Mar 2023 11:56:10 +0000 Subject: Allow Windows builds under Bazel diff --git a/BUILD.bazel b/BUILD.bazel -index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2dfe2c9ab48 100644 +index f2b2f4da0f8164ef29e36a3d1e9489b8e9c7b86e..84a281458aaa18525fa3640b3710414153e008b1 100644 --- a/BUILD.bazel +++ b/BUILD.bazel -@@ -817,6 +817,7 @@ filegroup( +@@ -820,6 +820,7 @@ filegroup( "src/base/platform/mutex.h", "src/base/platform/platform.cc", "src/base/platform/platform.h", @@ -16,7 +16,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df "src/base/platform/semaphore.cc", "src/base/platform/semaphore.h", "src/base/platform/time.cc", -@@ -860,7 +861,6 @@ filegroup( +@@ -863,7 +864,6 @@ filegroup( ] + select({ "@v8//bazel/config:is_posix": [ "src/base/platform/platform-posix.cc", @@ -24,7 +24,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df "src/base/platform/platform-posix-time.cc", "src/base/platform/platform-posix-time.h", ], -@@ -883,6 +883,7 @@ filegroup( +@@ -886,6 +886,7 @@ filegroup( "@v8//bazel/config:is_windows": [ "src/base/debug/stack_trace_win.cc", "src/base/platform/platform-win32.cc", @@ -32,7 +32,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df "src/base/win32-headers.h", ], }), -@@ -1265,6 +1266,7 @@ filegroup( +@@ -1268,6 +1269,7 @@ filegroup( "include/v8-wasm-trap-handler-posix.h", "src/api/api.cc", "src/api/api.h", @@ -40,7 +40,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df "src/api/api-arguments.cc", "src/api/api-arguments.h", "src/api/api-arguments-inl.h", -@@ -2739,6 +2741,11 @@ filegroup( +@@ -2741,6 +2743,11 @@ filegroup( "src/trap-handler/handler-inside-posix.cc", "src/trap-handler/handler-outside-posix.cc", ], @@ -52,7 +52,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df "//conditions:default": [], }) + select({ "@v8//bazel/config:v8_arm64_simulator": [ -@@ -2746,13 +2753,6 @@ filegroup( +@@ -2748,13 +2755,6 @@ filegroup( "src/trap-handler/trap-handler-simulator.h", ], "//conditions:default": [], @@ -66,7 +66,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df }) + select({ "@v8//bazel/config:is_windows_64bit": [ "src/diagnostics/unwinding-info-win64.cc", -@@ -3805,6 +3805,9 @@ filegroup( +@@ -3793,6 +3793,9 @@ filegroup( "@v8//bazel/config:is_msvc_asm_ia32": ["src/heap/base/asm/ia32/push_registers_masm.asm"], "@v8//bazel/config:is_msvc_asm_x64": ["src/heap/base/asm/x64/push_registers_masm.asm"], "@v8//bazel/config:is_msvc_asm_arm64": ["src/heap/base/asm/arm64/push_registers_masm.S"], @@ -76,7 +76,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df }), ) -@@ -4201,9 +4204,11 @@ filegroup( +@@ -4170,9 +4173,11 @@ filegroup( "src/d8/d8-js.cc", "src/d8/d8-platforms.cc", "src/d8/d8-platforms.h", @@ -90,7 +90,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df ) genrule( -@@ -4554,7 +4559,7 @@ py_test( +@@ -4522,7 +4527,7 @@ py_test( ":noicu/d8", ":noicu/v8_build_config", "//testing/pybase", @@ -99,7 +99,7 @@ index 1f269f9c149e56a7098697fc2346b5998b0c6e01..89bc2f54fc5e42a2cf6d6fa41742c2df main = "tools/run-tests.py", python_version = "PY3", tags = [ -@@ -4593,7 +4598,7 @@ py_test( +@@ -4561,7 +4566,7 @@ py_test( ":icu/d8", ":icu/v8_build_config", "//testing/pybase", @@ -178,7 +178,7 @@ index c81f278203126913c3bad74d31348706678ccf06..96e0f9cdb61d0d8f6597d337c2dd965b name = "is_clang", match_any = [ diff --git a/bazel/defs.bzl b/bazel/defs.bzl -index ba1716d9ad466a1a7a0a8976631c6a82cad9b894..cda9c55baefe428bd85b8d98dbf475d07e9c4307 100644 +index 6a3c868b002142754cbfa671e1d30a1459d32f92..7ab09f062fd0d9bad3785836cdaa2c8be789e0f2 100644 --- a/bazel/defs.bzl +++ b/bazel/defs.bzl @@ -119,6 +119,24 @@ def _default_args(): diff --git a/patches/v8/0005-Disable-bazel-whole-archive-build.patch b/patches/v8/0005-Disable-bazel-whole-archive-build.patch index 93f5c7aa09e..7307d844e0c 100644 --- a/patches/v8/0005-Disable-bazel-whole-archive-build.patch +++ b/patches/v8/0005-Disable-bazel-whole-archive-build.patch @@ -1,4 +1,4 @@ -From 2e5ab7c0faa7ea01c8f3159540d9d563ebed2cdd Mon Sep 17 00:00:00 2001 +From 4dd002f20f669a7b845e8a73e82997eb6e02d0e2 Mon Sep 17 00:00:00 2001 From: Felix Hanau Date: Tue, 11 Apr 2023 14:41:31 -0400 Subject: Disable bazel whole-archive build diff --git a/patches/v8/0006-Speed-up-V8-bazel-build-by-always-using-target-cfg.patch b/patches/v8/0006-Speed-up-V8-bazel-build-by-always-using-target-cfg.patch index da5d6a09ed8..da7ccb9f0a9 100644 --- a/patches/v8/0006-Speed-up-V8-bazel-build-by-always-using-target-cfg.patch +++ b/patches/v8/0006-Speed-up-V8-bazel-build-by-always-using-target-cfg.patch @@ -1,4 +1,4 @@ -From 9bca82fb298ec759a04383fc830827eaf205ccbd Mon Sep 17 00:00:00 2001 +From de23c2346084629d63b6d620a4a0a70fd9a9390a Mon Sep 17 00:00:00 2001 From: Felix Hanau Date: Wed, 7 Jun 2023 21:40:54 -0400 Subject: Speed up V8 bazel build by always using target cfg @@ -12,7 +12,7 @@ generated files as the output set. While unrelated to the build cfg change, this also improves build times. diff --git a/BUILD.bazel b/BUILD.bazel -index 89bc2f54fc5e42a2cf6d6fa41742c2dfe2c9ab48..675c36f7784409f10b28b6fca93d4fd39f69a17d 100644 +index 84a281458aaa18525fa3640b3710414153e008b1..55eaca3189c6b9464c2a0a795efea9bdc83ab8da 100644 --- a/BUILD.bazel +++ b/BUILD.bazel @@ -17,6 +17,7 @@ load( @@ -23,7 +23,7 @@ index 89bc2f54fc5e42a2cf6d6fa41742c2dfe2c9ab48..675c36f7784409f10b28b6fca93d4fd3 ) load(":bazel/v8-non-pointer-compression.bzl", "v8_binary_non_pointer_compression") -@@ -4211,22 +4212,20 @@ filegroup( +@@ -4180,22 +4181,20 @@ filegroup( }), ) @@ -52,7 +52,7 @@ index 89bc2f54fc5e42a2cf6d6fa41742c2dfe2c9ab48..675c36f7784409f10b28b6fca93d4fd3 ) v8_mksnapshot( -@@ -4427,8 +4426,6 @@ v8_binary( +@@ -4395,8 +4394,6 @@ v8_binary( srcs = [ "src/regexp/gen-regexp-special-case.cc", "src/regexp/special-case.h", @@ -61,7 +61,7 @@ index 89bc2f54fc5e42a2cf6d6fa41742c2dfe2c9ab48..675c36f7784409f10b28b6fca93d4fd3 ], copts = ["-Wno-implicit-fallthrough"], defines = [ -@@ -4440,6 +4437,7 @@ v8_binary( +@@ -4408,6 +4405,7 @@ v8_binary( ], deps = [ "//external:absl_optional", @@ -70,7 +70,7 @@ index 89bc2f54fc5e42a2cf6d6fa41742c2dfe2c9ab48..675c36f7784409f10b28b6fca93d4fd3 ], ) diff --git a/bazel/defs.bzl b/bazel/defs.bzl -index cda9c55baefe428bd85b8d98dbf475d07e9c4307..658b44b7deca596ef8ea5b178b2d51b0d06820d3 100644 +index 7ab09f062fd0d9bad3785836cdaa2c8be789e0f2..bb75ea080ed4a4e441e212b067c27b6d9316f81c 100644 --- a/bazel/defs.bzl +++ b/bazel/defs.bzl @@ -340,6 +340,15 @@ def v8_library( diff --git a/patches/v8/0007-Implement-Promise-Context-Tagging.patch b/patches/v8/0007-Implement-Promise-Context-Tagging.patch index d7566277fa1..c794185004c 100644 --- a/patches/v8/0007-Implement-Promise-Context-Tagging.patch +++ b/patches/v8/0007-Implement-Promise-Context-Tagging.patch @@ -1,14 +1,14 @@ -From c0e541c6f29fc25fc4641f6e182db277f62702c7 Mon Sep 17 00:00:00 2001 +From 6c6d8355d7070125e930f1ff0b1533572916076c Mon Sep 17 00:00:00 2001 From: Erik Corry Date: Wed, 21 Aug 2024 16:29:43 +0200 Subject: Implement Promise Context Tagging diff --git a/include/v8-callbacks.h b/include/v8-callbacks.h -index 567b36faf63ddb758ae402dc0d47b5596b7f93ac..6add89ac1837df03a71539801ab513e098e73722 100644 +index 7a8f8abeb402d93f0089e1e54b0e211096f1c2dd..25f0c8189e5c0102b26bfd0827f375d9910849cd 100644 --- a/include/v8-callbacks.h +++ b/include/v8-callbacks.h -@@ -454,6 +454,15 @@ using FilterETWSessionByURLCallback = +@@ -462,6 +462,15 @@ using FilterETWSessionByURLCallback = bool (*)(Local context, const std::string& etw_filter_payload); #endif // V8_OS_WIN @@ -25,10 +25,10 @@ index 567b36faf63ddb758ae402dc0d47b5596b7f93ac..6add89ac1837df03a71539801ab513e0 #endif // INCLUDE_V8_ISOLATE_CALLBACKS_H_ diff --git a/include/v8-isolate.h b/include/v8-isolate.h -index 54571391fb8227e7d5feb63c219f396a5d39e6f2..96b7d9feb20d4ef1b5ba2da56d9635688da2457c 100644 +index 08fcfc40f1f46e5867a7d9a1384d246d9422ddce..8112231319b309cdb96c59896fc0f48bcf920e96 100644 --- a/include/v8-isolate.h +++ b/include/v8-isolate.h -@@ -1731,6 +1731,9 @@ class V8_EXPORT Isolate { +@@ -1730,6 +1730,9 @@ class V8_EXPORT Isolate { */ std::string GetDefaultLocale(); @@ -38,7 +38,7 @@ index 54571391fb8227e7d5feb63c219f396a5d39e6f2..96b7d9feb20d4ef1b5ba2da56d963568 Isolate() = delete; ~Isolate() = delete; Isolate(const Isolate&) = delete; -@@ -1775,6 +1778,19 @@ MaybeLocal Isolate::GetDataFromSnapshotOnce(size_t index) { +@@ -1774,6 +1777,19 @@ MaybeLocal Isolate::GetDataFromSnapshotOnce(size_t index) { return {}; } @@ -59,10 +59,10 @@ index 54571391fb8227e7d5feb63c219f396a5d39e6f2..96b7d9feb20d4ef1b5ba2da56d963568 #endif // INCLUDE_V8_ISOLATE_H_ diff --git a/src/api/api.cc b/src/api/api.cc -index 7058f9a13cb73cbbd0602ddeb589268306ee45ea..806357781fd97bb4767b2120bc5cc20607e86f07 100644 +index 6e2191ef66d5c04b99f7d314df6fb4b75de3fd7a..8d4e6dee69b355baaadd3e144c7514e55dd88907 100644 --- a/src/api/api.cc +++ b/src/api/api.cc -@@ -12236,6 +12236,23 @@ std::string SourceLocation::ToString() const { +@@ -12235,6 +12235,23 @@ std::string SourceLocation::ToString() const { return std::string(function_) + "@" + file_ + ":" + std::to_string(line_); } @@ -87,7 +87,7 @@ index 7058f9a13cb73cbbd0602ddeb589268306ee45ea..806357781fd97bb4767b2120bc5cc206 EXPORT_CONTEXTUAL_VARIABLE(v8::internal::StackAllocatedCheck) diff --git a/src/builtins/promise-abstract-operations.tq b/src/builtins/promise-abstract-operations.tq -index f4e17456651516dfb3e81880da82ab228646ccfd..6142e0450dac646ccebd3fc7c5168f9b42b4d0b5 100644 +index 8866a39c8ab47eedee928aea48b853eb4076cd90..fdec3d268e4e3d181d6c092bbb19a40cdf8dde57 100644 --- a/src/builtins/promise-abstract-operations.tq +++ b/src/builtins/promise-abstract-operations.tq @@ -20,6 +20,9 @@ extern transitioning runtime PromiseResolveAfterResolved( @@ -100,7 +100,7 @@ index f4e17456651516dfb3e81880da82ab228646ccfd..6142e0450dac646ccebd3fc7c5168f9b } // https://tc39.es/ecma262/#sec-promise-abstract-operations -@@ -457,12 +460,14 @@ transitioning macro PerformPromiseThenImpl( +@@ -456,12 +459,14 @@ transitioning macro PerformPromiseThenImpl( // PromiseReaction holding both the onFulfilled and onRejected callbacks. // Once the {promise} is resolved we decide on the concrete handler to // push onto the microtask queue. @@ -117,7 +117,7 @@ index f4e17456651516dfb3e81880da82ab228646ccfd..6142e0450dac646ccebd3fc7c5168f9b } else { const reactionsOrResult = promise.reactions_or_result; let microtask: PromiseReactionJobTask; -@@ -484,8 +489,8 @@ transitioning macro PerformPromiseThenImpl( +@@ -483,8 +488,8 @@ transitioning macro PerformPromiseThenImpl( } } EnqueueMicrotask(handlerContext, microtask); @@ -126,7 +126,7 @@ index f4e17456651516dfb3e81880da82ab228646ccfd..6142e0450dac646ccebd3fc7c5168f9b - promise.SetHasHandler(); } - transitioning javascript builtin PerformPromiseThenFunction( + // https://tc39.es/ecma262/#sec-performpromisethen diff --git a/src/builtins/promise-constructor.tq b/src/builtins/promise-constructor.tq index 7ace785675fe1b8ae005a1c38f9c0c32e41ac7f3..88efee16b51a6e26bd20fc4ed1222091cac8670b 100644 --- a/src/builtins/promise-constructor.tq @@ -150,26 +150,26 @@ index 7ace785675fe1b8ae005a1c38f9c0c32e41ac7f3..88efee16b51a6e26bd20fc4ed1222091 } diff --git a/src/builtins/promise-misc.tq b/src/builtins/promise-misc.tq -index 1f90230bcafe424b2260598906cc7586f5406848..44ff23634e5a91498736fa2a15b324b23f6abde5 100644 +index 8accbc33c6872bee1533897a8a846d0456ecf79f..6b409b806468ae0dd9007cb1ac82e546aa6f652f 100644 --- a/src/builtins/promise-misc.tq +++ b/src/builtins/promise-misc.tq -@@ -55,6 +55,7 @@ macro PromiseInit(promise: JSPromise): void { +@@ -52,6 +52,7 @@ macro PromiseInit(promise: JSPromise): void { is_silent: false, - async_task_id: kInvalidAsyncTaskId + async_task_id: 0 }); + promise.context_tag = kZero; promise_internal::ZeroOutEmbedderOffsets(promise); } -@@ -74,6 +75,7 @@ macro InnerNewJSPromise(implicit context: Context)(): JSPromise { +@@ -71,6 +72,7 @@ macro InnerNewJSPromise(implicit context: Context)(): JSPromise { is_silent: false, - async_task_id: kInvalidAsyncTaskId + async_task_id: 0 }); + promise.context_tag = kZero; return promise; } -@@ -273,6 +275,7 @@ transitioning macro NewJSPromise(implicit context: Context)(parent: Object): +@@ -270,6 +272,7 @@ transitioning macro NewJSPromise(implicit context: Context)(parent: Object): JSPromise { const instance = InnerNewJSPromise(); PromiseInit(instance); @@ -177,7 +177,7 @@ index 1f90230bcafe424b2260598906cc7586f5406848..44ff23634e5a91498736fa2a15b324b2 RunAnyPromiseHookInit(instance, parent); return instance; } -@@ -296,6 +299,7 @@ transitioning macro NewJSPromise( +@@ -293,6 +296,7 @@ transitioning macro NewJSPromise( instance.reactions_or_result = result; instance.SetStatus(status); promise_internal::ZeroOutEmbedderOffsets(instance); @@ -186,10 +186,10 @@ index 1f90230bcafe424b2260598906cc7586f5406848..44ff23634e5a91498736fa2a15b324b2 return instance; } diff --git a/src/compiler/js-create-lowering.cc b/src/compiler/js-create-lowering.cc -index c8b5eade2b55ac6f09c49bdef24553e0a1dd57d6..180a510241685b469ca25f59ce4b2d2f506cad78 100644 +index cb7613c4eed992a519e70e1501c88ecc43a230fe..780f4a1d3d9645a840bea156246d7259b04be78b 100644 --- a/src/compiler/js-create-lowering.cc +++ b/src/compiler/js-create-lowering.cc -@@ -1115,10 +1115,12 @@ Reduction JSCreateLowering::ReduceJSCreatePromise(Node* node) { +@@ -1108,10 +1108,12 @@ Reduction JSCreateLowering::ReduceJSCreatePromise(Node* node) { jsgraph()->EmptyFixedArrayConstant()); a.Store(AccessBuilder::ForJSObjectOffset(JSPromise::kReactionsOrResultOffset), jsgraph()->ZeroConstant()); @@ -204,7 +204,7 @@ index c8b5eade2b55ac6f09c49bdef24553e0a1dd57d6..180a510241685b469ca25f59ce4b2d2f offset < JSPromise::kSizeWithEmbedderFields; offset += kTaggedSize) { a.Store(AccessBuilder::ForJSObjectOffset(offset), diff --git a/src/diagnostics/objects-printer.cc b/src/diagnostics/objects-printer.cc -index ebf2796dde4fdcc1d5a12feec6cdb3b70a98bf44..d98914e3297a79769800d0652329fb6a582e8e6a 100644 +index 3fb40e6ea6a1112d86f4dfaf0182cfad5a9e27d4..b069293ad8acd9d6403a2bb6ad2016a774f56fd5 100644 --- a/src/diagnostics/objects-printer.cc +++ b/src/diagnostics/objects-printer.cc @@ -846,6 +846,7 @@ void JSPromise::JSPromisePrint(std::ostream& os) { @@ -247,10 +247,10 @@ index f81666ddd2f513a9a1f39b9e486b451bf3c7574d..9e0969460fd33d8cc893e04d3418e1cb Tagged Isolate::VerifyBuiltinsResult(Tagged result) { if (is_execution_terminating() && !v8_flags.strict_termination_checks) { diff --git a/src/execution/isolate.cc b/src/execution/isolate.cc -index 92913cf54d576fff94cad992b12a72698edc7788..20f371a3cd2717eee242d3faab8ddf040b0ec034 100644 +index 40303fb7ecfee5fd84462c80da715d923a90efdf..dab3359645835636a4ab0f1a1fc35706b1aa3d3c 100644 --- a/src/execution/isolate.cc +++ b/src/execution/isolate.cc -@@ -599,6 +599,8 @@ void Isolate::Iterate(RootVisitor* v, ThreadLocalTop* thread) { +@@ -593,6 +593,8 @@ void Isolate::Iterate(RootVisitor* v, ThreadLocalTop* thread) { FullObjectSlot(&thread->pending_message_)); v->VisitRootPointer(Root::kStackRoots, nullptr, FullObjectSlot(&thread->context_)); @@ -259,7 +259,7 @@ index 92913cf54d576fff94cad992b12a72698edc7788..20f371a3cd2717eee242d3faab8ddf04 for (v8::TryCatch* block = thread->try_catch_handler_; block != nullptr; block = block->next_) { -@@ -5581,6 +5583,7 @@ bool Isolate::Init(SnapshotData* startup_snapshot_data, +@@ -5575,6 +5577,7 @@ bool Isolate::Init(SnapshotData* startup_snapshot_data, shared_heap_object_cache_.push_back(ReadOnlyRoots(this).undefined_value()); } @@ -267,7 +267,7 @@ index 92913cf54d576fff94cad992b12a72698edc7788..20f371a3cd2717eee242d3faab8ddf04 InitializeThreadLocal(); // Profiler has to be created after ThreadLocal is initialized -@@ -7472,5 +7475,39 @@ void Isolate::InitializeBuiltinJSDispatchTable() { +@@ -7447,5 +7450,39 @@ void Isolate::InitializeBuiltinJSDispatchTable() { #endif } @@ -308,10 +308,10 @@ index 92913cf54d576fff94cad992b12a72698edc7788..20f371a3cd2717eee242d3faab8ddf04 } // namespace internal } // namespace v8 diff --git a/src/execution/isolate.h b/src/execution/isolate.h -index d6060d7068ee3820eace6b3a7a015108d65960b5..7de738063bdddead3762aded57fbbd388eef950f 100644 +index 7be3714d23d84241128aa08059a741fc593012a0..c12c69fcc193ae2622d1698cf79704d58d939231 100644 --- a/src/execution/isolate.h +++ b/src/execution/isolate.h -@@ -2266,6 +2266,14 @@ class V8_EXPORT_PRIVATE Isolate final : private HiddenFactory { +@@ -2250,6 +2250,14 @@ class V8_EXPORT_PRIVATE Isolate final : private HiddenFactory { v8::ExceptionContext callback_kind); void SetExceptionPropagationCallback(ExceptionPropagationCallback callback); @@ -326,7 +326,7 @@ index d6060d7068ee3820eace6b3a7a015108d65960b5..7de738063bdddead3762aded57fbbd38 #ifdef V8_ENABLE_WASM_SIMD256_REVEC void set_wasm_revec_verifier_for_test( compiler::turboshaft::WasmRevecVerifier* verifier) { -@@ -2778,12 +2786,19 @@ class V8_EXPORT_PRIVATE Isolate final : private HiddenFactory { +@@ -2761,12 +2769,19 @@ class V8_EXPORT_PRIVATE Isolate final : private HiddenFactory { int current_thread_counter_ = 0; #endif @@ -347,10 +347,10 @@ index d6060d7068ee3820eace6b3a7a015108d65960b5..7de738063bdddead3762aded57fbbd38 // The current entered Isolate and its thread data. Do not access these diff --git a/src/heap/factory.cc b/src/heap/factory.cc -index e26d18c63693bb89f38c79780df5836f1540fbe0..1d631dde7b3234f6d3639a8f49410e908126f6d6 100644 +index 4ef611e8d84ebf700d62bb9977b2aab3db9b2bfb..c0c46447c2f55325885ce33e7aa45cd011eac5ad 100644 --- a/src/heap/factory.cc +++ b/src/heap/factory.cc -@@ -4429,6 +4429,12 @@ Handle Factory::NewJSPromiseWithoutHook() { +@@ -4415,6 +4415,12 @@ Handle Factory::NewJSPromiseWithoutHook() { DisallowGarbageCollection no_gc; Tagged raw = *promise; raw->set_reactions_or_result(Smi::zero(), SKIP_WRITE_BARRIER); @@ -364,7 +364,7 @@ index e26d18c63693bb89f38c79780df5836f1540fbe0..1d631dde7b3234f6d3639a8f49410e90 // TODO(v8) remove once embedder data slots are always zero-initialized. InitEmbedderFields(*promise, Smi::zero()); diff --git a/src/objects/js-promise.tq b/src/objects/js-promise.tq -index 93a4a34f9f1f7fad40611d4b9432aaf944c9fbae..188619ea64c9e307f014898e4023ce796c52c7e2 100644 +index 29acfa259048f1dae2dfcb02ef57ca4ef69e2d9a..1c137d27219afe1298326604a5d172b49810a1c1 100644 --- a/src/objects/js-promise.tq +++ b/src/objects/js-promise.tq @@ -32,6 +32,7 @@ extern class JSPromise extends JSObjectWithEmbedderSlots { @@ -376,10 +376,10 @@ index 93a4a34f9f1f7fad40611d4b9432aaf944c9fbae..188619ea64c9e307f014898e4023ce79 } diff --git a/src/profiler/heap-snapshot-generator.cc b/src/profiler/heap-snapshot-generator.cc -index 5b7a1fe859f252ec03d42bb9eb7ab438e0b6a6d7..1671f284c8439d6eeff757f927ae62de9e90c1e5 100644 +index 7e2089e1f1abbd34093427bfd995ab90acbf4d54..b7d753ee3bce2df2e8896eabbc64d837b12841ef 100644 --- a/src/profiler/heap-snapshot-generator.cc +++ b/src/profiler/heap-snapshot-generator.cc -@@ -1936,6 +1936,9 @@ void V8HeapExplorer::ExtractJSPromiseReferences(HeapEntry* entry, +@@ -1911,6 +1911,9 @@ void V8HeapExplorer::ExtractJSPromiseReferences(HeapEntry* entry, SetInternalReference(entry, "reactions_or_result", promise->reactions_or_result(), JSPromise::kReactionsOrResultOffset); @@ -435,10 +435,10 @@ index 20ba437b34afd13bc0e43e87785544160b5c109b..4fbdf90319c5fc3b3e6f60aaf1b12a33 } // namespace internal } // namespace v8 diff --git a/src/runtime/runtime.h b/src/runtime/runtime.h -index 6088fced3a07b63a008b1d8b20597c8f12e06aa8..d23446cbeee65b50cab694dc60743b4ab7f9c1d7 100644 +index 56c685d3c2d4f18e8455ee8e84e4741aeff3d92c..9399509f6903e392175c2b14a1dd97feaad1c526 100644 --- a/src/runtime/runtime.h +++ b/src/runtime/runtime.h -@@ -403,7 +403,9 @@ namespace internal { +@@ -401,7 +401,9 @@ namespace internal { F(PromiseResolveAfterResolved, 2, 1) \ F(ConstructSuppressedError, 3, 1) \ F(ConstructAggregateErrorHelper, 4, 1) \ diff --git a/patches/v8/0008-Enable-V8-shared-linkage.patch b/patches/v8/0008-Enable-V8-shared-linkage.patch index 9c31f3b5b73..a2e8604898e 100644 --- a/patches/v8/0008-Enable-V8-shared-linkage.patch +++ b/patches/v8/0008-Enable-V8-shared-linkage.patch @@ -1,22 +1,14 @@ -From 0815526f4a4f533ef4ce76d763db568e50811dfd Mon Sep 17 00:00:00 2001 +From 80b4aff91f274adfaddc8acdee4318764e92a065 Mon Sep 17 00:00:00 2001 From: Felix Hanau Date: Sun, 9 Jul 2023 18:46:20 -0400 Subject: Enable V8 shared linkage diff --git a/BUILD.bazel b/BUILD.bazel -index 675c36f7784409f10b28b6fca93d4fd39f69a17d..634faf34baceefc8a08f953777eecdabfa9d1b73 100644 +index 55eaca3189c6b9464c2a0a795efea9bdc83ab8da..4a831b0d190ea85eebb7796a1bc9bb5eae3a13ea 100644 --- a/BUILD.bazel +++ b/BUILD.bazel -@@ -1359,6 +1359,7 @@ filegroup( - "src/builtins/constants-table-builder.cc", - "src/builtins/constants-table-builder.h", - "src/builtins/data-view-ops.h", -+ "src/builtins/profile-data-reader.cc", - "src/builtins/profile-data-reader.h", - "src/codegen/aligned-slot-allocator.cc", - "src/codegen/aligned-slot-allocator.h", -@@ -1539,7 +1540,6 @@ filegroup( +@@ -1542,7 +1542,6 @@ filegroup( "src/execution/futex-emulation.h", "src/execution/interrupts-scope.cc", "src/execution/interrupts-scope.h", @@ -24,52 +16,28 @@ index 675c36f7784409f10b28b6fca93d4fd39f69a17d..634faf34baceefc8a08f953777eecdab "src/execution/isolate.h", "src/execution/isolate-data.h", "src/execution/isolate-inl.h", -@@ -3040,7 +3040,6 @@ filegroup( - filegroup( - name = "v8_compiler_files", - srcs = [ -- "src/builtins/profile-data-reader.h", - "src/compiler/access-builder.cc", - "src/compiler/access-builder.h", - "src/compiler/access-info.cc", -@@ -3616,8 +3615,6 @@ filegroup( - "src/builtins/growable-fixed-array-gen.cc", - "src/builtins/growable-fixed-array-gen.h", - "src/builtins/number-builtins-reducer-inl.h", -- "src/builtins/profile-data-reader.cc", -- "src/builtins/profile-data-reader.h", - "src/builtins/setup-builtins-internal.cc", - "src/builtins/torque-csa-header-includes.h", - "src/codegen/turboshaft-builtins-assembler-inl.h", -@@ -3891,6 +3888,7 @@ filegroup( +@@ -3860,6 +3859,10 @@ filegroup( "src/snapshot/snapshot-empty.cc", "src/snapshot/static-roots-gen.cc", "src/snapshot/static-roots-gen.h", ++ # file moved here to make dynamic linkage possible. Keeping it in the v8 base causes issues ++ # with dynamic linking as it depends on symbols only defined in the snapshot (or through a ++ # placeholder when building the snapshot itself). + "src/execution/isolate.cc", ], ) -@@ -4003,6 +4001,10 @@ filegroup( - name = "noicu/snapshot_files", - srcs = [ - "src/init/setup-isolate-deserialize.cc", -+ # Not a snapshot file per se, but depends on symbols only present in the snapshot (or -+ # through a placeholder when building the snapshot itself); having it here makes using -+ # shared linkage for the main v8 target possible. -+ "src/execution/isolate.cc", - ] + select({ - "@v8//bazel/config:v8_target_arm": [ - "google3/snapshots/arm/noicu/embedded.S", -@@ -4020,6 +4022,7 @@ filegroup( - name = "icu/snapshot_files", +@@ -4315,6 +4318,8 @@ v8_library( + name = "v8", srcs = [ - "src/init/setup-isolate-deserialize.cc", + ":v8_inspector_files", ++ # file moved here to make dynamic linkage possible. + "src/execution/isolate.cc", ] + select({ - "@v8//bazel/config:v8_target_arm": [ - "google3/snapshots/arm/icu/embedded.S", + ":is_not_v8_enable_turbofan": [ + # With Turbofan disabled, we only include the stubbed-out API. diff --git a/bazel/defs.bzl b/bazel/defs.bzl -index 658b44b7deca596ef8ea5b178b2d51b0d06820d3..7181784539ecc548cacc09eab33f168fec9f1116 100644 +index bb75ea080ed4a4e441e212b067c27b6d9316f81c..78079ecf921f9eb22dda8ce6c208e9a510e8a224 100644 --- a/bazel/defs.bzl +++ b/bazel/defs.bzl @@ -297,7 +297,6 @@ def v8_library( diff --git a/patches/v8/0009-Randomize-the-initial-ExecutionContextId-used-by-the.patch b/patches/v8/0009-Randomize-the-initial-ExecutionContextId-used-by-the.patch index c3648888f02..2b809d68124 100644 --- a/patches/v8/0009-Randomize-the-initial-ExecutionContextId-used-by-the.patch +++ b/patches/v8/0009-Randomize-the-initial-ExecutionContextId-used-by-the.patch @@ -1,4 +1,4 @@ -From d301937540aa091ca93bd7330b62461e5bdcb9be Mon Sep 17 00:00:00 2001 +From ca59160215b6cbc3d8279b0b1ef26d8e8aac0e35 Mon Sep 17 00:00:00 2001 From: Orion Hodson Date: Wed, 13 Sep 2023 15:38:15 +0100 Subject: Randomize the initial ExecutionContextId used by the inspector diff --git a/patches/v8/0010-increase-visibility-of-virtual-method.patch b/patches/v8/0010-increase-visibility-of-virtual-method.patch index 078a6ea3a56..c72b2a8957b 100644 --- a/patches/v8/0010-increase-visibility-of-virtual-method.patch +++ b/patches/v8/0010-increase-visibility-of-virtual-method.patch @@ -1,4 +1,4 @@ -From 0d83a2f696b4390a0f32d11acf3108c924faa421 Mon Sep 17 00:00:00 2001 +From c7028cbc6d345c18d120224177c1017db74a1eaa Mon Sep 17 00:00:00 2001 From: Mike Aizatsky Date: Tue, 6 Feb 2024 12:55:07 -0800 Subject: increase visibility of virtual method @@ -7,10 +7,10 @@ Methods were marked as protected, which conflicts with v8-platform-wrapper.h implementation. diff --git a/include/v8-platform.h b/include/v8-platform.h -index a3a939729c9b14b76ae70d6b9f8b8d4501047e89..d422ebf72bce3ceda0c8ee94c7e7fdf8ba06d816 100644 +index 5110f432077dce9770319373aec4988be1eaff59..6fb67c8c77b0d6adcc6b294230d4488a0fef9bc5 100644 --- a/include/v8-platform.h +++ b/include/v8-platform.h -@@ -1314,7 +1314,7 @@ class Platform { +@@ -1308,7 +1308,7 @@ class Platform { return &default_observer; } diff --git a/patches/v8/0011-Add-ValueSerializer-SetTreatFunctionsAsHostObjects.patch b/patches/v8/0011-Add-ValueSerializer-SetTreatFunctionsAsHostObjects.patch index f6b03f61a7d..4796c18314a 100644 --- a/patches/v8/0011-Add-ValueSerializer-SetTreatFunctionsAsHostObjects.patch +++ b/patches/v8/0011-Add-ValueSerializer-SetTreatFunctionsAsHostObjects.patch @@ -1,4 +1,4 @@ -From 0d366ecab2c5c6044c8d4670ddbf7011c3307f50 Mon Sep 17 00:00:00 2001 +From b0e06ebe97033ab1da993e3384513437409ec2ac Mon Sep 17 00:00:00 2001 From: Kenton Varda Date: Sat, 2 Mar 2024 09:00:18 -0600 Subject: Add ValueSerializer::SetTreatFunctionsAsHostObjects(). @@ -28,10 +28,10 @@ index 596be18adeb3a5a81794aaa44b1d347dec6c0c7d..141f138e08de849e3e02b3b2b346e643 * Write raw data in various common formats to the buffer. * Note that integer types are written in base-128 varint format, not with a diff --git a/src/api/api.cc b/src/api/api.cc -index 806357781fd97bb4767b2120bc5cc20607e86f07..e34f21cb6082f2a3cf506e4f75a63b1718d8759e 100644 +index 8d4e6dee69b355baaadd3e144c7514e55dd88907..8db94796eb44db416f38fb5488ea4c83eeec1bf0 100644 --- a/src/api/api.cc +++ b/src/api/api.cc -@@ -3483,6 +3483,10 @@ void ValueSerializer::SetTreatArrayBufferViewsAsHostObjects(bool mode) { +@@ -3481,6 +3481,10 @@ void ValueSerializer::SetTreatArrayBufferViewsAsHostObjects(bool mode) { private_->serializer.SetTreatArrayBufferViewsAsHostObjects(mode); } @@ -43,7 +43,7 @@ index 806357781fd97bb4767b2120bc5cc20607e86f07..e34f21cb6082f2a3cf506e4f75a63b17 Local value) { auto i_isolate = reinterpret_cast(context->GetIsolate()); diff --git a/src/objects/value-serializer.cc b/src/objects/value-serializer.cc -index eeb74aa42a9d783bbfdedc171717422321435c3a..050c30e92281c9e473db923599edb38f99d15836 100644 +index f7da4eefa361807dec4a76bfaf0025299cfb6b86..32441451d4d5c05484dd0a68ff8baea2a9283140 100644 --- a/src/objects/value-serializer.cc +++ b/src/objects/value-serializer.cc @@ -328,6 +328,10 @@ void ValueSerializer::SetTreatArrayBufferViewsAsHostObjects(bool mode) { diff --git a/patches/v8/0012-Set-torque-generator-path-to-external-v8.-This-allow.patch b/patches/v8/0012-Set-torque-generator-path-to-external-v8.-This-allow.patch index 3e2b62c62a1..dd10ed0585b 100644 --- a/patches/v8/0012-Set-torque-generator-path-to-external-v8.-This-allow.patch +++ b/patches/v8/0012-Set-torque-generator-path-to-external-v8.-This-allow.patch @@ -1,4 +1,4 @@ -From e87ce0046ef3b99670fc1eb15a78899467d0f2b7 Mon Sep 17 00:00:00 2001 +From 83b235a7506a132606e6161df7ce31b231de56ce Mon Sep 17 00:00:00 2001 From: Garrett Gu Date: Wed, 10 Apr 2024 14:31:33 -0500 Subject: Set torque generator path to external/v8. This allows bazel to find @@ -8,7 +8,7 @@ Subject: Set torque generator path to external/v8. This allows bazel to find See https://chromium-review.googlesource.com/c/v8/v8/+/5339896 diff --git a/bazel/defs.bzl b/bazel/defs.bzl -index 7181784539ecc548cacc09eab33f168fec9f1116..70a1d221145d044a2df814d2de9428f3bca8f07b 100644 +index 78079ecf921f9eb22dda8ce6c208e9a510e8a224..5da50d5b863f96b77add82b3e50a1492f0516a66 100644 --- a/bazel/defs.bzl +++ b/bazel/defs.bzl @@ -350,7 +350,7 @@ def get_cfg(): diff --git a/patches/v8/0013-Modify-where-to-look-for-fp16-dependency.-This-depen.patch b/patches/v8/0013-Modify-where-to-look-for-fp16-dependency.-This-depen.patch index c4272690a55..b5631d4553c 100644 --- a/patches/v8/0013-Modify-where-to-look-for-fp16-dependency.-This-depen.patch +++ b/patches/v8/0013-Modify-where-to-look-for-fp16-dependency.-This-depen.patch @@ -1,4 +1,4 @@ -From 806d4c63a395e302a9748da731da96e719b282eb Mon Sep 17 00:00:00 2001 +From 19c8be4351aa13c2610b1fda92f774acdd1ddc89 Mon Sep 17 00:00:00 2001 From: Garrett Gu Date: Mon, 22 Apr 2024 10:10:21 -0500 Subject: Modify where to look for fp16 dependency. This dependency is normally @@ -7,11 +7,11 @@ Subject: Modify where to look for fp16 dependency. This dependency is normally diff --git a/BUILD.bazel b/BUILD.bazel -index 634faf34baceefc8a08f953777eecdabfa9d1b73..349d523252347b5314950228b1ca0b558c2ac4cb 100644 +index 4a831b0d190ea85eebb7796a1bc9bb5eae3a13ea..e99cb6fe2dc950678612d22693fd8dbfa8a3aa7a 100644 --- a/BUILD.bazel +++ b/BUILD.bazel -@@ -3828,16 +3828,22 @@ v8_library( - ], +@@ -3799,16 +3799,22 @@ filegroup( + }), ) -v8_library( diff --git a/patches/v8/0014-Expose-v8-Symbol-GetDispose.patch b/patches/v8/0014-Expose-v8-Symbol-GetDispose.patch index b85358a27ce..d3f4619a8ac 100644 --- a/patches/v8/0014-Expose-v8-Symbol-GetDispose.patch +++ b/patches/v8/0014-Expose-v8-Symbol-GetDispose.patch @@ -1,4 +1,4 @@ -From ab9b30b91e514433690c1a9f4eb8653fdf192405 Mon Sep 17 00:00:00 2001 +From 9ce4e94340d59211c4e24e73969a212377c6aa90 Mon Sep 17 00:00:00 2001 From: Jon Phillips Date: Tue, 30 Apr 2024 00:06:33 +0100 Subject: Expose v8::Symbol::GetDispose(). @@ -21,10 +21,10 @@ index 426bb379099e262191dadfd87262f4431bd444c6..7d0f6399a22cb32b19641398b9e858ce V8_INLINE static Symbol* Cast(Data* data) { #ifdef V8_ENABLE_CHECKS diff --git a/src/api/api.cc b/src/api/api.cc -index e34f21cb6082f2a3cf506e4f75a63b1718d8759e..06895d14a0ab93b8a9f16b761744d8d8986bdf97 100644 +index 8db94796eb44db416f38fb5488ea4c83eeec1bf0..d3fc6d77ea3a75535ca688e120e884afa1b5815d 100644 --- a/src/api/api.cc +++ b/src/api/api.cc -@@ -9463,7 +9463,9 @@ Local v8::Symbol::ForApi(Isolate* v8_isolate, Local name) { +@@ -9461,7 +9461,9 @@ Local v8::Symbol::ForApi(Isolate* v8_isolate, Local name) { V(Split, split) \ V(ToPrimitive, to_primitive) \ V(ToStringTag, to_string_tag) \ diff --git a/patches/v8/0015-Rename-V8_COMPRESS_POINTERS_IN_ISOLATE_CAGE-V8_COMPR.patch b/patches/v8/0015-Rename-V8_COMPRESS_POINTERS_IN_ISOLATE_CAGE-V8_COMPR.patch index 2cdfe70635f..a801eb9039a 100644 --- a/patches/v8/0015-Rename-V8_COMPRESS_POINTERS_IN_ISOLATE_CAGE-V8_COMPR.patch +++ b/patches/v8/0015-Rename-V8_COMPRESS_POINTERS_IN_ISOLATE_CAGE-V8_COMPR.patch @@ -1,4 +1,4 @@ -From f37963c8d6060af1c39af2d1ef87d29cf42b9f3f Mon Sep 17 00:00:00 2001 +From 125708e60af053fdb12d5e304fd9646a8ca974d0 Mon Sep 17 00:00:00 2001 From: Jon Phillips Date: Thu, 9 May 2024 23:36:43 +0100 Subject: Rename V8_COMPRESS_POINTERS_IN_ISOLATE_CAGE -> @@ -9,10 +9,10 @@ this rename elsewhere: https://chromium-review.googlesource.com/c/v8/v8/+/5279595. diff --git a/BUILD.bazel b/BUILD.bazel -index f4e21615946d33c24a818cfee3ec4551ee908aac..bbbd4e3ef1d2f8de13b3ef52422481c8c4106c79 100644 +index e99cb6fe2dc950678612d22693fd8dbfa8a3aa7a..4146cef20a6684ae811aacc7a93a0832943a2173 100644 --- a/BUILD.bazel +++ b/BUILD.bazel -@@ -327,10 +327,10 @@ selects.config_setting_group( +@@ -329,10 +329,10 @@ selects.config_setting_group( ], ) @@ -25,7 +25,7 @@ index f4e21615946d33c24a818cfee3ec4551ee908aac..bbbd4e3ef1d2f8de13b3ef52422481c8 match_all = [ ":is_v8_enable_pointer_compression", ":is_not_v8_enable_pointer_compression_shared_cage", -@@ -526,8 +526,8 @@ v8_config( +@@ -529,8 +529,8 @@ v8_config( ":enable_pointer_compression_shared_cage": [ "V8_COMPRESS_POINTERS_IN_SHARED_CAGE", ], diff --git a/patches/v8/0016-Revert-TracedReference-deref-API-removal.patch b/patches/v8/0016-Revert-TracedReference-deref-API-removal.patch index 6635dbc3d24..bfada9476c1 100644 --- a/patches/v8/0016-Revert-TracedReference-deref-API-removal.patch +++ b/patches/v8/0016-Revert-TracedReference-deref-API-removal.patch @@ -1,4 +1,4 @@ -From d7512e34a47292ec4e291079fed080121dd62a6e Mon Sep 17 00:00:00 2001 +From 2b99ae2cbe2f3e4db6f6fcac18a389d245143534 Mon Sep 17 00:00:00 2001 From: Harris Hancock Date: Fri, 28 Jun 2024 14:19:25 +0100 Subject: Revert TracedReference deref API removal @@ -6,10 +6,10 @@ Subject: Revert TracedReference deref API removal This previously-deprecated API was removed in 7cd2b0c434bd5ea7bd253a97958c7348557fd72e, but we don't know how to safely replace our usage of it yet. diff --git a/include/v8-traced-handle.h b/include/v8-traced-handle.h -index 28fe6cf5ae3ad0dadafcc0942bda6d9148d5d58f..0e39bdf79ab0770df0fac97ee95c2ba2effdb874 100644 +index 04752c4f2aeed025364326fb0a0d85c03ba3347c..f1a41b1d8cd756358b536ee90ca9bd8c6b601e69 100644 --- a/include/v8-traced-handle.h +++ b/include/v8-traced-handle.h -@@ -134,6 +134,17 @@ class BasicTracedReference : public TracedReferenceBase { +@@ -135,6 +135,17 @@ class BasicTracedReference : public TracedReferenceBase { const_cast&>(*this)); } diff --git a/patches/v8/0017-Revert-heap-Add-masm-specific-unwinding-annotations-.patch b/patches/v8/0017-Revert-heap-Add-masm-specific-unwinding-annotations-.patch index d8cb181dbf2..80f39262bab 100644 --- a/patches/v8/0017-Revert-heap-Add-masm-specific-unwinding-annotations-.patch +++ b/patches/v8/0017-Revert-heap-Add-masm-specific-unwinding-annotations-.patch @@ -1,4 +1,4 @@ -From 8f3298d94672b411e5d7337714593d01b980bfc7 Mon Sep 17 00:00:00 2001 +From 139a95cc864b400209c227adda72cce4d04baf85 Mon Sep 17 00:00:00 2001 From: Harris Hancock Date: Wed, 3 Jul 2024 15:46:43 +0100 Subject: Revert "heap: Add masm-specific unwinding annotations to GC @@ -9,10 +9,10 @@ This reverts commit 42bc7bfdf56cc7a8cd7757d96aa70b83ce82d9ff. This commit broke our build, because we patch V8 to build push_registers_asm.cc with clang-cl on Windows, and this commit makes it an error to compile that file on Windows with any compiler. Maybe clang-cl and masm can be used together? I'm not sure. In the meantime, I'm reverting this commit in the hope of getting our V8 upgrade unblocked. diff --git a/BUILD.gn b/BUILD.gn -index 87b212921bb8d51fd5457a7b4d61ee956589c282..33a97f8a8b5b0ba482b7bb3d1d0528e3b0ec7f76 100644 +index 19e0d2b584790eed3f633152f25665aa333d6f4a..3fd262bd0184d0e9b1c9df7ac2b9ae717ba0482a 100644 --- a/BUILD.gn +++ b/BUILD.gn -@@ -4271,8 +4271,8 @@ v8_header_set("v8_internal_headers") { +@@ -4240,8 +4240,8 @@ v8_header_set("v8_internal_headers") { "src/third_party/siphash/halfsiphash.h", "src/third_party/utf8-decoder/utf8-decoder.h", "src/torque/runtime-macro-shims.h", @@ -22,7 +22,7 @@ index 87b212921bb8d51fd5457a7b4d61ee956589c282..33a97f8a8b5b0ba482b7bb3d1d0528e3 "src/tracing/traced-value.h", "src/tracing/tracing-category-observer.h", "src/utils/address-map.h", -@@ -6924,12 +6924,7 @@ v8_source_set("v8_heap_base") { +@@ -6940,12 +6940,7 @@ v8_source_set("v8_heap_base") { if (is_clang || !is_win) { if (current_cpu == "x64") { diff --git a/patches/v8/0018-Update-illegal-invocation-error-message-in-v8.patch b/patches/v8/0018-Update-illegal-invocation-error-message-in-v8.patch index c1c28d40fb1..53d1042a6bf 100644 --- a/patches/v8/0018-Update-illegal-invocation-error-message-in-v8.patch +++ b/patches/v8/0018-Update-illegal-invocation-error-message-in-v8.patch @@ -1,11 +1,11 @@ -From c4887f798d55850a858fbb046a526194cf267c11 Mon Sep 17 00:00:00 2001 +From 7e5cd64bd2c2354ab4d5e5525465a02bd2183497 Mon Sep 17 00:00:00 2001 From: James M Snell Date: Tue, 9 Jul 2024 08:37:05 -0700 Subject: Update illegal invocation error message in v8 diff --git a/src/common/message-template.h b/src/common/message-template.h -index 20e4ce1b57d947bc80d10eb1baf05f495b244505..25eec5c469261f655a226782b7bad55892108ff4 100644 +index 1390439013513f314e4cda5078c2026ca244d2a1..de253f53c5171d5d91eb023f71fab6ff51519b8e 100644 --- a/src/common/message-template.h +++ b/src/common/message-template.h @@ -112,7 +112,9 @@ namespace internal { diff --git a/patches/v8/0019-Implement-cross-request-context-promise-resolve-hand.patch b/patches/v8/0019-Implement-cross-request-context-promise-resolve-hand.patch index a31e95a5480..74ac81b1cd0 100644 --- a/patches/v8/0019-Implement-cross-request-context-promise-resolve-hand.patch +++ b/patches/v8/0019-Implement-cross-request-context-promise-resolve-hand.patch @@ -1,14 +1,14 @@ -From 31758ba9e6c5583ca38f77fca62a28f872872a83 Mon Sep 17 00:00:00 2001 +From 7724507f0525deef0a484d33d2efee3586728520 Mon Sep 17 00:00:00 2001 From: James M Snell Date: Mon, 16 Sep 2024 09:56:04 -0700 Subject: Implement cross-request context promise resolve handling diff --git a/include/v8-callbacks.h b/include/v8-callbacks.h -index 6add89ac1837df03a71539801ab513e098e73722..ad153256a06f16fc89cee9144716ba6bfaaec08c 100644 +index 25f0c8189e5c0102b26bfd0827f375d9910849cd..f7fbae861a5ab64e1792f8de1b2e59657c1c1b70 100644 --- a/include/v8-callbacks.h +++ b/include/v8-callbacks.h -@@ -463,6 +463,27 @@ using PromiseCrossContextCallback = MaybeLocal (*)(Local conte +@@ -471,6 +471,27 @@ using PromiseCrossContextCallback = MaybeLocal (*)(Local conte Local promise, Local tag); @@ -37,10 +37,10 @@ index 6add89ac1837df03a71539801ab513e098e73722..ad153256a06f16fc89cee9144716ba6b #endif // INCLUDE_V8_ISOLATE_CALLBACKS_H_ diff --git a/include/v8-isolate.h b/include/v8-isolate.h -index 96b7d9feb20d4ef1b5ba2da56d9635688da2457c..825ead73595d445e0cf27df4c4c43de5a31632e3 100644 +index 8112231319b309cdb96c59896fc0f48bcf920e96..9fe57f7bde401a9b68b4dcdb3adf03ea7a11404b 100644 --- a/include/v8-isolate.h +++ b/include/v8-isolate.h -@@ -1733,6 +1733,8 @@ class V8_EXPORT Isolate { +@@ -1732,6 +1732,8 @@ class V8_EXPORT Isolate { class PromiseContextScope; void SetPromiseCrossContextCallback(PromiseCrossContextCallback callback); @@ -50,10 +50,10 @@ index 96b7d9feb20d4ef1b5ba2da56d9635688da2457c..825ead73595d445e0cf27df4c4c43de5 Isolate() = delete; ~Isolate() = delete; diff --git a/src/api/api.cc b/src/api/api.cc -index 06895d14a0ab93b8a9f16b761744d8d8986bdf97..cbe6b3153a4e165154680ae1670d5d1fd83633ba 100644 +index d3fc6d77ea3a75535ca688e120e884afa1b5815d..248a78ad24cbb84a168568f67ded619b2b1a1615 100644 --- a/src/api/api.cc +++ b/src/api/api.cc -@@ -12247,12 +12247,17 @@ void Isolate::SetPromiseCrossContextCallback(PromiseCrossContextCallback callbac +@@ -12246,12 +12246,17 @@ void Isolate::SetPromiseCrossContextCallback(PromiseCrossContextCallback callbac isolate->set_promise_cross_context_callback(callback); } @@ -73,7 +73,7 @@ index 06895d14a0ab93b8a9f16b761744d8d8986bdf97..cbe6b3153a4e165154680ae1670d5d1f Isolate::PromiseContextScope::~PromiseContextScope() { diff --git a/src/builtins/promise-abstract-operations.tq b/src/builtins/promise-abstract-operations.tq -index 6142e0450dac646ccebd3fc7c5168f9b42b4d0b5..9acc20825711c87aa3fe07916cddf208e0963b9f 100644 +index fdec3d268e4e3d181d6c092bbb19a40cdf8dde57..456d051d3c0b8156deb8a54dce7037769564e919 100644 --- a/src/builtins/promise-abstract-operations.tq +++ b/src/builtins/promise-abstract-operations.tq @@ -23,6 +23,9 @@ extern transitioning runtime PromiseRejectEventFromStack( @@ -158,10 +158,10 @@ index 9e0969460fd33d8cc893e04d3418e1cbed01d6a0..aa2b1cea6b7b6c0c91108776e79b04cc Tagged Isolate::VerifyBuiltinsResult(Tagged result) { if (is_execution_terminating() && !v8_flags.strict_termination_checks) { diff --git a/src/execution/isolate.cc b/src/execution/isolate.cc -index 20f371a3cd2717eee242d3faab8ddf040b0ec034..8615381c5e2249b504fcc899e95309fccc096497 100644 +index dab3359645835636a4ab0f1a1fc35706b1aa3d3c..f9c6adaa00971b94c85e8dfb2d1225ccf2f9b37e 100644 --- a/src/execution/isolate.cc +++ b/src/execution/isolate.cc -@@ -599,8 +599,6 @@ void Isolate::Iterate(RootVisitor* v, ThreadLocalTop* thread) { +@@ -593,8 +593,6 @@ void Isolate::Iterate(RootVisitor* v, ThreadLocalTop* thread) { FullObjectSlot(&thread->pending_message_)); v->VisitRootPointer(Root::kStackRoots, nullptr, FullObjectSlot(&thread->context_)); @@ -170,7 +170,7 @@ index 20f371a3cd2717eee242d3faab8ddf040b0ec034..8615381c5e2249b504fcc899e95309fc for (v8::TryCatch* block = thread->try_catch_handler_; block != nullptr; block = block->next_) { -@@ -7509,5 +7507,27 @@ MaybeHandle Isolate::RunPromiseCrossContextCallback(Handle Isolate::RunPromiseCrossContextCallback(Handle Factory::NewJSPromiseWithoutHook() { +@@ -4413,18 +4413,17 @@ Handle Factory::NewJSPromiseWithoutHook() { Handle promise = Cast(NewJSObject(isolate()->promise_function())); DisallowGarbageCollection no_gc; @@ -277,10 +277,10 @@ index 1d631dde7b3234f6d3639a8f49410e908126f6d6..baafc83265c8386437b8399e1e50050c } diff --git a/src/objects/js-promise.h b/src/objects/js-promise.h -index afb40bd86464535ce0b7ed649cd0b09ea78b3d26..e1e953affdc617747164e655d1063f906a03ac43 100644 +index e4c1e42c63e036063baff9e8079c148c4fe3e112..87bebb70d0d31842318c5a6bc555dbd226491811 100644 --- a/src/objects/js-promise.h +++ b/src/objects/js-promise.h -@@ -81,6 +81,11 @@ class JSPromise +@@ -75,6 +75,11 @@ class JSPromise static_assert(v8::Promise::kFulfilled == 1); static_assert(v8::Promise::kRejected == 2); @@ -293,10 +293,10 @@ index afb40bd86464535ce0b7ed649cd0b09ea78b3d26..e1e953affdc617747164e655d1063f90 // ES section #sec-triggerpromisereactions static Handle TriggerPromiseReactions(Isolate* isolate, diff --git a/src/objects/objects.cc b/src/objects/objects.cc -index eda5636e187c368ec849c6ab204fe49c335a691e..c67cc54200ebb717d3b4c962218858e220cc59aa 100644 +index 76e284e19a293cf6f452d8333793bf5ae27cca47..b5cde09038e64e7e7854dd7f21b45002361ca8f2 100644 --- a/src/objects/objects.cc +++ b/src/objects/objects.cc -@@ -4866,6 +4866,23 @@ Handle JSPromise::Fulfill(DirectHandle promise, +@@ -4878,6 +4878,23 @@ Handle JSPromise::Fulfill(DirectHandle promise, // 6. Set promise.[[PromiseState]] to "fulfilled". promise->set_status(Promise::kFulfilled); @@ -320,7 +320,7 @@ index eda5636e187c368ec849c6ab204fe49c335a691e..c67cc54200ebb717d3b4c962218858e2 // 7. Return TriggerPromiseReactions(reactions, value). return TriggerPromiseReactions(isolate, reactions, value, PromiseReaction::kFulfill); -@@ -4921,6 +4938,23 @@ Handle JSPromise::Reject(Handle promise, +@@ -4933,6 +4950,23 @@ Handle JSPromise::Reject(Handle promise, isolate->ReportPromiseReject(promise, reason, kPromiseRejectWithNoHandler); } @@ -344,7 +344,7 @@ index eda5636e187c368ec849c6ab204fe49c335a691e..c67cc54200ebb717d3b4c962218858e2 // 8. Return TriggerPromiseReactions(reactions, reason). return TriggerPromiseReactions(isolate, reactions, reason, PromiseReaction::kReject); -@@ -5023,6 +5057,15 @@ MaybeHandle JSPromise::Resolve(Handle promise, +@@ -5035,6 +5069,15 @@ MaybeHandle JSPromise::Resolve(Handle promise, } // static @@ -361,10 +361,10 @@ index eda5636e187c368ec849c6ab204fe49c335a691e..c67cc54200ebb717d3b4c962218858e2 Isolate* isolate, DirectHandle reactions, DirectHandle argument, PromiseReaction::Type type) { diff --git a/src/roots/roots.h b/src/roots/roots.h -index 47e0ef53ee79901873b8dd48e7ca19465cea1868..2657550796b0a022b5efb9830ac0896ba5ca9d39 100644 +index 288dee65e0467d241914fa046640c5e2b716e13b..51af59f2efa37532ea516f7cbcf002d9b706984b 100644 --- a/src/roots/roots.h +++ b/src/roots/roots.h -@@ -406,7 +406,8 @@ class RootVisitor; +@@ -405,7 +405,8 @@ class RootVisitor; V(FunctionTemplateInfo, error_stack_getter_fun_template, \ ErrorStackGetterSharedFun) \ V(FunctionTemplateInfo, error_stack_setter_fun_template, \ @@ -437,10 +437,10 @@ index 4fbdf90319c5fc3b3e6f60aaf1b12a33c5f537ea..f58e6ce6173695f8caf77ba1aa6cf8de } // namespace internal } // namespace v8 diff --git a/src/runtime/runtime.h b/src/runtime/runtime.h -index d23446cbeee65b50cab694dc60743b4ab7f9c1d7..a9e5f7e459442f3c9cb4b3d1e9491da9c87ab114 100644 +index 9399509f6903e392175c2b14a1dd97feaad1c526..bfca9182be091b1fe04c6df67319f8a967adf184 100644 --- a/src/runtime/runtime.h +++ b/src/runtime/runtime.h -@@ -405,7 +405,8 @@ namespace internal { +@@ -403,7 +403,8 @@ namespace internal { F(ConstructAggregateErrorHelper, 4, 1) \ F(ConstructInternalAggregateErrorHelper, -1 /* <= 5*/, 1) \ F(PromiseContextInit, 1, 1) \ diff --git a/patches/v8/0020-Modify-where-to-look-for-fast_float-dependency.patch b/patches/v8/0020-Modify-where-to-look-for-fast_float-dependency.patch deleted file mode 100644 index 41e987cebbc..00000000000 --- a/patches/v8/0020-Modify-where-to-look-for-fast_float-dependency.patch +++ /dev/null @@ -1,49 +0,0 @@ -From ae904da54d2ce2980c69e4316d7e2b49b02a694a Mon Sep 17 00:00:00 2001 -From: Dominik Picheta -Date: Tue, 24 Sep 2024 15:30:12 +0000 -Subject: Modify where to look for fast_float dependency. - -Similar to fp16, this dependency now needs to be downloaded by bazel. - -diff --git a/BUILD.bazel b/BUILD.bazel -index ca6c577276afd26290dd05f0829d3ad64e9b6d1c..3fa74551420b48f226553ddaa00eb9926a3b009f 100644 ---- a/BUILD.bazel -+++ b/BUILD.bazel -@@ -3809,23 +3809,21 @@ filegroup( - }), - ) - --v8_library( -- name = "lib_fast_float", -- srcs = [ -- "third_party/fast_float/src/include/fast_float/ascii_number.h", -- "third_party/fast_float/src/include/fast_float/bigint.h", -- "third_party/fast_float/src/include/fast_float/constexpr_feature_detect.h", -- "third_party/fast_float/src/include/fast_float/decimal_to_binary.h", -- "third_party/fast_float/src/include/fast_float/digit_comparison.h", -- "third_party/fast_float/src/include/fast_float/fast_float.h", -- "third_party/fast_float/src/include/fast_float/fast_table.h", -- "third_party/fast_float/src/include/fast_float/float_common.h", -- "third_party/fast_float/src/include/fast_float/parse_number.h", -+cc_library( -+ name = "lib_fast_float", -+ hdrs = [ -+ "@fast_float//:include/fast_float/fast_float.h", -+ "@fast_float//:include/fast_float/ascii_number.h", -+ "@fast_float//:include/fast_float/bigint.h", -+ "@fast_float//:include/fast_float/constexpr_feature_detect.h", -+ "@fast_float//:include/fast_float/decimal_to_binary.h", -+ "@fast_float//:include/fast_float/digit_comparison.h", -+ "@fast_float//:include/fast_float/fast_table.h", -+ "@fast_float//:include/fast_float/float_common.h", -+ "@fast_float//:include/fast_float/parse_number.h", - ], -- hdrs = [ "third_party/fast_float/src/include/fast_float/fast_float.h" ], -- includes = [ -- "third_party/fast_float/src/include", -- ], -+ include_prefix = "third_party/fast_float/src", -+ deps = [], - ) - - cc_library( diff --git a/src/workerd/jsg/v8-platform-wrapper.h b/src/workerd/jsg/v8-platform-wrapper.h index 4da4f08da7b..7a11be8fae3 100644 --- a/src/workerd/jsg/v8-platform-wrapper.h +++ b/src/workerd/jsg/v8-platform-wrapper.h @@ -22,9 +22,8 @@ class V8PlatformWrapper: public v8::Platform { return inner.NumberOfWorkerThreads(); } - std::shared_ptr GetForegroundTaskRunner( - v8::Isolate* isolate, v8::TaskPriority priority) override { - return inner.GetForegroundTaskRunner(isolate, priority); + std::shared_ptr GetForegroundTaskRunner(v8::Isolate* isolate) override { + return inner.GetForegroundTaskRunner(isolate); } void PostTaskOnWorkerThreadImpl(v8::TaskPriority priority, diff --git a/src/workerd/server/v8-platform-impl.h b/src/workerd/server/v8-platform-impl.h index 5de7edc8b8b..ed5348bb91a 100644 --- a/src/workerd/server/v8-platform-impl.h +++ b/src/workerd/server/v8-platform-impl.h @@ -36,9 +36,8 @@ class WorkerdPlatform final: public v8::Platform { return inner.NumberOfWorkerThreads(); } - std::shared_ptr GetForegroundTaskRunner( - v8::Isolate* isolate, v8::TaskPriority priority) noexcept override { - return inner.GetForegroundTaskRunner(isolate, priority); + std::shared_ptr GetForegroundTaskRunner(v8::Isolate* isolate) noexcept override { + return inner.GetForegroundTaskRunner(isolate); } void PostTaskOnWorkerThreadImpl(v8::TaskPriority priority,