summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/MachineFunction.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-02-14 05:52:17 +0000
committerChris Lattner <sabre@nondot.org>2007-02-14 05:52:17 +0000
commit945e437c65a6e354bdb090ccabf4a3d374edf231 (patch)
treebc114a3c6f82141eff39a63020dc4852b866ad42 /llvm/lib/CodeGen/MachineFunction.cpp
parent0c5db231198bca3c416790edab01d47ef7ae6154 (diff)
downloadbcm5719-llvm-945e437c65a6e354bdb090ccabf4a3d374edf231.tar.gz
bcm5719-llvm-945e437c65a6e354bdb090ccabf4a3d374edf231.zip
Generalize TargetData strings, to support more interesting forms of data.
Patch by Scott Michel. llvm-svn: 34266
Diffstat (limited to 'llvm/lib/CodeGen/MachineFunction.cpp')
-rw-r--r--llvm/lib/CodeGen/MachineFunction.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachineFunction.cpp b/llvm/lib/CodeGen/MachineFunction.cpp
index 0cba1567e18..5ae73ca40a0 100644
--- a/llvm/lib/CodeGen/MachineFunction.cpp
+++ b/llvm/lib/CodeGen/MachineFunction.cpp
@@ -13,6 +13,7 @@
//
//===----------------------------------------------------------------------===//
+#include "llvm/DerivedTypes.h"
#include "llvm/CodeGen/MachineFunctionPass.h"
#include "llvm/CodeGen/MachineInstr.h"
#include "llvm/CodeGen/SSARegMap.h"
@@ -123,7 +124,7 @@ MachineFunction::MachineFunction(const Function *F,
const TargetData &TD = *TM.getTargetData();
bool IsPic = TM.getRelocationModel() == Reloc::PIC_;
unsigned EntrySize = IsPic ? 4 : TD.getPointerSize();
- unsigned Alignment = IsPic ? TD.getIntABIAlignment()
+ unsigned Alignment = IsPic ? TD.getABITypeAlignment(Type::Int32Ty)
: TD.getPointerABIAlignment();
JumpTableInfo = new MachineJumpTableInfo(EntrySize, Alignment);
OpenPOWER on IntegriCloud