mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
SIL Linker: clear the [serialized] flag when deserializing a function into a module that's already had the serialized flag stripped out.
This commit is contained in:
@@ -311,6 +311,13 @@ bool SILLinkerVisitor::process() {
|
||||
while (!Worklist.empty()) {
|
||||
auto *Fn = Worklist.pop_back_val();
|
||||
|
||||
if (Fn->getModule().isSerialized()) {
|
||||
// If the containing module has been serialized,
|
||||
// Remove The Serialized state (if any)
|
||||
// This allows for more optimizations
|
||||
Fn->setSerialized(IsSerialized_t::IsNotSerialized);
|
||||
}
|
||||
|
||||
DEBUG(llvm::dbgs() << "Process imports in function: "
|
||||
<< Fn->getName() << "\n");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user