diff --git a/lib/VM/JIT/arm64/JIT.cpp b/lib/VM/JIT/arm64/JIT.cpp index bb03d90ffcd..2912ae83431 100644 --- a/lib/VM/JIT/arm64/JIT.cpp +++ b/lib/VM/JIT/arm64/JIT.cpp @@ -100,7 +100,7 @@ class JITContext::Compiler { [this](std::string &&message) { otherErrorMessage_ = std::move(message); error_ = Error::Other; - _longjmp(errorJmpBuf_, 1); + _sh_longjmp(errorJmpBuf_, 1); }), codeBlock_(codeBlock), funcStart_((const char *)codeBlock->begin()) {} @@ -187,7 +187,7 @@ JITCompiledFunctionPtr JITContext::compileImpl( } JITCompiledFunctionPtr JITContext::Compiler::compileCodeBlock() { - if (_setjmp(errorJmpBuf_) == 0) { + if (_sh_setjmp(errorJmpBuf_) == 0) { return compileCodeBlockImpl(); } else { // We arrive here on error. @@ -291,7 +291,7 @@ JITCompiledFunctionPtr JITContext::Compiler::compileCodeBlockImpl() { #define EMIT_UNIMPLEMENTED(name) \ inline void JITContext::Compiler::emit##name(const inst::name##Inst *inst) { \ error_ = Error::UnsupportedInst; \ - _longjmp(errorJmpBuf_, 1); \ + _sh_longjmp(errorJmpBuf_, 1); \ } EMIT_UNIMPLEMENTED(GetEnvironment) diff --git a/lib/VM/JIT/arm64/JitEmitter.cpp b/lib/VM/JIT/arm64/JitEmitter.cpp index 950fa0d3a2a..6da47338dad 100644 --- a/lib/VM/JIT/arm64/JitEmitter.cpp +++ b/lib/VM/JIT/arm64/JitEmitter.cpp @@ -864,7 +864,7 @@ void Emitter::frameSetup( a.add(a64::x0, a64::sp, jmpBufOffset + offsetof(SHJmpBuf, buf)); // setjmp can't throw and it'll be called once, so don't use a thunk. EMIT_RUNTIME_CALL_WITHOUT_THUNK_AND_SAVED_IP( - *this, int (*)(jmp_buf), _setjmp); + *this, int (*)(jmp_buf), _sh_setjmp); // If this a catch, go to the catch table to jump to either a handler BB or // rethrow. a.cbnz(a64::x0, catchTableLabel_);