[commit: ghc] ghc-8.0: InstEnv: Ensure that instance visibility check is lazy (291b439)

git at git.haskell.org git at git.haskell.org
Mon Sep 5 23:12:12 UTC 2016


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

On branch  : ghc-8.0
Link       : http://ghc.haskell.org/trac/ghc/changeset/291b439fb1da7af4401477c92ba24c7b4b498df8/ghc

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

commit 291b439fb1da7af4401477c92ba24c7b4b498df8
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
    
    (cherry picked from commit ed4809813fa51524ae73a4475afe33018a67f87d)


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

291b439fb1da7af4401477c92ba24c7b4b498df8
 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 291b439fb1da7af4401477c92ba24c7b4b498df8


More information about the ghc-commits mailing list