[llvm-bugs] [Bug 48980] New: [ARM] Very non-optimal register allocation for basic operations
via llvm-bugs
llvm-bugs at lists.llvm.org
Sun Jan 31 22:08:38 PST 2021
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: unassignedbugs at nondot.org
Reporter: gabravier at gmail.com
CC: llvm-bugs at lists.llvm.org, smithp352 at googlemail.com,
Ties.Stuij at arm.com
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.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210201/952cf6ba/attachment.html>
More information about the llvm-bugs
mailing list