@@ -199,7 +199,7 @@ static InstCount ComputeSLILStaticLowerBound(int64_t regTypeCnt_,
199
199
// between the recursive successor list of this instruction and the
200
200
// recursive predecessors of the dependent instruction.
201
201
auto recSuccBV = inst->GetRcrsvNghbrBitVector (DIR_FRWRD);
202
- for (Register *def : inst->GetDefs ()) {
202
+ for (opt_sched:: Register *def : inst->GetDefs ()) {
203
203
for (const auto &dependentInst : def->GetUseList ()) {
204
204
auto recPredBV = const_cast <SchedInstruction *>(dependentInst)
205
205
->GetRcrsvNghbrBitVector (DIR_BKWRD);
@@ -225,14 +225,15 @@ static InstCount ComputeSLILStaticLowerBound(int64_t regTypeCnt_,
225
225
// based on the instructions that use more than one register (defined by
226
226
// different instructions).
227
227
int commonUseLowerBound = closureLowerBound;
228
- std::vector<std::pair<const SchedInstruction *, Register *>> usedInsts;
228
+ std::vector<std::pair<const SchedInstruction *, opt_sched::Register *>>
229
+ usedInsts;
229
230
for (int i = 0 ; i < dataDepGraph_->GetInstCnt (); ++i) {
230
231
const auto &inst = dataDepGraph_->GetInstByIndx (i);
231
232
232
233
// Get a list of instructions that define the registers, in array form.
233
234
usedInsts.clear ();
234
235
llvm::transform (inst->GetUses (), std::back_inserter (usedInsts),
235
- [&](Register *reg) {
236
+ [&](opt_sched:: Register *reg) {
236
237
assert (reg->GetDefList ().size () == 1 &&
237
238
" Number of defs for register is not 1!" );
238
239
return std::make_pair (*(reg->GetDefList ().begin ()), reg);
@@ -477,7 +478,7 @@ void BBWithSpill::UpdateSpillInfoForSchdul_(SchedInstruction *inst,
477
478
#endif
478
479
479
480
// Update Live regs after uses
480
- for (Register *use : inst->GetUses ()) {
481
+ for (opt_sched:: Register *use : inst->GetUses ()) {
481
482
regType = use->GetType ();
482
483
regNum = use->GetNum ();
483
484
physRegNum = use->GetPhysicalNumber ();
@@ -519,7 +520,7 @@ void BBWithSpill::UpdateSpillInfoForSchdul_(SchedInstruction *inst,
519
520
}
520
521
521
522
// Update Live regs after defs
522
- for (Register *def : inst->GetDefs ()) {
523
+ for (opt_sched:: Register *def : inst->GetDefs ()) {
523
524
regType = def->GetType ();
524
525
regNum = def->GetNum ();
525
526
physRegNum = def->GetPhysicalNumber ();
@@ -575,7 +576,7 @@ void BBWithSpill::UpdateSpillInfoForSchdul_(SchedInstruction *inst,
575
576
sumOfLiveIntervalLengths_[i] += liveRegs_[i].GetOneCnt ();
576
577
for (int j = 0 ; j < liveRegs_[i].GetSize (); ++j) {
577
578
if (liveRegs_[i].GetBit (j)) {
578
- const Register *reg = regFiles_[i].GetReg (j);
579
+ const opt_sched:: Register *reg = regFiles_[i].GetReg (j);
579
580
if (!reg->IsInInterval (inst) && !reg->IsInPossibleInterval (inst)) {
580
581
++dynamicSlilLowerBound_;
581
582
}
@@ -636,7 +637,7 @@ void BBWithSpill::UpdateSpillInfoForUnSchdul_(SchedInstruction *inst) {
636
637
for (int i = 0 ; i < regTypeCnt_; ++i) {
637
638
for (int j = 0 ; j < liveRegs_[i].GetSize (); ++j) {
638
639
if (liveRegs_[i].GetBit (j)) {
639
- const Register *reg = regFiles_[i].GetReg (j);
640
+ const opt_sched:: Register *reg = regFiles_[i].GetReg (j);
640
641
sumOfLiveIntervalLengths_[i]--;
641
642
if (!reg->IsInInterval (inst) && !reg->IsInPossibleInterval (inst)) {
642
643
--dynamicSlilLowerBound_;
@@ -649,7 +650,7 @@ void BBWithSpill::UpdateSpillInfoForUnSchdul_(SchedInstruction *inst) {
649
650
}
650
651
651
652
// Update Live regs
652
- for (Register *def : inst->GetDefs ()) {
653
+ for (opt_sched:: Register *def : inst->GetDefs ()) {
653
654
regType = def->GetType ();
654
655
regNum = def->GetNum ();
655
656
physRegNum = def->GetPhysicalNumber ();
@@ -674,7 +675,7 @@ void BBWithSpill::UpdateSpillInfoForUnSchdul_(SchedInstruction *inst) {
674
675
// }
675
676
}
676
677
677
- for (Register *use : inst->GetUses ()) {
678
+ for (opt_sched:: Register *use : inst->GetUses ()) {
678
679
regType = use->GetType ();
679
680
regNum = use->GetNum ();
680
681
physRegNum = use->GetPhysicalNumber ();
@@ -1091,8 +1092,8 @@ bool BBWithSpill::ChkInstLglty(SchedInstruction *inst) {
1091
1092
/*
1092
1093
int16_t regType;
1093
1094
int defCnt, physRegNum;
1094
- Register **defs;
1095
- Register *def, *liveDef;
1095
+ opt_sched:: Register **defs;
1096
+ opt_sched:: Register *def, *liveDef;
1096
1097
1097
1098
#ifdef IS_DEBUG_CHECK
1098
1099
Logger::Info("Checking inst %d %s", inst->GetNum(), inst->GetOpCode());
@@ -1111,7 +1112,7 @@ bool BBWithSpill::ChkInstLglty(SchedInstruction *inst) {
1111
1112
}
1112
1113
1113
1114
// Update Live regs
1114
- for (Register *def : inst->GetDefs()) {
1115
+ for (opt_sched:: Register *def : inst->GetDefs()) {
1115
1116
regType = def->GetType();
1116
1117
physRegNum = def->GetPhysicalNumber();
1117
1118
0 commit comments