summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
diff options
context:
space:
mode:
authorAditya Nandakumar <aditya_nandakumar@apple.com>2014-11-13 09:26:31 +0000
committerAditya Nandakumar <aditya_nandakumar@apple.com>2014-11-13 09:26:31 +0000
commita27193297f76d9847ec6c62042444a0c69b7dac7 (patch)
treeba5bf0e2f6265070a71090a97cc6ffb94b320b2d /llvm/lib/Target/PowerPC/PPCISelLowering.cpp
parent8e586617c462178145cad3563bcfd7e9c30fdf67 (diff)
downloadbcm5719-llvm-a27193297f76d9847ec6c62042444a0c69b7dac7.tar.gz
bcm5719-llvm-a27193297f76d9847ec6c62042444a0c69b7dac7.zip
This patch changes the ownership of TLOF from TargetLoweringBase to TargetMachine so that different subtargets could share the TLOF effectively
llvm-svn: 221878
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCISelLowering.cpp')
-rw-r--r--llvm/lib/Target/PowerPC/PPCISelLowering.cpp11
1 files changed, 1 insertions, 10 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
index 17bf813521a..38656df9998 100644
--- a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
+++ b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
@@ -55,17 +55,8 @@ cl::desc("disable unaligned load/store generation on PPC"), cl::Hidden);
// FIXME: Remove this once the bug has been fixed!
extern cl::opt<bool> ANDIGlueBug;
-static TargetLoweringObjectFile *createTLOF(const Triple &TT) {
- // If it isn't a Mach-O file then it's going to be a linux ELF
- // object file.
- if (TT.isOSDarwin())
- return new TargetLoweringObjectFileMachO();
-
- return new PPC64LinuxTargetObjectFile();
-}
-
PPCTargetLowering::PPCTargetLowering(const PPCTargetMachine &TM)
- : TargetLowering(TM, createTLOF(Triple(TM.getTargetTriple()))),
+ : TargetLowering(TM, TM.getObjFileLowering()),
Subtarget(*TM.getSubtargetImpl()) {
setPow2SDivIsCheap();
OpenPOWER on IntegriCloud