[commit: ghc] master: Make module membership on ModuleGraph faster (b070858)

git at git.haskell.org git at git.haskell.org
Tue Jun 27 17:35:04 UTC 2017


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/b0708588e87554899c2efc80a2d3eba353dbe926/ghc

>---------------------------------------------------------------

commit b0708588e87554899c2efc80a2d3eba353dbe926
Author: Bartosz Nitka <niteria at gmail.com>
Date:   Tue Jun 27 12:55:17 2017 -0400

    Make module membership on ModuleGraph faster
    
    When loading/reloading with a large number of modules
    (>5000) the cost of linear lookups becomes significant.
    
    The changes here made `:reload` go from 6s to 1s on my
    test case.
    
    The bottlenecks were `needsLinker` in `DriverPipeline` and
    `getModLoop` in `GhcMake`.
    
    Test Plan: ./validate
    
    Reviewers: simonmar, austin, bgamari
    
    Subscribers: rwbarton, thomie
    
    Differential Revision: https://phabricator.haskell.org/D3646


>---------------------------------------------------------------

b0708588e87554899c2efc80a2d3eba353dbe926
 compiler/backpack/DriverBkp.hs                |   5 +-
 compiler/main/DriverMkDepend.hs               |  16 ++--
 compiler/main/DriverPipeline.hs               |   5 +-
 compiler/main/GHC.hs                          |  23 ++---
 compiler/main/GhcMake.hs                      |  54 ++++++-----
 compiler/main/HscMain.hs                      |   2 +-
 compiler/main/HscTypes.hs                     | 123 ++++++++++++++++++++++++--
 ghc/GHCi/UI.hs                                |  23 ++---
 ghc/GHCi/UI/Tags.hs                           |   2 +-
 testsuite/tests/ghc-api/apirecomp001/myghc.hs |   4 +-
 utils/check-api-annotations/Main.hs           |  10 +--
 utils/check-ppr/Main.hs                       |   2 +-
 utils/ghctags/Main.hs                         |   6 +-
 13 files changed, 200 insertions(+), 75 deletions(-)

Diff suppressed because of size. To see it, use:

    git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc b0708588e87554899c2efc80a2d3eba353dbe926


More information about the ghc-commits mailing list