From 4f97ea8da7159d8be80471a93011442b40c3003d Mon Sep 17 00:00:00 2001 From: kd-11 Date: Sun, 25 Aug 2024 20:38:02 +0300 Subject: [PATCH] macos - Fix crash when running native arm64 LLVM --- Utilities/JITLLVM.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Utilities/JITLLVM.cpp b/Utilities/JITLLVM.cpp index a28ee2580f..0a1038f61e 100644 --- a/Utilities/JITLLVM.cpp +++ b/Utilities/JITLLVM.cpp @@ -517,7 +517,7 @@ std::string jit_compiler::triple1() #elif defined(__APPLE__) && defined(ARCH_X64) return llvm::Triple::normalize("x86_64-unknown-linux-gnu"); #elif defined(__APPLE__) && defined(ARCH_ARM64) - return llvm::Triple::normalize("aarch64-unknown-linux-gnu"); + return llvm::Triple::normalize("aarch64-unknown-linux-android"); // Set environment to android to reserve x18 #else return llvm::Triple::normalize(llvm::sys::getProcessTriple()); #endif @@ -532,7 +532,7 @@ std::string jit_compiler::triple2() #elif defined(__APPLE__) && defined(ARCH_X64) return llvm::Triple::normalize("x86_64-unknown-linux-gnu"); #elif defined(__APPLE__) && defined(ARCH_ARM64) - return llvm::Triple::normalize("aarch64-unknown-linux-gnu"); + return llvm::Triple::normalize("aarch64-unknown-linux-android"); // Set environment to android to reserve x18 #else return llvm::Triple::normalize(llvm::sys::getProcessTriple()); #endif