This is the mail archive of the gcc-help@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]

Looking for advice on manipulating asm code



Hi,

I am not sure if this is the right place to ask this question, but I
couldn't find any other forum. 

How difficult is it to manipulate the target asm code such that all
instructions that need similar execution units are grouped together
(taking care of dependencies, of course).

Eg. Mul ...
    Add ...
    Mul ...

would be reordered as:

    Mul ...
    Mul ...
    Add ...

if the last two instructions can be interchanged.

I tried looking at the gcc code, but I couldn't determine how easy it would
be to modify gcc itself. I am looking for suggestions on whether I should
delve into gcc, or write a post-processor which directly works on the asm.

Thanks for any tips.  I'm not subscribed to these lists. I'll check the
archives in a few days, but I'd appreciate it if any responses could also be
mailed to me at pant@ee.gatech.edu.

- Pankaj.

PS: the code is targeted at the SimpleScalar architecture, for which a 
    compiler (derived from gcc), simulator and other tools can be found at:

    http://www.cs.wisc.edu/~mscalar/simplescalar.html



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