Skip to content

Commit 793293d

Browse files
authored
[3.13] gh-130834: Fix free-threaded build with JIT for aarch64 linux (#132368)
* [3.13] gh-130834: Fix free-threaded build with JIT for arm * lint
1 parent 88c1ca9 commit 793293d

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Tools/jit/_targets.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -525,7 +525,12 @@ def get_target(host: str) -> _COFF | _ELF | _MachO:
525525
args = ["-fms-runtime-lib=dll"]
526526
target = _COFF(host, alignment=8, args=args)
527527
elif re.fullmatch(r"aarch64-.*-linux-gnu", host):
528-
args = ["-fpic"]
528+
args = [
529+
"-fpic",
530+
# On aarch64 Linux, intrinsics were being emitted and this flag
531+
# was required to disable them.
532+
"-mno-outline-atomics",
533+
]
529534
target = _ELF(host, alignment=8, args=args)
530535
elif re.fullmatch(r"i686-pc-windows-msvc", host):
531536
args = ["-DPy_NO_ENABLE_SHARED"]

0 commit comments

Comments
 (0)