summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2007-05-01 00:47:46 +0000
committerEvan Cheng <evan.cheng@apple.com>2007-05-01 00:47:46 +0000
commit366feaed9120a24deff17fcc6b1ab2b27dc0f419 (patch)
tree2cb6ba8ed776f07052fe4008e2ff04c2d1170231 /llvm
parent8a1620195332ab9790aaac2b65d4a62f788a8762 (diff)
downloadbcm5719-llvm-366feaed9120a24deff17fcc6b1ab2b27dc0f419.tar.gz
bcm5719-llvm-366feaed9120a24deff17fcc6b1ab2b27dc0f419.zip
Added hook hasReservedCallFrame(). It returns true if the call frame is
included as part of the stack frame. llvm-svn: 36606
Diffstat (limited to 'llvm')
-rw-r--r--llvm/include/llvm/Target/MRegisterInfo.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/include/llvm/Target/MRegisterInfo.h b/llvm/include/llvm/Target/MRegisterInfo.h
index 2db4f2031bd..4b9389accb7 100644
--- a/llvm/include/llvm/Target/MRegisterInfo.h
+++ b/llvm/include/llvm/Target/MRegisterInfo.h
@@ -451,6 +451,15 @@ public:
/// variable sized allocas or if frame pointer elimination is disabled.
virtual bool hasFP(const MachineFunction &MF) const = 0;
+ // hasReservedCallFrame - Under normal circumstances, when a frame pointer is
+ // not required, we reserve argument space for call sites in the function
+ // immediately on entry to the current function. This eliminates the need for
+ // add/sub sp brackets around call sites. Returns true if the call frame is
+ // included as part of the stack frame.
+ virtual bool hasReservedCallFrame(MachineFunction &MF) const {
+ return !hasFP(MF);
+ }
+
/// getCallFrameSetup/DestroyOpcode - These methods return the opcode of the
/// frame setup/destroy instructions if they exist (-1 otherwise). Some
/// targets use pseudo instructions in order to abstract away the difference
OpenPOWER on IntegriCloud