Wolfgang Jeltsch pushed to branch wip/jeltsch/more-efficient-home-unit-imports-finding at Glasgow Haskell Compiler / GHC

Commits:

1 changed file:

Changes:

  • compiler/GHC/Unit/Finder.hs
    ... ... @@ -253,9 +253,9 @@ findImportedModuleNoHsc fc fopts ue home_module_name_providers_map mb_home_unit
    253 253
         hpt_deps = homeUnitDepends units
    
    254 254
     
    
    255 255
         -- TODO: this predicate is wrong, we need something more focused
    
    256
    -    sorted_deps = case finder_lookupHomeInterfaces fopts of
    
    257
    -      True -> Set.toList hpt_deps
    
    258
    -      False -> sortHomeUnitsByLikelihoodFor home_module_name_providers_map mb_home_unit_id mod_name hpt_deps
    
    256
    +    sorted_deps = if finder_lookupHomeInterfaces fopts
    
    257
    +      then Set.toList hpt_deps
    
    258
    +      else sortHomeUnitsByLikelihoodFor home_module_name_providers_map mb_home_unit_id mod_name hpt_deps
    
    259 259
     
    
    260 260
         other_fopts =
    
    261 261
           [ (uid, initFinderOpts (homeUnitEnv_dflags (ue_findHomeUnitEnv uid ue)))