This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: gcc-64 on HP-UX 11.00


In message <200204152027.g3FKRLuZ009642@hiauly1.hia.nrc.ca>, "John David Anglin
" writes:
 > > However, the code from the actual perl function looks like:
 > > 
 > >         cmpib,= 0,%r3,L$1012
 > > 	addil LT'PL_sv_no,%r27
 > > 	addil LT'PL_sv_yes,%r27
 > > 	b L$1013
 > > 	fldd RT'PL_sv_yes(%r1),%fr22
 > > L$1012
 > > 	fldd RT'PL_sv_no(%r1),%fr22
 > > L$1013
 > > 	fstd %fr22,-272(%r30)
 > > 	b L$0783
 > > 	ldd -272(%r30),%r25
 > > 	[...]
 > > L$1017
 > >         copy %r28,%r25
 > > L$0783
 > >         copy %r25,%r28
 > > 	[restore registers and return]
 > 
 > I tested this with gcc 3.0.3 -O -mpa-risc-2-0 -fPIC (32bit) and the code is:
 > 
 >         cmpib,= 0,%r28,L$0940
 > 	addil LT'PL_sv_yes,%r19
 > 	b L$0733
 > 	ldw RT'PL_sv_yes(%r1),%r28
 > L$0940
 > 	addil LT'PL_sv_no,%r19
 > 	b L$0733
 > 	ldw RT'PL_sv_no(%r1),%r28
 > 
 > So, this worked with 3.0.3 and we have a regression.
I don't doubt that it worked in the past.  My point is that selecting an
FP register to hold an address like this is an exceedingly bad thing to
do.  In fact, not assigning the value to a register and instead leaving it
in memory is actually cheaper than assigning it to an FP register.

In fact, from the fragments, it looks like we did something insanely stupid,
why don't we assign the value to %r28 or %r25?

jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]