[semantic-arc-opts] Change Semantic ARC Opts to run only on the stdlib so it only sees ownership verified SIL.

The reason why I am doing this is now that once we have the
OperandOwnershipKindMap I can write this optimization in a more robust,
aggressive manner. My hope is that I can eliminate all copy_value of guaranteed
parameters all of whose uses could accept a guaranteed parameter. This is given
to me by the OperandOwnershipKindMap.

Additionally, I found that the way the analysis was using the OwnershipVerifier
was not sound on non-ownership verified SIL. Rather than fix it, I just turned
it off for that case.

rdar://44667493
This commit is contained in:
Michael Gottesman
2018-10-01 20:16:05 -07:00
parent b9b568b6ec
commit 2e63b4c830
4 changed files with 10 additions and 1 deletions

View File

@@ -660,6 +660,10 @@ void SILModule::setOptRecordStream(
OptRecordRawStream = std::move(RawStream);
}
bool SILModule::isStdlibModule() const {
return TheSwiftModule->isStdlibModule();
}
SILProperty *SILProperty::create(SILModule &M,
bool Serialized,
AbstractStorageDecl *Decl,