https://bugs.llvm.org/show_bug.cgi?id=35072
Bug ID: 35072
Summary: [AArch64] cmpxchg not using Armv8.1-a instructions at
-O0
Product: new-bugs
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: new bugs
Assignee: unassignedb...@nondot.org
Reporter: christof.do...@arm.com
CC: llvm-bugs@lists.llvm.org
Created attachment 19337
--> https://bugs.llvm.org/attachment.cgi?id=19337&action=edit
reproducer
The Armv8.1-a target has a compare-and-swap (CAS) instruction which is used to
implement cmpxchg operation of LLVM IR. However, at -O0 the code generator is
still emitting a long code sequence to emulate this instruction.
LLVM should use CAS even at -O0.
A reproducer that show the behaviour is attached. Compile using:
llc -mattr=+v8.1a cmpxchg.ll -O[0|2]
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs