summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target
diff options
context:
space:
mode:
authorHal Finkel <hfinkel@anl.gov>2013-04-11 01:23:34 +0000
committerHal Finkel <hfinkel@anl.gov>2013-04-11 01:23:34 +0000
commitf29285a48757df3868c3ce72e860e4dfe0334e22 (patch)
tree0ac20f7451143680ee5f8babcab358e40bd6fd73 /llvm/lib/Target
parente822f58db4dee2ae56e306512288224979b9b5ba (diff)
downloadbcm5719-llvm-f29285a48757df3868c3ce72e860e4dfe0334e22.tar.gz
bcm5719-llvm-f29285a48757df3868c3ce72e860e4dfe0334e22.zip
Make PPCInstrInfo::isPredicated always return false
Because of how predication in implemented on PPC (only for branches), I think that this is the right thing to do. No functionality change intended. llvm-svn: 179252
Diffstat (limited to 'llvm/lib/Target')
-rw-r--r--llvm/lib/Target/PowerPC/PPCInstrInfo.cpp24
1 files changed, 8 insertions, 16 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
index c9674575d75..ccd1247a388 100644
--- a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
+++ b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
@@ -900,22 +900,14 @@ bool PPCInstrInfo::isProfitableToIfCvt(MachineBasicBlock &TMBB,
bool PPCInstrInfo::isPredicated(const MachineInstr *MI) const {
- unsigned OpC = MI->getOpcode();
- switch (OpC) {
- default:
- return false;
- case PPC::BCC:
- case PPC::BCCTR:
- case PPC::BCCTR8:
- case PPC::BCCTRL:
- case PPC::BCCTRL8:
- case PPC::BCLR:
- case PPC::BDZLR:
- case PPC::BDZLR8:
- case PPC::BDNZLR:
- case PPC::BDNZLR8:
- return true;
- }
+ // The predicated branches are identified by their type, not really by the
+ // explicit presence of a predicate. Furthermore, some of them can be
+ // predicated more than once. Because if conversion won't try to predicate
+ // any instruction which already claims to be predicated (by returning true
+ // here), always return false. In doing so, we let isPredicable() be the
+ // final word on whether not the instruction can be (further) predicated.
+
+ return false;
}
bool PPCInstrInfo::isUnpredicatedTerminator(const MachineInstr *MI) const {
OpenPOWER on IntegriCloud