misched: fall-back to a target hook for instr bundles.

llvm-svn: 165606
This commit is contained in:
Andrew Trick 2012-10-10 05:43:18 +00:00
parent 2a06d4753a
commit c334bd4577
1 changed files with 4 additions and 3 deletions

View File

@ -203,10 +203,11 @@ unsigned TargetSchedModel::computeOperandLatency(
}
unsigned TargetSchedModel::computeInstrLatency(const MachineInstr *MI) const {
if (hasInstrItineraries()) {
// For the itinerary model, fall back to the old subtarget hook.
// For the itinerary model, fall back to the old subtarget hook.
// Allow subtargets to compute Bundle latencies outside the machine model.
if (hasInstrItineraries() || MI->isBundle())
return TII->getInstrLatency(&InstrItins, MI);
}
if (hasInstrSchedModel()) {
unsigned Latency = 0;
const MCSchedClassDesc *SCDesc = resolveSchedClass(MI);