Copying SI regs as HI subregs

D. Towner towner@compsci.bristol.ac.uk
Thu Feb 28 04:58:00 GMT 2002


Hi all,

I am porting gcc to a machine which uses 2 HImode regs to represent an
SImode reg. Currently, a movsi instruction emits two register moves to
copy the value:

MOVE lowpartSrc, lowpartDest
MOVE highpartSRC, highpartDest

Is it more efficient to use RTL to generate the two subreg moves
explicitly?  Does this present opportunities for optimisation if gcc knows
that two such instructions are used, rather than a single atomic movsi
instruction? How can I go about actually generating the RTL if this is the
case?

Thanks,

Dan.




More information about the Gcc mailing list