[commit: ghc] wip/T9291: Add a CSE pass to Stg (#9291) (e81ce91)

git at git.haskell.org git at git.haskell.org
Sun Dec 25 14:23:06 UTC 2016


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

On branch  : wip/T9291
Link       : http://ghc.haskell.org/trac/ghc/changeset/e81ce911ded9f1141c66ab5ccc5c8c5cbb0ab560/ghc

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

commit e81ce911ded9f1141c66ab5ccc5c8c5cbb0ab560
Author: Joachim Breitner <mail at joachim-breitner.de>
Date:   Thu Dec 15 10:57:43 2016 -0800

    Add a CSE pass to Stg (#9291)
    
    This CSE pass only targets data constructor applications. This is
    probably the best we can do, as function calls and primitive operations
    might have side-effects.
    
    Introduces the flag -fstg-cse, enabled by default with -O.
    
    Differential Revision: https://phabricator.haskell.org/D2871


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

e81ce911ded9f1141c66ab5ccc5c8c5cbb0ab560
 compiler/basicTypes/Id.hs                          |   6 +
 compiler/basicTypes/Var.hs                         |  19 +
 compiler/coreSyn/CoreSyn.hs                        |   8 -
 compiler/coreSyn/TrieMap.hs                        |   6 +-
 compiler/ghc.cabal.in                              |   1 +
 compiler/main/DynFlags.hs                          |   3 +
 compiler/simplStg/SimplStg.hs                      |  30 +-
 compiler/simplStg/StgCse.hs                        | 427 +++++++++++++++++++++
 compiler/simplStg/UnariseStg.hs                    |   5 -
 compiler/stgSyn/StgSyn.hs                          |  24 +-
 docs/users_guide/using-optimisation.rst            |   8 +
 testsuite/tests/{ado => simplStg}/Makefile         |   0
 .../should_run}/Makefile                           |   0
 testsuite/tests/simplStg/should_run/T9291.hs       |  58 +++
 .../should_run/T9291.stdout}                       |   1 +
 testsuite/tests/simplStg/should_run/all.T          |  12 +
 16 files changed, 578 insertions(+), 30 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 e81ce911ded9f1141c66ab5ccc5c8c5cbb0ab560


More information about the ghc-commits mailing list