MINGW-packages/mingw-w64-v8/004-fix-static-assert-implementations.patch
Raed Rizqie bf99396a2e v8: update to 14.0.210
- rebase some patches
- disable external startup data (using internal instead)
- enable monolithic library
2025-07-25 14:04:21 +00:00

33 lines
1.4 KiB
Diff

diff --git a/src/base/macros.h b/src/base/macros.h
index e5e020d9..e9ee1e30 100644
--- a/src/base/macros.h
+++ b/src/base/macros.h
@@ -199,7 +199,7 @@ V8_INLINE Dest bit_cast(Source const& source) {
// DISABLE_CFI_ICALL -- Disable Control Flow Integrity indirect call checks,
// useful because calls into JITed code can not be CFI verified. Same for
// UBSan's function pointer type checks.
-#ifdef V8_OS_WIN
+#ifdef V8_CC_MSVC
// On Windows, also needs __declspec(guard(nocf)) for CFG.
#define DISABLE_CFI_ICALL \
V8_CLANG_NO_SANITIZE("cfi-icall") \
diff --git a/src/profiler/heap-snapshot-generator.cc b/src/profiler/heap-snapshot-generator.cc
index 40ee39d7..fda19f27 100644
--- a/src/profiler/heap-snapshot-generator.cc
+++ b/src/profiler/heap-snapshot-generator.cc
@@ -427,11 +427,11 @@ HeapSnapshot::HeapSnapshot(HeapProfiler* profiler,
static_assert(kSystemPointerSize != 4 || sizeof(HeapGraphEdge) == 12);
static_assert(kSystemPointerSize != 8 || sizeof(HeapGraphEdge) == 24);
static_assert(kSystemPointerSize != 4 || sizeof(HeapEntry) == 32);
-#if V8_CC_MSVC
+#if V8_OS_WIN
static_assert(kSystemPointerSize != 8 || sizeof(HeapEntry) == 48);
-#else // !V8_CC_MSVC
+#else // !V8_OS_WIN
static_assert(kSystemPointerSize != 8 || sizeof(HeapEntry) == 40);
-#endif // !V8_CC_MSVC
+#endif // !V8_OS_WIN
memset(&gc_subroot_entries_, 0, sizeof(gc_subroot_entries_));
}