Commit Graph

7 Commits

Author SHA1 Message Date
Bob Wilson d60367c198 pr4926: ARM requires the stack pointer to be aligned, even for leaf functions.
For the AAPCS ABI, SP must always be 4-byte aligned, and at any "public
interface" it must be 8-byte aligned.  For the older ARM APCS ABI, the stack
alignment is just always 4 bytes.  For X86, we currently align SP at
entry to a function (e.g., to 16 bytes for Darwin), but no stack alignment
is needed at other times, such as for a leaf function.

After discussing this with Dan, I decided to go with the approach of adding
a new "TransientStackAlignment" field to TargetFrameInfo.  This value
specifies the stack alignment that must be maintained even in between calls.
It defaults to 1 except for ARM, where it is 4.  (Some other targets may
also want to set this if they have similar stack requirements. It's not
currently required for PPC because it sets targetHandlesStackFrameRounding
and handles the alignment in target-specific code.) The existing StackAlignment
value specifies the alignment upon entry to a function, which is how we've
been using it anyway.

llvm-svn: 82767
2009-09-25 14:41:49 +00:00
Evan Cheng 27e32c092e Reorg includes.
llvm-svn: 75115
2009-07-09 06:49:09 +00:00
Chris Lattner f3ebc3f3d2 Remove attribution from file headers, per discussion on llvmdev.
llvm-svn: 45418
2007-12-29 20:36:04 +00:00
Dan Gohman e379f08b19 More explicit keywords.
llvm-svn: 40589
2007-07-30 14:51:59 +00:00
Evan Cheng 10043e215b ARM backend contribution from Apple.
llvm-svn: 33353
2007-01-19 07:51:42 +00:00
Rafael Espindola 98dc23fd1f use @ for comments
store LR in an arbitrary stack slot
add support for writing varargs functions

llvm-svn: 29876
2006-08-25 17:55:16 +00:00
Rafael Espindola bf8e751488 Declare the callee saved regs
Remove the hard coded store and load of the link register
Implement ARMFrameInfo

llvm-svn: 29727
2006-08-16 14:43:33 +00:00