GCC Bugzilla has been upgraded from version 4.4.9 to 5.0rc3. If you see any problem, please report it to bug 64968.

Bug 32647

Summary: spill failures with hard-register variable
Product: gcc Reporter: Paolo Bonzini <bonzini>
Component: middle-endAssignee: Not yet assigned to anyone <unassigned>
Status: NEW ---    
Severity: normal CC: gcc-bugs, kauer, vmakarov, zsojka
Priority: P3 Keywords: ra
Version: 4.3.0   
Target Milestone: ---   
Host: Target: i686-pc-linux-gnu
Build: Known to work:
Known to fail: 3.3.6, 4.1.2, 4.2.1, 4.3.0 Last reconfirmed: 2008-09-14 04:32:39
Bug Depends on: 9085, 24319, 32004    
Bug Blocks: 55277    

Description Paolo Bonzini 2007-07-06 12:20:56 UTC
This testcase fails with a spill failure for class AREG:

void f(int a)
{
  register int reg asm ("eax") = 0;
  a /= 1000;
  asm volatile ("nop" : "+r"(reg), "+r"(a));
}
Comment 1 Andrew Pinski 2008-09-14 04:34:56 UTC
Related to PR 22072.
Comment 2 Uroš Bizjak 2012-11-19 18:50:46 UTC
Adding CC.
Comment 3 Uroš Bizjak 2012-11-26 19:32:14 UTC
LRA ICEs with following backtrace (-O2) on x86_64:

pr32647.c: In function ‘f’:
pr32647.c:6:1: internal compiler error: in assign_by_spills, at lra-assigns.c:1212
 }
 ^
0x7f41a1 assign_by_spills
        ../../gcc-svn/trunk/gcc/lra-assigns.c:1212
0x7f41a1 lra_assign()
        ../../gcc-svn/trunk/gcc/lra-assigns.c:1364
0x7f1626 lra(_IO_FILE*)
        ../../gcc-svn/trunk/gcc/lra.c:2306
0x7b9038 do_reload
        ../../gcc-svn/trunk/gcc/ira.c:4624
0x7b9038 rest_of_handle_reload
        ../../gcc-svn/trunk/gcc/ira.c:4737

The failure is similar to PR55277.