Commit 5e227beb authored by Ben Noordhuis's avatar Ben Noordhuis Committed by V8 LUCI CQ

[arm64] Fix undefined symbol linker error

Assembler::CheckBuffer() was defined inline in a header file but without
inline linkage, causing an undefined symbol link error on arm64 macOS.

Fixes: https://github.com/nodejs/node-v8/issues/233
Bug: v8:13055
Change-Id: Ifb638705e95de72b2e8d472e7092e88d77cf8ba8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3749583
Auto-Submit: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#81749}
parent 80d1dbe6
......@@ -1066,21 +1066,6 @@ const Register& Assembler::AppropriateZeroRegFor(const CPURegister& reg) const {
return reg.Is64Bits() ? xzr : wzr;
}
inline void Assembler::CheckBufferSpace() {
DCHECK_LT(pc_, buffer_start_ + buffer_->size());
if (V8_UNLIKELY(buffer_space() < kGap)) {
GrowBuffer();
}
}
V8_INLINE void Assembler::CheckBuffer() {
CheckBufferSpace();
if (pc_offset() >= next_veneer_pool_check_) {
CheckVeneerPool(false, true);
}
constpool_.MaybeCheck();
}
EnsureSpace::EnsureSpace(Assembler* assembler) : block_pools_scope_(assembler) {
assembler->CheckBufferSpace();
}
......
......@@ -2637,8 +2637,21 @@ class V8_EXPORT_PRIVATE Assembler : public AssemblerBase {
}
void GrowBuffer();
V8_INLINE void CheckBufferSpace();
void CheckBuffer();
void CheckBufferSpace() {
DCHECK_LT(pc_, buffer_start_ + buffer_->size());
if (V8_UNLIKELY(buffer_space() < kGap)) {
GrowBuffer();
}
}
void CheckBuffer() {
CheckBufferSpace();
if (pc_offset() >= next_veneer_pool_check_) {
CheckVeneerPool(false, true);
}
constpool_.MaybeCheck();
}
// Emission of the veneer pools may be blocked in some code sequences.
int veneer_pool_blocked_nesting_; // Block emission if this is not zero.
......
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