diff options
author | Anton Korobeynikov <asl@math.spbu.ru> | 2010-04-07 18:19:32 +0000 |
---|---|---|
committer | Anton Korobeynikov <asl@math.spbu.ru> | 2010-04-07 18:19:32 +0000 |
commit | 96085a36dbb9cf251c81bc150e41ea9c952c99c0 (patch) | |
tree | 11f979db3890993a7fbe28524bba4ff6870449b2 /utils/TableGen/SubtargetEmitter.cpp | |
parent | 1298948c5c36e6e88cbde0abe73f7f37c3a038a6 (diff) |
Initial support for different kinds of FU reservation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100645 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/TableGen/SubtargetEmitter.cpp')
-rw-r--r-- | utils/TableGen/SubtargetEmitter.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/utils/TableGen/SubtargetEmitter.cpp b/utils/TableGen/SubtargetEmitter.cpp index 9ac652f799..fb86a704c4 100644 --- a/utils/TableGen/SubtargetEmitter.cpp +++ b/utils/TableGen/SubtargetEmitter.cpp @@ -216,7 +216,7 @@ void SubtargetEmitter::FormItineraryStageString(Record *ItinData, // Next stage const Record *Stage = StageList[i]; - // Form string as ,{ cycles, u1 | u2 | ... | un, timeinc } + // Form string as ,{ cycles, u1 | u2 | ... | un, timeinc, kind } int Cycles = Stage->getValueAsInt("Cycles"); ItinString += " { " + itostr(Cycles) + ", "; @@ -233,6 +233,9 @@ void SubtargetEmitter::FormItineraryStageString(Record *ItinData, int TimeInc = Stage->getValueAsInt("TimeInc"); ItinString += ", " + itostr(TimeInc); + int Kind = Stage->getValueAsInt("Kind"); + ItinString += ", (llvm::InstrStage::ReservationKinds)" + itostr(Kind); + // Close off stage ItinString += " }"; if (++i < N) ItinString += ", "; @@ -278,7 +281,7 @@ void SubtargetEmitter::EmitStageAndOperandCycleData(raw_ostream &OS, // Begin stages table std::string StageTable = "static const llvm::InstrStage Stages[] = {\n"; - StageTable += " { 0, 0, 0 }, // No itinerary\n"; + StageTable += " { 0, 0, 0, llvm::InstrStage::Required }, // No itinerary\n"; // Begin operand cycle table std::string OperandCycleTable = "static const unsigned OperandCycles[] = {\n"; @@ -367,7 +370,7 @@ void SubtargetEmitter::EmitStageAndOperandCycleData(raw_ostream &OS, } // Closing stage - StageTable += " { 0, 0, 0 } // End itinerary\n"; + StageTable += " { 0, 0, 0, llvm::InstrStage::Required } // End itinerary\n"; StageTable += "};\n"; // Closing operand cycles |