diff options
author | Hal Finkel <hfinkel@anl.gov> | 2013-01-30 23:43:27 +0000 |
---|---|---|
committer | Hal Finkel <hfinkel@anl.gov> | 2013-01-30 23:43:27 +0000 |
commit | 9a79b320cb7f179118e69427bc684f2232a24bd9 (patch) | |
tree | 590dbd81775c02a9d43cf62852ea6c50917024e7 /lib/Target/PowerPC/PPCSubtarget.cpp | |
parent | ac72eb264c3a8a15cda81aaead6adc8419058666 (diff) |
PPC QPX requires a 32-byte aligned stack
On systems which support the QPX vector instructions, the stack must be
32-byte aligned.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173993 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PowerPC/PPCSubtarget.cpp')
-rw-r--r-- | lib/Target/PowerPC/PPCSubtarget.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Target/PowerPC/PPCSubtarget.cpp b/lib/Target/PowerPC/PPCSubtarget.cpp index 91beeaee68..18e4c07942 100644 --- a/lib/Target/PowerPC/PPCSubtarget.cpp +++ b/lib/Target/PowerPC/PPCSubtarget.cpp @@ -83,6 +83,12 @@ PPCSubtarget::PPCSubtarget(const std::string &TT, const std::string &CPU, // Set up darwin-specific properties. if (isDarwin()) HasLazyResolverStubs = true; + + // QPX requires a 32-byte aligned stack. Note that we need to do this if + // we're compiling for a BG/Q system regardless of whether or not QPX + // is enabled because external functions will assume this alignment. + if (hasQPX() || isBGQ()) + StackAlignment = 32; } /// SetJITMode - This is called to inform the subtarget info that we are |