"Rohit Arul Raj" <[EMAIL PROTECTED]> writes: > 1. How do i get the stack alignment size of a particular target? > Does #define STACK_BOUNDARY 32 serve this purpose?
STACK_BOUNDARY is used to express the alignment maintained by the hardware. In practice this means that gcc can expect the stack to be aligned to that boundary at function entry, and that gcc must maintain that stack alignment when calling a function. In some cases maintaining that alignment may need to be implemented in the function calling sequence. > 2. Is it possible to override the STACK Alignment in ld file using ALIGN()? No, that does not make sense. > 3. Difference between stack alignment and data alignment? One applies to the stack, which holds local variables, and the other applies to global and static variables. Ian