Wolfgang Jeltsch pushed to branch wip/jeltsch/more-efficient-home-unit-imports-finding at Glasgow Haskell Compiler / GHC Commits: da4c4d9f by Wolfgang Jeltsch at 2026-04-11T16:23:36+03:00 Consider also `ModuleNodeFixed` nodes for the cache - - - - - 1 changed file: - compiler/GHC/Unit/Module/Graph.hs Changes: ===================================== compiler/GHC/Unit/Module/Graph.hs ===================================== @@ -219,22 +219,18 @@ mkHomeModuleMap nodes = ModuleNameHomeMap completeUnits providerMap where providerMap = Map.fromListWith Set.union $ [ - (ms_mod_name modSummary, Set.singleton (ms_unitid modSummary)) | - ModuleNode _ (ModuleNodeCompile modSummary) <- nodes + (moduleName, Set.singleton unitID) | + ModuleNode _ moduleNodeInfo <- nodes, + let moduleName = moduleNodeInfoModuleName moduleNodeInfo, + let unitID = moduleNodeInfoUnitId moduleNodeInfo ] completeUnits :: Set UnitId - completeUnits - = Set.fromList $ - [ - ms_unitid modSummary | - ModuleNode _ (ModuleNodeCompile modSummary) <- nodes - ] - - {-NOTE: - The matching with `ModuleNodeCompile` results in nodes with - `ModuleNodeFixed` in their info being dropped. - -} + completeUnits = Set.fromList $ + [ + moduleNodeInfoUnitId moduleNodeInfo | + ModuleNode _ moduleNodeInfo <- nodes + ] mgHomeModuleMap :: ModuleGraph -> ModuleNameHomeMap mgHomeModuleMap = mg_home_map View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/da4c4d9f49768a4f326a0ee87b2ce62e... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/da4c4d9f49768a4f326a0ee87b2ce62e... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Wolfgang Jeltsch (@jeltsch)