aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/TargetInstrInfoImpl.cpp
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2012-07-02 18:10:42 +0000
committerAndrew Trick <atrick@apple.com>2012-07-02 18:10:42 +0000
commit218ee74a011c0d350099c452810da0bd57a15047 (patch)
tree58e25d935c68661cd1654a02633e20c3a5c2ea56 /lib/CodeGen/TargetInstrInfoImpl.cpp
parent7c3a65c7edceb3a013cf49d376c3bc016eb871bf (diff)
Reapply "Make NumMicroOps a variable in the subtarget's instruction itinerary."
Reapplies r159406 with minor cleanup. The regressions appear to have been spurious. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159541 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/TargetInstrInfoImpl.cpp')
-rw-r--r--lib/CodeGen/TargetInstrInfoImpl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/TargetInstrInfoImpl.cpp b/lib/CodeGen/TargetInstrInfoImpl.cpp
index 7af08f591f..54be88a8bb 100644
--- a/lib/CodeGen/TargetInstrInfoImpl.cpp
+++ b/lib/CodeGen/TargetInstrInfoImpl.cpp
@@ -560,8 +560,8 @@ TargetInstrInfoImpl::getNumMicroOps(const InstrItineraryData *ItinData,
return 1;
unsigned Class = MI->getDesc().getSchedClass();
- unsigned UOps = ItinData->Itineraries[Class].NumMicroOps;
- if (UOps)
+ int UOps = ItinData->Itineraries[Class].NumMicroOps;
+ if (UOps >= 0)
return UOps;
// The # of u-ops is dynamically determined. The specific target should