Commit 0f4731c8 authored by gengjiawen's avatar gengjiawen Committed by V8 LUCI CQ

[build] fix MSVC build issues

on latest MSVC, build will fail due to error C1017

log: https://github.com/bnoordhuis/v8-cmake/runs/6473602404
Change-Id: Ida6a4f1cbace68cbfc5aa7d4df2e7829fc755a55
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3653496Reviewed-by: 's avatarClemens Backes <clemensb@chromium.org>
Reviewed-by: 's avatarIgor Sheludko <ishell@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80614}
parent d75d524c
......@@ -1249,7 +1249,7 @@ void TurboAssembler::Claim(int64_t count, uint64_t unit_size) {
return;
}
DCHECK_EQ(size % 16, 0);
#if V8_TARGET_OS_WIN
#ifdef V8_TARGET_OS_WIN
while (size > kStackPageSize) {
Sub(sp, sp, kStackPageSize);
Str(xzr, MemOperand(sp));
......@@ -1271,7 +1271,7 @@ void TurboAssembler::Claim(const Register& count, uint64_t unit_size) {
}
AssertPositiveOrZero(count);
#if V8_TARGET_OS_WIN
#ifdef V8_TARGET_OS_WIN
// "Functions that allocate 4k or more worth of stack must ensure that each
// page prior to the final page is touched in order." Source:
// https://docs.microsoft.com/en-us/cpp/build/arm64-windows-abi-conventions?view=vs-2019#stack
......
......@@ -34,7 +34,7 @@ void StaticCallInterfaceDescriptor<DerivedDescriptor>::
// static
constexpr auto WriteBarrierDescriptor::registers() {
#if V8_TARGET_OS_WIN
#ifdef V8_TARGET_OS_WIN
return RegisterArray(rdi, r8, rcx, rax, r9, rdx, rsi);
#else
return RegisterArray(rdi, rbx, rdx, rcx, rax, rsi);
......
......@@ -4451,7 +4451,7 @@ void Worker::PostMessageOut(const v8::FunctionCallbackInfo<v8::Value>& args) {
}
}
#if V8_TARGET_OS_WIN
#ifdef V8_TARGET_OS_WIN
// Enable support for unicode filename path on windows.
// We first convert ansi encoded argv[i] to utf16 encoded, and then
// convert utf16 encoded to utf8 encoded with setting the argv[i]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment