[GHC] #14226: Common Block Elimination pass doesn't eliminate common blocks

GHC ghc-devs at haskell.org
Tue Sep 19 22:54:32 UTC 2017


#14226: Common Block Elimination pass doesn't eliminate common blocks
-------------------------------------+-------------------------------------
        Reporter:  bgamari           |                Owner:  (none)
            Type:  bug               |               Status:  patch
        Priority:  high              |            Milestone:  8.4.1
       Component:  Compiler          |              Version:  8.2.1
  (CodeGen)                          |
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:  #9157             |  Differential Rev(s):  Phab:D3973
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by Ben Gamari <ben@…>):

 In [changeset:"7920a7d9c53083b234e060a3e72f00b601a46808/ghc" 7920a7d/ghc]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="7920a7d9c53083b234e060a3e72f00b601a46808"
 cmm/CBE: Collapse blocks equivalent up to alpha renaming of local
 registers

 As noted in #14226, the common block elimination pass currently
 implements an extremely strict equivalence relation, demanding that two
 blocks are equivalent including the names of their local registers. This
 is quite restrictive and severely hampers the effectiveness of the pass.

 Here we allow the CBE pass to collapse blocks which are equivalent up to
 alpha renaming of locally-bound local registers. This is completely safe
 and catches many more duplicate blocks.

 Test Plan: Validate

 Reviewers: austin, simonmar, michalt

 Reviewed By: michalt

 Subscribers: rwbarton, thomie

 GHC Trac Issues: #14226

 Differential Revision: https://phabricator.haskell.org/D3973
 }}}

-- 
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14226#comment:10>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list