@@ -57,6 +57,12 @@ using IsFrameworkField = BCFixed<1>;
5757using IsSystemField = BCFixed<1 >;
5858// / A bit that indicates whether or not a module is that of a static archive
5959using IsStaticField = BCFixed<1 >;
60+ // / A bit taht indicates whether or not a link library is a force-load one
61+ using IsForceLoadField = BCFixed<1 >;
62+
63+ // / Source location fields
64+ using LineNumberField = BCFixed<32 >;
65+ using ColumnNumberField = BCFixed<32 >;
6066
6167// / Arrays of various identifiers, distinguished for readability
6268using IdentifierIDArryField = llvm::BCArray<IdentifierIDField>;
@@ -65,9 +71,12 @@ using ModuleIDArryField = llvm::BCArray<IdentifierIDField>;
6571// / Identifiers used to refer to the above arrays
6672using FileIDArrayIDField = IdentifierIDField;
6773using ContextHashIDField = IdentifierIDField;
74+ using ModuleCacheKeyIDField = IdentifierIDField;
6875using ImportArrayIDField = IdentifierIDField;
6976using FlagIDArrayIDField = IdentifierIDField;
7077using DependencyIDArrayIDField = IdentifierIDField;
78+ using AuxiliaryFilesArrayIDField = IdentifierIDField;
79+ using SourceLocationIDArrayIDField = IdentifierIDField;
7180
7281// / The ID of the top-level block containing the dependency graph
7382const unsigned GRAPH_BLOCK_ID = llvm::bitc::FIRST_APPLICATION_BLOCKID;
@@ -81,6 +90,9 @@ namespace graph_block {
8190enum {
8291 METADATA = 1 ,
8392 MODULE_NODE,
93+ LINK_LIBRARY_NODE,
94+ SOURCE_LOCATION_NODE,
95+ IMPORT_STATEMENT_NODE,
8496 SWIFT_INTERFACE_MODULE_DETAILS_NODE,
8597 SWIFT_SOURCE_MODULE_DETAILS_NODE,
8698 SWIFT_PLACEHOLDER_MODULE_DETAILS_NODE,
@@ -117,6 +129,26 @@ using IdentifierNodeLayout = BCRecordLayout<IDENTIFIER_NODE, BCBlob>;
117129using IdentifierArrayLayout =
118130 BCRecordLayout<IDENTIFIER_ARRAY_NODE, IdentifierIDArryField>;
119131
132+ using LinkLibraryLayout =
133+ BCRecordLayout<LINK_LIBRARY_NODE, // ID
134+ IdentifierIDField, // libraryName
135+ IsFrameworkField, // isFramework
136+ IsForceLoadField // forceLoad
137+ >;
138+
139+ using SourceLocationLayout =
140+ BCRecordLayout<LINK_LIBRARY_NODE, // ID
141+ IdentifierIDField, // bufferIdentifier
142+ LineNumberField, // lineNumber
143+ ColumnNumberField // columnNumber
144+ >;
145+
146+ using ImportStatementLayout =
147+ BCRecordLayout<LINK_LIBRARY_NODE, // ID
148+ IdentifierIDField, // importIdentifier
149+ SourceLocationIDArrayIDField // importLocations
150+ >;
151+
120152// After the array records, we have a sequence of Module info
121153// records, each of which is followed by one of:
122154// - SwiftInterfaceModuleDetails
@@ -130,7 +162,14 @@ using ModuleInfoLayout =
130162 ContextHashIDField, // contextHash
131163 ImportArrayIDField, // moduleImports
132164 ImportArrayIDField, // optionalModuleImports
133- DependencyIDArrayIDField // resolvedDirectModuleDependencies
165+ // ACTODO: LinkLibrariesArrayIDField, // linkLibraries
166+ DependencyIDArrayIDField, // importedSwiftModules
167+ DependencyIDArrayIDField, // importedClangModules
168+ DependencyIDArrayIDField, // crossImportOverlayModules
169+ DependencyIDArrayIDField, // swiftOverlayDependencies
170+ ModuleCacheKeyIDField, // moduleCacheKey
171+ AuxiliaryFilesArrayIDField // auxiliaryFiles
172+ // ACTODO: MacroDependenciesArrayIDField, // macroDependencies
134173 >;
135174
136175using SwiftInterfaceModuleDetailsLayout =
@@ -147,7 +186,6 @@ using SwiftInterfaceModuleDetailsLayout =
147186 FileIDArrayIDField, // sourceFiles
148187 FileIDArrayIDField, // bridgingSourceFiles
149188 IdentifierIDField, // bridgingModuleDependencies
150- DependencyIDArrayIDField, // swiftOverlayDependencies
151189 IdentifierIDField, // CASFileSystemRootID
152190 IdentifierIDField, // bridgingHeaderIncludeTree
153191 IdentifierIDField, // moduleCacheKey
@@ -161,7 +199,6 @@ using SwiftSourceModuleDetailsLayout =
161199 FileIDArrayIDField, // sourceFiles
162200 FileIDArrayIDField, // bridgingSourceFiles
163201 FileIDArrayIDField, // bridgingModuleDependencies
164- DependencyIDArrayIDField, // swiftOverlayDependencies
165202 IdentifierIDField, // CASFileSystemRootID
166203 IdentifierIDField, // bridgingHeaderIncludeTree
167204 FlagIDArrayIDField, // buildCommandLine
@@ -173,7 +210,6 @@ using SwiftBinaryModuleDetailsLayout =
173210 FileIDField, // compiledModulePath
174211 FileIDField, // moduleDocPath
175212 FileIDField, // moduleSourceInfoPath
176- DependencyIDArrayIDField, // swiftOverlayDependencies
177213 FileIDField, // headerImport
178214 IdentifierIDField, // headerModuleDependencies
179215 FileIDArrayIDField, // headerSourceFiles
@@ -220,7 +256,7 @@ bool readInterModuleDependenciesCache(llvm::StringRef path,
220256// / Returns true if there was an error.
221257bool writeInterModuleDependenciesCache (DiagnosticEngine &diags,
222258 llvm::vfs::OutputBackend &backend,
223- llvm::StringRef path ,
259+ llvm::StringRef outputPath ,
224260 const ModuleDependenciesCache &cache);
225261
226262// / Tries to write out the given dependency cache with the given
0 commit comments