[commit: ghc] master: Hoopl/Dataflow: use block-oriented interface (679ccd1)

git at git.haskell.org git at git.haskell.org
Wed Nov 30 01:38:43 UTC 2016


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

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

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

commit 679ccd1c8860f1ef4b589c9593b74d04c97ae836
Author: Michal Terepeta <michal.terepeta at gmail.com>
Date:   Tue Nov 29 17:54:12 2016 -0500

    Hoopl/Dataflow: use block-oriented interface
    
    This introduces the new interface for dataflow analysis, where transfer
    functions operate on a whole basic block.
    
    The main changes are:
    - Hoopl.Dataflow: implement the new interface and remove the old code;
      expose a utility function to do a strict fold over the nodes of a
      basic block (for analyses that do want to look at all the nodes)
    - Refactor all the analyses to use the new interface.
    
    One of the nice effects is that we can remove the `analyzeFwdBlocks`
    hack that ignored the middle nodes (that existed for analyses that
    didn't need to go over all the nodes). Now this is no longer a special
    case and fits well with the new interface.
    
    Signed-off-by: Michal Terepeta <michal.terepeta at gmail.com>
    
    Test Plan:
    validate, earlier version of the patch had assertions
    comparing the results with the old implementation
    
    Reviewers: erikd, austin, simonmar, hvr, goldfire, bgamari
    
    Reviewed By: bgamari
    
    Subscribers: goldfire, erikd, thomie
    
    Differential Revision: https://phabricator.haskell.org/D2754


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

679ccd1c8860f1ef4b589c9593b74d04c97ae836
 compiler/cmm/CmmBuildInfoTables.hs |  33 +++--
 compiler/cmm/CmmLive.hs            |  61 ++++----
 compiler/cmm/CmmProcPoint.hs       |  73 +++++-----
 compiler/cmm/Hoopl/Dataflow.hs     | 285 ++++++++++---------------------------
 4 files changed, 160 insertions(+), 292 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 679ccd1c8860f1ef4b589c9593b74d04c97ae836


More information about the ghc-commits mailing list