@@ -1145,11 +1145,10 @@ struct PartitionOpBuilder {
1145
1145
currentInstPartitionOps.clear ();
1146
1146
}
1147
1147
1148
- TrackableValueID lookupValueID (SILValue value);
1148
+ Element lookupValueID (SILValue value);
1149
1149
bool valueHasID (SILValue value, bool dumpIfHasNoID = false );
1150
1150
1151
- TrackableValueID
1152
- getActorIntroducingRepresentative (SILIsolationInfo actorIsolation);
1151
+ Element getActorIntroducingRepresentative (SILIsolationInfo actorIsolation);
1153
1152
1154
1153
void addAssignFresh (SILValue value) {
1155
1154
currentInstPartitionOps.emplace_back (
@@ -1160,7 +1159,7 @@ struct PartitionOpBuilder {
1160
1159
assert (valueHasID (src, /* dumpIfHasNoID=*/ true ) &&
1161
1160
" source value of assignment should already have been encountered" );
1162
1161
1163
- TrackableValueID srcID = lookupValueID (src);
1162
+ Element srcID = lookupValueID (src);
1164
1163
if (lookupValueID (tgt) == srcID) {
1165
1164
LLVM_DEBUG (llvm::dbgs () << " Skipping assign since tgt and src have "
1166
1165
" the same representative.\n " );
@@ -1501,7 +1500,7 @@ class PartitionOpTranslator {
1501
1500
return partialApplyReachabilityDataflow.isReachable (value, inst);
1502
1501
}
1503
1502
1504
- std::optional<TrackableValue> getValueForId (TrackableValueID id) const {
1503
+ std::optional<TrackableValue> getValueForId (Element id) const {
1505
1504
return valueMap.getValueForId (id);
1506
1505
}
1507
1506
@@ -1542,7 +1541,7 @@ class PartitionOpTranslator {
1542
1541
return valueMap.valueHasID (value, dumpIfHasNoID);
1543
1542
}
1544
1543
1545
- TrackableValueID lookupValueID (SILValue value) {
1544
+ Element lookupValueID (SILValue value) {
1546
1545
return valueMap.lookupValueID (value);
1547
1546
}
1548
1547
@@ -2288,11 +2287,11 @@ class PartitionOpTranslator {
2288
2287
} // namespace regionanalysisimpl
2289
2288
} // namespace swift
2290
2289
2291
- TrackableValueID PartitionOpBuilder::lookupValueID (SILValue value) {
2290
+ Element PartitionOpBuilder::lookupValueID (SILValue value) {
2292
2291
return translator->lookupValueID (value);
2293
2292
}
2294
2293
2295
- TrackableValueID PartitionOpBuilder::getActorIntroducingRepresentative (
2294
+ Element PartitionOpBuilder::getActorIntroducingRepresentative (
2296
2295
SILIsolationInfo actorIsolation) {
2297
2296
return translator
2298
2297
->getActorIntroducingRepresentative (currentInst, actorIsolation)
@@ -2332,17 +2331,17 @@ void PartitionOpBuilder::print(llvm::raw_ostream &os) const {
2332
2331
2333
2332
// Now print out a translation from region to equivalence class value.
2334
2333
llvm::dbgs () << " └─────╼ Used Values\n " ;
2335
- llvm::SmallVector<TrackableValueID , 8 > opsToPrint;
2334
+ llvm::SmallVector<Element , 8 > opsToPrint;
2336
2335
SWIFT_DEFER { opsToPrint.clear (); };
2337
2336
for (const PartitionOp &op : ops) {
2338
2337
// Now dump our the root value we map.
2339
2338
for (unsigned opArg : op.getOpArgs ()) {
2340
2339
// If we didn't insert, skip this. We only emit this once.
2341
- opsToPrint.push_back (TrackableValueID (opArg));
2340
+ opsToPrint.push_back (Element (opArg));
2342
2341
}
2343
2342
}
2344
2343
sortUnique (opsToPrint);
2345
- for (TrackableValueID opArg : opsToPrint) {
2344
+ for (Element opArg : opsToPrint) {
2346
2345
llvm::dbgs () << " └╼ " ;
2347
2346
auto trackableValue = translator->getValueForId (opArg);
2348
2347
assert (trackableValue);
@@ -3193,7 +3192,7 @@ SILInstruction *RegionAnalysisValueMap::maybeGetActorIntroducingInst(
3193
3192
}
3194
3193
3195
3194
std::optional<TrackableValue>
3196
- RegionAnalysisValueMap::getValueForId (TrackableValueID id) const {
3195
+ RegionAnalysisValueMap::getValueForId (Element id) const {
3197
3196
auto iter = stateIndexToEquivalenceClass.find (id);
3198
3197
if (iter == stateIndexToEquivalenceClass.end ())
3199
3198
return {};
@@ -3570,7 +3569,7 @@ bool RegionAnalysisValueMap::valueHasID(SILValue value, bool dumpIfHasNoID) {
3570
3569
return hasID;
3571
3570
}
3572
3571
3573
- TrackableValueID RegionAnalysisValueMap::lookupValueID (SILValue value) {
3572
+ Element RegionAnalysisValueMap::lookupValueID (SILValue value) {
3574
3573
auto state = getTrackableValue (value);
3575
3574
assert (state.isNonSendable () &&
3576
3575
" only non-Sendable values should be entered in the map" );
0 commit comments