Re: how to set some value at a memory location in stack

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Vaibhav Shrimali <vaibhav.shrimali@xxxxxxxxx> writes:

> I am performing this task in the prologue in the section where the
> hard frame pointer is pushed on the stack.

This is after register allocation, so you can not use force_reg.

> If not, please tell me how and where can I allocate the register and
> then use my code accordingly.

You have to figure out a hard register to use.  It should be safe to
use any call used register in the prologue, as long as it is not being
used for anything else in the prologue.  If you want this to be
generally useful, watch out for the regparm attribute.  The prologue
code is full of examples of using registers; read it and understand
what it is doing.

Ian

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux