This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/54993] [4.8 regression] PIC register not marked as live
- From: "schwab at linux-m68k dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 28 Oct 2012 15:30:37 +0000
- Subject: [Bug rtl-optimization/54993] [4.8 regression] PIC register not marked as live
- Auto-submitted: auto-generated
- References: <bug-54993-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54993
--- Comment #2 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-28 15:30:37 UTC ---
What exactly did you test? The bug is clearly present before r192890. Here is
the diff between r192889 and r192890:
@@ -1663,16 +1663,17 @@ _Z6test01v:
.cfi_startproc
.cfi_personality 0,__gxx_personality_v0
.cfi_lsda 0,.LLSDA2633
- link.w %fp,#-68
+ link.w %fp,#-72
.cfi_offset 14, -8
.cfi_def_cfa 14, 8
movem.l #12348,-(%sp)
- .cfi_offset 2, -100
- .cfi_offset 3, -96
- .cfi_offset 10, -92
- .cfi_offset 11, -88
- .cfi_offset 12, -84
- .cfi_offset 13, -80
+ .cfi_offset 2, -104
+ .cfi_offset 3, -100
+ .cfi_offset 10, -96
+ .cfi_offset 11, -92
+ .cfi_offset 12, -88
+ .cfi_offset 13, -84
+ lea (%pc, _GLOBAL_OFFSET_TABLE_@GOTPC), %a5
clr.l -48(%fp)
clr.l -44(%fp)
pea 104.w
@@ -1791,22 +1792,22 @@ _Z6test01v:
jsr _ZNSt6thread15_M_start_threadESt10shared_ptrINS_10_Impl_baseEE
.LEHE14:
addq.l #8,%sp
- move.l -16(%fp),%a5
- tst.l %a5
+ move.l -16(%fp),%a1
+ tst.l %a1
jeq .L329
- lea (4,%a5),%a0
+ lea (4,%a1),%a0
move.l #_ZL28__gthrw___pthread_key_createPjPFvPvE,%d2
jeq .L323
move.l (%a0),%d0
.L324:
- move.l %d0,%a1
+ move.l %d0,%d3
move.l %d0,%d1
subq.l #1,%d1
cas.l %d0,%d1,(%a0)
seq %d1
tst.b %d1
jeq .L324
- move.l %a1,%d0
+ move.l %d3,%d0
moveq #1,%d1
cmp.l %d0,%d1
jeq .L446
@@ -1925,7 +1926,7 @@ _Z6test01v:
cmp.l %a0,%d1
jeq .L450
.L309:
- movem.l -92(%fp),#15372
+ movem.l -96(%fp),#15372
unlk %fp
rts
.L351:
@@ -2005,30 +2006,32 @@ _Z6test01v:
sub.l %a0,%a0
jra .L321
.L446:
- move.l (%a5),%a0
- move.l %a5,-(%sp)
+ move.l (%a1),%a0
+ move.l %a1,-(%sp)
move.l 8(%a0),%a0
+ move.l %a1,-72(%fp)
jsr (%a0)
- lea (8,%a5),%a0
+ move.l -72(%fp),%a1
+ lea (8,%a1),%a0
addq.l #4,%sp
tst.l %d2
jeq .L326
move.l (%a0),%d0
.L327:
- move.l %d0,%a1
+ move.l %d0,%d2
move.l %d0,%d1
subq.l #1,%d1
cas.l %d0,%d1,(%a0)
seq %d1
tst.b %d1
jeq .L327
- move.l %a1,%d0
+ move.l %d2,%d0
moveq #1,%d1
cmp.l %d0,%d1
jne .L329
.L452:
- move.l (%a5),%a0
- move.l %a5,-(%sp)
+ move.l (%a1),%a0
+ move.l %a1,-(%sp)
move.l 12(%a0),%a0
jsr (%a0)
addq.l #4,%sp
@@ -2056,7 +2059,7 @@ _Z6test01v:
move.l 12(%a0),%a0
jsr (%a0)
addq.l #4,%sp
- movem.l -92(%fp),#15372
+ movem.l -96(%fp),#15372
unlk %fp
rts
.L449:
@@ -2147,19 +2150,19 @@ _Z6test01v:
addq.l #1,4(%a2)
jra .L312
.L323:
- move.l 4(%a5),%d0
+ move.l 4(%a1),%d0
move.l %d0,%d1
subq.l #1,%d1
- move.l %d1,4(%a5)
+ move.l %d1,4(%a1)
moveq #1,%d1
cmp.l %d0,%d1
jne .L329
jra .L446
.L326:
- move.l 8(%a5),%d0
+ move.l 8(%a1),%d0
move.l %d0,%d1
subq.l #1,%d1
- move.l %d1,8(%a5)
+ move.l %d1,8(%a1)
moveq #1,%d1
cmp.l %d0,%d1
jne .L329