https://bugs.llvm.org/show_bug.cgi?id=48980
Bug ID: 48980
Summary: [ARM] Very non-optimal register allocation for basic
operations
Product: libraries
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: Backend: ARM
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected],
[email protected]
int square(int num)
{
return num * num;
}
With -O3, GCC generates this:
square(int):
mul r0, r0, r0
bx lr
LLVM generates this:
square(int):
mul r1, r0, r0
mov r0, r1
bx lr
--
You are receiving this mail because:
You are on the CC list for the bug._______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs