mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
During Package CMO, SIL cloning happens during which
SILOptions::EnableSerializePackage info is lost. SILVerifier needs this info to determine whether resilience can be bypassed for decls serialized in a resiliently built module when Package CMO optimization enabled. This PR adds SerializePackageEnabled bit to Module format and uses that in SILVerifier. Resolves rdar://126157356
This commit is contained in:
@@ -200,6 +200,9 @@ static bool readOptionsBlock(llvm::BitstreamCursor &cursor,
|
||||
case options_block::ALLOW_NON_RESILIENT_ACCESS:
|
||||
extendedInfo.setAllowNonResilientAccess(true);
|
||||
break;
|
||||
case options_block::SERIALIZE_PACKAGE_ENABLED:
|
||||
extendedInfo.setSerializePackageEnabled(true);
|
||||
break;
|
||||
default:
|
||||
// Unknown options record, possibly for use by a future version of the
|
||||
// module format.
|
||||
@@ -1448,6 +1451,7 @@ ModuleFileSharedCore::ModuleFileSharedCore(
|
||||
Bits.IsConcurrencyChecked = extInfo.isConcurrencyChecked();
|
||||
Bits.HasCxxInteroperability = extInfo.hasCxxInteroperability();
|
||||
Bits.AllowNonResilientAccess = extInfo.allowNonResilientAccess();
|
||||
Bits.SerializePackageEnabled = extInfo.serializePackageEnabled();
|
||||
MiscVersion = info.miscVersion;
|
||||
ModuleABIName = extInfo.getModuleABIName();
|
||||
ModulePackageName = extInfo.getModulePackageName();
|
||||
|
||||
Reference in New Issue
Block a user