summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2006-12-08 07:57:56 +0000
committerEvan Cheng <evan.cheng@apple.com>2006-12-08 07:57:56 +0000
commitb5f1c22e94a7989198e6e4480056c48dc0f28ecb (patch)
tree2512ef3766e2d0233601a36a426e84c7b4549a1b /llvm/lib
parent5040f58ae437ccdf0fd97b418a3cc08c2f4b83c4 (diff)
downloadbcm5719-llvm-b5f1c22e94a7989198e6e4480056c48dc0f28ecb.tar.gz
bcm5719-llvm-b5f1c22e94a7989198e6e4480056c48dc0f28ecb.zip
Use MI's TargetInstrDescriptor.
llvm-svn: 32352
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/TargetInstrInfo.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/llvm/lib/Target/TargetInstrInfo.cpp b/llvm/lib/Target/TargetInstrInfo.cpp
index c29b1c54b4f..0e79baac7c9 100644
--- a/llvm/lib/Target/TargetInstrInfo.cpp
+++ b/llvm/lib/Target/TargetInstrInfo.cpp
@@ -27,13 +27,12 @@ TargetInstrInfo::~TargetInstrInfo() {
/// findTiedToSrcOperand - Returns the operand that is tied to the specified
/// dest operand. Returns -1 if there isn't one.
-int
-TargetInstrInfo::findTiedToSrcOperand(MachineOpCode Opc, unsigned OpNum) const {
- for (unsigned i = 0, e = getNumOperands(Opc); i != e; ++i) {
+int TargetInstrInfo::findTiedToSrcOperand(const TargetInstrDescriptor *TID,
+ unsigned OpNum) const {
+ for (unsigned i = 0, e = TID->numOperands; i != e; ++i) {
if (i == OpNum)
continue;
- int ti = getOperandConstraint(Opc, i, TOI::TIED_TO);
- if (ti == (int)OpNum)
+ if (TID->getOperandConstraint(i, TOI::TIED_TO) == (int)OpNum)
return i;
}
return -1;
OpenPOWER on IntegriCloud