[prev in list] [next in list] [prev in thread] [next in thread]
List: llvm-bugs
Subject: [LLVMbugs] [Bug 10221] New: Poor register allocation
From: bugzilla-daemon () llvm ! org
Date: 2011-06-29 3:28:12
Message-ID: bug-10221-206 () http ! llvm ! org/bugs/
[Download RAW message or body]
http://llvm.org/bugs/show_bug.cgi?id=10221
Summary: Poor register allocation
Product: libraries
Version: trunk
Platform: PC
OS/Version: All
Status: NEW
Severity: normal
Priority: P
Component: Register Allocator
AssignedTo: unassignedbugs@nondot.org
ReportedBy: jmuizelaar@mozilla.com
CC: llvmbugs@cs.uiuc.edu
This code:
void foo(float x, float y);
int finit(double);
int
nsSVGPathElementCreateSVGPathSegMovetoAbs(float x, float y, void **_retval)
{
if (!finit((x)+(y))) {
return 5;
}
foo(x, y);
return 0;
}
Compiles to:
__@_Z41nsSVGPathElementCreateSVGPathSegMovetoAbsffPPv
pushq %rax
movaps %xmm1, %xmm2
movaps %xmm0, %xmm1
movaps %xmm1, %xmm0
We move and then move back?
movss %xmm1, 4(%rsp) ## 4-byte Spill
addss %xmm2, %xmm0
movss %xmm2, (%rsp) ## 4-byte Spill
We also shouldn't need to use xmm2 here above
cvtss2sd %xmm0, %xmm0
callq __Z5finitd
movl %eax, %ecx
movl $5, %eax
testl %ecx, %ecx
je LBB0_2
movss 4(%rsp), %xmm0 ## 4-byte Reload
movss (%rsp), %xmm1 ## 4-byte Reload
callq __Z3fooff
xorl %eax, %eax
addq $8, %rsp
ret
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
LLVMbugs@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic