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: How to control the offset for stack operation?


On 4/16/07, J.C. Pizarro <jcpiza@gmail.com> wrote:
2007/4/16, Mohamed Shafi <shafitvm@gmail.com>:
> hello all,
>
> Depending on the machine mode the compiler will generate automatically
> the offset required for the stack operation i.e for a machine with
> word size is 32, for char type the offset is 1, for int type the
> offset is 2 and so on..
>
> Is there a way to control this ? i mean say for long long the offset
> is 4 if long long is mapped to TI mode and i want the generate the
> offset such that it is 2.
>
> Is there a way to do this in gcc ?
>
> Regards,
> Shafi
>

For a x86 machine, the stack's offset always is multiple of 4 bytes.

long long is NOT 4 bytes, is 8 bytes!

I was not talking about the size of long long but the offset i.e 4x32, required for stack operation. I want gcc to generate the code such that the offset is 2 (64 bytes)and not 4 (128 bytes)

Is there a way to do this?


Sincerely J.C. Pizarro :)




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