aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
diff options
context:
space:
mode:
authorHal Finkel <hfinkel@anl.gov>2014-03-24 09:51:41 +0000
committerHal Finkel <hfinkel@anl.gov>2014-03-24 09:51:41 +0000
commit32854b0439cfb667af122cb04d562e87102342f4 (patch)
treefea6b48f130bad3cbcad40541b72341167d7df32 /llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
parent1847401332ddc3a15fc35e07cc07707ae6c21f81 (diff)
downloadllvm-32854b0439cfb667af122cb04d562e87102342f4.zip
llvm-32854b0439cfb667af122cb04d562e87102342f4.tar.gz
llvm-32854b0439cfb667af122cb04d562e87102342f4.tar.bz2
[PowerPC] Don't schedule VSX copy legalization unless VSX is enabled
There is no need to schedule this extra pass if it will have nothing to do. llvm-svn: 204594
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCTargetMachine.cpp')
-rw-r--r--llvm/lib/Target/PowerPC/PPCTargetMachine.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
index 2449abf..ff226389 100644
--- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
@@ -160,7 +160,8 @@ bool PPCPassConfig::addInstSelector() {
addPass(createPPCCTRLoopsVerify());
#endif
- addPass(createPPCVSXCopyPass());
+ if (getPPCSubtarget().hasVSX())
+ addPass(createPPCVSXCopyPass());
return false;
}