[commit: ghc] master: InstEnv: Ensure that instance visibility check is lazy (ed48098)

git at git.haskell.org git at git.haskell.org
Wed Jul 20 15:16:22 UTC 2016


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

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

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

commit ed4809813fa51524ae73a4475afe33018a67f87d
Author: Ben Gamari <bgamari.foss at gmail.com>
Date:   Wed Jul 20 09:56:03 2016 +0200

    InstEnv: Ensure that instance visibility check is lazy
    
    Previously instIsVisible had completely broken the laziness of
    lookupInstEnv' since it would examine is_dfun_name to check the name of
    the defining module (to know whether it is an interactive module). This
    resulted in the visibility check drawing in an interface file
    unnecessarily. This contributed to the unnecessary regression in
    compiler allocations reported in #12367.
    
    Test Plan: Validate, check nofib changes
    
    Reviewers: simonpj, ezyang, austin
    
    Reviewed By: ezyang
    
    Subscribers: thomie, ezyang
    
    Differential Revision: https://phabricator.haskell.org/D2411
    
    GHC Trac Issues: #12367


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

ed4809813fa51524ae73a4475afe33018a67f87d
 compiler/iface/TcIface.hs                          |  8 +-
 compiler/types/InstEnv.hs                          | 97 +++++++++++++++-------
 .../tests/ghci.debugger/scripts/break006.stderr    | 14 ++--
 testsuite/tests/perf/space_leaks/all.T             |  3 +-
 testsuite/tests/typecheck/should_fail/T5095.stderr |  8 +-
 5 files changed, 83 insertions(+), 47 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 ed4809813fa51524ae73a4475afe33018a67f87d


More information about the ghc-commits mailing list