From e65614cb92a11ccb42d1692f6396ab62dfab0320 Mon Sep 17 00:00:00 2001 From: Jonas Hahnfeld Date: Mon, 20 Feb 2023 10:08:00 +0100 Subject: [PATCH] Disable outline-atomics on AArch64 The routines __aarch64_* are defined in the static library libgcc.a and not necessarily included in libCling or otherwise present in the process, so the interpreter has a hard time finding them. Fixes #12294 --- lib/Interpreter/CIFactory.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/Interpreter/CIFactory.cpp b/lib/Interpreter/CIFactory.cpp index b135bf21..b5b5df2e 100644 --- a/lib/Interpreter/CIFactory.cpp +++ b/lib/Interpreter/CIFactory.cpp @@ -1254,6 +1254,13 @@ namespace { #if __APPLE__ && __arm64__ argvCompile.push_back("--target=arm64-apple-darwin20.3.0"); #endif +#if __aarch64__ + // Disable outline-atomics on AArch64; the routines __aarch64_* are defined + // in the static library libgcc.a and not necessarily included in libCling + // or otherwise present in the process, so the interpreter has a hard time + // finding them. + argvCompile.push_back("-mno-outline-atomics"); +#endif // Variables for storing the memory of the C-string arguments. // FIXME: We shouldn't use C-strings in the first place, but just use