[llvm-commits] [llvm] r63119 - /llvm/trunk/lib/Target/PowerPC/PPCRegisterInfo.cpp

Dan Gohman gohman at apple.com
Tue Jan 27 11:19:28 PST 2009


Author: djg
Date: Tue Jan 27 13:19:28 2009
New Revision: 63119

URL: http://llvm.org/viewvc/llvm-project?rev=63119&view=rev
Log:
Respect the DisableRedZone flag on PowerPC.

Modified:
    llvm/trunk/lib/Target/PowerPC/PPCRegisterInfo.cpp

Modified: llvm/trunk/lib/Target/PowerPC/PPCRegisterInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/PowerPC/PPCRegisterInfo.cpp?rev=63119&r1=63118&r2=63119&view=diff

==============================================================================
--- llvm/trunk/lib/Target/PowerPC/PPCRegisterInfo.cpp (original)
+++ llvm/trunk/lib/Target/PowerPC/PPCRegisterInfo.cpp Tue Jan 27 13:19:28 2009
@@ -893,7 +893,8 @@
   // If we are a leaf function, and use up to 224 bytes of stack space,
   // don't have a frame pointer, calls, or dynamic alloca then we do not need
   // to adjust the stack pointer (we fit in the Red Zone).
-  if (FrameSize <= 224 &&                          // Fits in red zone.
+  if (!DisableRedZone &&
+      FrameSize <= 224 &&                          // Fits in red zone.
       !MFI->hasVarSizedObjects() &&                // No dynamic alloca.
       !MFI->hasCalls() &&                          // No calls.
       (!ALIGN_STACK || MaxAlign <= TargetAlign)) { // No special alignment.





More information about the llvm-commits mailing list