[GHC] #9476: Implement late lambda-lifting
GHC
ghc-devs at haskell.org
Thu Nov 29 23:42:43 UTC 2018
#9476: Implement late lambda-lifting
-------------------------------------+-------------------------------------
Reporter: simonpj | Owner: sgraf
Type: feature request | Status: closed
Priority: normal | Milestone: 8.8.1
Component: Compiler | Version: 7.8.2
Resolution: fixed | Keywords: LateLamLift
Operating System: Unknown/Multiple | Architecture:
Type of failure: Runtime | Unknown/Multiple
performance bug | Test Case:
Blocked By: | Blocking:
Related Tickets: #8763 #13286 | Differential Rev(s): Phab:D5224
Wiki Page: LateLamLift |
-------------------------------------+-------------------------------------
Comment (by simonpj):
Ah, I see. Thanks.
It is indeed mysterious to me how allocating more less to less GC time.
Paraffins is a reasonably small example, with a small inner loop, so there
is some hope of finding out.
With `+RTS -Sstderr` you'll get info on GC calls, including the residency
numbers. With `-G1` (I think) you'll get just one generation, so every GC
does a full sweep and you'll get accurate residency (= live data) info.
That's useful as a way to avoid accidents such as the precise moment when
major GC strikes. Does the improvement continue with one generation ?
(I.e. both before and after with one generation.)
With a program this small it must be possible to truly understand where
the better GC numbers are coming from.
It's be interesting to know if ignoring closure growth improves all
programs (or at least does not make them worse). Even we didn't
understand why, if it's generally true we can switch it off -- or just
simplify the code by removing the analysis.
One idea is this. After lambda-lifting, it's possible that `go` is
strict in one of its new arguments, such as x, y, or z2. Ahh... but this
lambda lifting occurs after strictness analysis, so it can't be that.
OK, I'm at a loss. More info needed.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9476#comment:59>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list