aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/TargetInfo.cpp
diff options
context:
space:
mode:
authorAkira Hatanaka <ahatanaka@mips.com>2011-11-03 00:05:50 +0000
committerAkira Hatanaka <ahatanaka@mips.com>2011-11-03 00:05:50 +0000
commitb551dd31f6b15aa959127ee906084fcf5bf0154e (patch)
tree0c4e7da1db780f73e5be0e4a35d60090fba7975f /lib/CodeGen/TargetInfo.cpp
parentd5a257f39b6f78fb66bb0227486b65592476c572 (diff)
Set MinABIStackAlignInBytes to 8 if ABI is N32/64.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143597 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/TargetInfo.cpp')
-rw-r--r--lib/CodeGen/TargetInfo.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/CodeGen/TargetInfo.cpp b/lib/CodeGen/TargetInfo.cpp
index 83cddb2d80..2bd341ce21 100644
--- a/lib/CodeGen/TargetInfo.cpp
+++ b/lib/CodeGen/TargetInfo.cpp
@@ -2992,11 +2992,12 @@ void MSP430TargetCodeGenInfo::SetTargetAttributes(const Decl *D,
namespace {
class MipsABIInfo : public ABIInfo {
- static const unsigned MinABIStackAlignInBytes = 4;
bool IsO32;
+ unsigned MinABIStackAlignInBytes;
llvm::Type* HandleStructTy(QualType Ty) const;
public:
- MipsABIInfo(CodeGenTypes &CGT, bool _IsO32) : ABIInfo(CGT), IsO32(_IsO32) {}
+ MipsABIInfo(CodeGenTypes &CGT, bool _IsO32) :
+ ABIInfo(CGT), IsO32(_IsO32), MinABIStackAlignInBytes(IsO32 ? 4 : 8) {}
ABIArgInfo classifyReturnType(QualType RetTy) const;
ABIArgInfo classifyArgumentType(QualType RetTy) const;
@@ -3005,8 +3006,6 @@ public:
CodeGenFunction &CGF) const;
};
-const unsigned MipsABIInfo::MinABIStackAlignInBytes;
-
class MIPSTargetCodeGenInfo : public TargetCodeGenInfo {
unsigned SizeOfUnwindException;
public: