SIL: introduce a PlaceholderValue and use it in the parser and deserializer.

... instead of a GlobalAddrInst.
This is cleaner and makes the handling of forward-referenced values in the deserializer a bit simpler.
This commit is contained in:
Erik Eckstein
2021-04-09 11:17:09 +02:00
parent 8e95ae8375
commit df2a89f3b3
10 changed files with 80 additions and 41 deletions

View File

@@ -169,6 +169,9 @@ void SILModule::checkForLeaks() const {
llvm::errs() << "Instructions in module: " << instsInModule << '\n';
llvm_unreachable("leaking instructions");
}
assert(PlaceholderValue::getNumPlaceholderValuesAlive() == 0 &&
"leaking placeholders");
}
void SILModule::checkForLeaksAfterDestruction() {