Repository : ssh://darcs.haskell.org//srv/darcs/ghc On branch : master
http://hackage.haskell.org/trac/ghc/changeset/7da13762664c1bec8e2a1ee5c7106cca3b32a98f >--------------------------------------------------------------- commit 7da13762664c1bec8e2a1ee5c7106cca3b32a98f Author: Simon Marlow <marlo...@gmail.com> Date: Tue Oct 9 08:49:25 2012 +0100 Code-size optimisation for top-level indirections (#7308) Top-level indirections are often generated when there is a cast, e.g. foo :: T foo = bar `cast` (some coercion) For these we were generating a full-blown CAF, which is a fair chunk of code. This patch makes these indirections generate a single IND_STATIC closure (4 words) instead. This is exactly what the CAF would evaluate to eventually anyway, we're just shortcutting the whole process. compiler/cmm/CmmInfo.hs | 3 +- compiler/cmm/SMRep.lhs | 11 +++++++++- compiler/codeGen/StgCmm.hs | 13 ++++++----- compiler/codeGen/StgCmmBind.hs | 40 ++++++++++++++++++++++++++++-------- compiler/codeGen/StgCmmClosure.hs | 8 +++++++ compiler/codeGen/StgCmmHeap.hs | 6 +--- 6 files changed, 60 insertions(+), 21 deletions(-) Diff suppressed because of size. To see it, use: git show 7da13762664c1bec8e2a1ee5c7106cca3b32a98f _______________________________________________ Cvs-ghc mailing list Cvs-ghc@haskell.org http://www.haskell.org/mailman/listinfo/cvs-ghc