suboptimal GCC code generation for unsigned long long on sparc

Richard Henderson rth@cygnus.com
Mon Sep 29 14:37:00 GMT 1997


> Note that this compares SPARCv8 code generated by GCC for `long long'
> operations to SPARCv9 code generated by Sun's cc.

No it isn't.  Or at least, not necessarily:

	Xor %o0, %o2, %g1
	Retl      
	Srl %g1, 16, %o0                                                 

Note that it's o0 and o2 not o0 and o1.  Note that it is a 16-bit
shift not a 48-bit shift.  This code is definitely expecting 32-bit
registers.


r~



More information about the Gcc mailing list