[Caching] Support CrossImport modules for caching build

Add support for cross import modules by ingesting swiftoverlay files for
the cross import into CAS file system.

The long-term better fix will be just passing the cross import
information from scanner to swift-frontend so frontend doesn't need to
read overlay files again to figure out the cross import module.

rdar://123839248
This commit is contained in:
Steven Wu
2024-03-01 13:50:02 -08:00
parent 6e18ffe729
commit cdd1ac91a8
8 changed files with 176 additions and 83 deletions

View File

@@ -72,9 +72,8 @@ public:
DiagnosticEngine &diags, bool ParallelScan);
/// Identify the scanner invocation's main module's dependencies
llvm::ErrorOr<ModuleDependencyInfo> getMainModuleDependencyInfo(
ModuleDecl *mainModule,
std::optional<SwiftDependencyTracker> tracker = std::nullopt);
llvm::ErrorOr<ModuleDependencyInfo>
getMainModuleDependencyInfo(ModuleDecl *mainModule);
/// Resolve module dependencies of the given module, computing a full
/// transitive closure dependency graph.