Improve the performance of GetModIfaceFromDisk in large repos and delete GetDependencies (#2323)
* Improve the performance of GetModIfaceFromDisk in large repos There are three benefits: 1. GetModIfaceFromDisk and GhcSessionDeps no longer depend on the transitive module summaries. This means fewer edges in the build graph = smaller build graph = faster builds 2. Avoid duplicate computations in setting up the GHC session with the dependencies of the module. Previously the total work done was O(NlogN) in the number of transitive dependencies, now it is O(N). 3. Increased sharing of HPT and FinderCache. Ideally we should also share the module graphs, but the datatype is abstract, doesn't have a monoid instance, and cannot be coerced to something that has. We will need to add the Monoid instance in GHC first. On the Sigma repo: - the startup metric goes down by ~34%. - The edit metric also goes down by 15%. - Max residency is down by 30% in the edit benchmark. * format importes * clean up * remove stale comment * fix build in GHC 9 * clean up * Unify defintions of ghcSessionDeps * mark test as no longer failing * Prevent duplicate missing module diagnostics * delete GetDependencies * add a test for deeply nested import cycles * Fix build in GHC 9.0 * bump ghcide version * Introduce config options for the main rules Surfacing the performance tradeoffs in the core build rules * Avoid using the Monoid instance (removed in 9.4 ?????) * Fix build with GHC 9 * Fix Eval plugin
Showing
- ghcide/.hlint.yaml 1 addition, 1 deletionghcide/.hlint.yaml
- ghcide/exe/Main.hs 2 additions, 1 deletionghcide/exe/Main.hs
- ghcide/ghcide.cabal 1 addition, 1 deletionghcide/ghcide.cabal
- ghcide/src/Development/IDE/Core/Compile.hs 30 additions, 1 deletionghcide/src/Development/IDE/Core/Compile.hs
- ghcide/src/Development/IDE/Core/RuleTypes.hs 1 addition, 9 deletionsghcide/src/Development/IDE/Core/RuleTypes.hs
- ghcide/src/Development/IDE/Core/Rules.hs 69 additions, 55 deletionsghcide/src/Development/IDE/Core/Rules.hs
- ghcide/src/Development/IDE/GHC/Compat/Units.hs 2 additions, 0 deletionsghcide/src/Development/IDE/GHC/Compat/Units.hs
- ghcide/src/Development/IDE/GHC/Compat/Util.hs 5 additions, 0 deletionsghcide/src/Development/IDE/GHC/Compat/Util.hs
- ghcide/src/Development/IDE/Import/DependencyInformation.hs 1 addition, 0 deletionsghcide/src/Development/IDE/Import/DependencyInformation.hs
- ghcide/src/Development/IDE/Main.hs 1 addition, 1 deletionghcide/src/Development/IDE/Main.hs
- ghcide/src/Development/IDE/Plugin/Test.hs 0 additions, 1 deletionghcide/src/Development/IDE/Plugin/Test.hs
- ghcide/test/exe/Main.hs 29 additions, 12 deletionsghcide/test/exe/Main.hs
- plugins/hls-eval-plugin/hls-eval-plugin.cabal 2 additions, 1 deletionplugins/hls-eval-plugin/hls-eval-plugin.cabal
- plugins/hls-eval-plugin/src/Ide/Plugin/Eval/CodeLens.hs 19 additions, 30 deletionsplugins/hls-eval-plugin/src/Ide/Plugin/Eval/CodeLens.hs
Loading
Please register or sign in to comment