mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[ParseableInterface] Add ‘forwarding modules’
A ‘forwarding module’ is a YAML file that’s meant to stand in for a .swiftmodule file and provide an up-to-date description of its dependencies, always using modification times. When a ‘prebuilt module’ is first loaded, we verify that it’s up-to-date by hashing all of its dependencies. Since this is orders of magnitude slower than reading mtimes, we’ll install a `forwarding module` containing the mtimes of the now-validated dependencies.
This commit is contained in:
@@ -51,6 +51,7 @@
|
||||
#include "swift/Frontend/Frontend.h"
|
||||
#include "swift/Frontend/PrintingDiagnosticConsumer.h"
|
||||
#include "swift/Frontend/SerializedDiagnosticConsumer.h"
|
||||
#include "swift/Frontend/ParseableInterfaceModuleLoader.h"
|
||||
#include "swift/Frontend/ParseableInterfaceSupport.h"
|
||||
#include "swift/Immediate/Immediate.h"
|
||||
#include "swift/Index/IndexRecord.h"
|
||||
@@ -585,7 +586,8 @@ static bool buildModuleFromParseableInterface(CompilerInvocation &Invocation,
|
||||
return ParseableInterfaceModuleLoader::buildSwiftModuleFromSwiftInterface(
|
||||
Instance.getASTContext(), Invocation.getClangModuleCachePath(),
|
||||
PrebuiltCachePath, Invocation.getModuleName(), InputPath,
|
||||
Invocation.getOutputFilename());
|
||||
Invocation.getOutputFilename(),
|
||||
FEOpts.SerializeParseableModuleInterfaceDependencyHashes);
|
||||
}
|
||||
|
||||
static bool compileLLVMIR(CompilerInvocation &Invocation,
|
||||
|
||||
Reference in New Issue
Block a user