Floating Pt. Optimize on PA
Mark Klein
mklein@dis.com
Fri Dec 25 14:26:00 GMT 1998
The attached code at -O2 fails with egcs-1.1b and egcs-1.1.1. It
works correctly in gcc 2.8.1.
Analysis:
fldds 0(0,%r19),%fr8
ldw -120(0,%r30),%r20
ldo -120(%r30),%r21
fstds %fr8,0(0,%r21)
addil LR'L$C0002-$global$,%r27
stw %r20,16(0,%r4)
copy %r1,%r22
ldw 4(0,%r21),%r24
copy %r20,%r25
stw %r24,20(0,%r4)
.CALL ARGW0=GR,ARGW1=GR,ARGW2=GR
bl printf,%r2
ldo RR'L$C0002-$global$(%r22),%r26
The second instruction (ldw -120(0,%r30),%r20) is attempting to
load the high order 32 bits of the floating point value into a
general register before the floating point value has been saved
into the frame.
More information about the Gcc-bugs
mailing list