From 2d87c56f374a8561fbba696fa73becbdfdcf673e Mon Sep 17 00:00:00 2001 From: Joyee Cheung Date: Tue, 6 Oct 2026 16:14:36 +0200 Subject: [PATCH] deps: V8: cherry-pick 19173cde61d8 Original commit message: Make TagRange build without __builtin_unreachable Guard the call with V8_HAS_BUILTIN_UNREACHABLE, if it's not available in the toolchain, skip the compiler hint so it still compiles. Co-Authored-By: StefanStojanovic Refs: https://github.com/nodejs/node/pull/61898 Change-Id: Ided07825644ffdd5b6aa7c6fa7f39ae3e62d2535 Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/8517724 Commit-Queue: Joyee Cheung Reviewed-by: Michael Lippautz Cr-Commit-Position: refs/heads/main@{#110422} Refs: https://github.com/v8/v8/commit/19173cde61d86c96da741e10e4ccbb20e11794ad Signed-off-by: Joyee Cheung PR-URL: https://github.com/nodejs/node/pull/66601 Reviewed-By: Richard Lau Reviewed-By: Filip Skokan Reviewed-By: Chengzhong Wu --- common.gypi | 2 +- deps/v8/include/v8-internal.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/common.gypi b/common.gypi index 73695cac679..5586cbce856 100644 --- a/common.gypi +++ b/common.gypi @@ -44,7 +44,7 @@ # Reset this number to 0 on major V8 upgrades. # Increment by one for each non-official patch applied to deps/v8. - 'v8_embedder_string': '-node.7', + 'v8_embedder_string': '-node.8', ##### V8 defaults for Node.js ##### diff --git a/deps/v8/include/v8-internal.h b/deps/v8/include/v8-internal.h index 121dfc8e33f..fd8fcda6f5e 100644 --- a/deps/v8/include/v8-internal.h +++ b/deps/v8/include/v8-internal.h @@ -532,7 +532,7 @@ struct TagRange { // Construct the inclusive tag range [first, last]. constexpr TagRange(Tag first, Tag last) : first(first), last(last) { -#ifdef V8_ENABLE_CHECKS +#if defined(V8_ENABLE_CHECKS) && V8_HAS_BUILTIN_UNREACHABLE // This would typically be a DCHECK, but that's not available here. if (first > last) __builtin_unreachable(); // Invalid tag range. #endif