[GHC] #15426: `elemIndex` and `findIndex` still can't fuse

GHC ghc-devs at haskell.org
Mon Aug 20 15:55:09 UTC 2018


#15426: `elemIndex` and `findIndex` still can't fuse
-------------------------------------+-------------------------------------
        Reporter:  kabuhr            |                Owner:  kabuhr
            Type:  bug               |               Status:  patch
        Priority:  normal            |            Milestone:  8.8.1
       Component:  libraries/base    |              Version:  8.4.3
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
                                     |  testsuite/tests/perf/should_run/T15426.hs
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |  https://phabricator.haskell.org/D5063
-------------------------------------+-------------------------------------
Changes (by kabuhr):

 * status:  new => patch


Comment:

 Yes, that summary is correct.  In the current Phab:D5063 that's pending
 review, I have added a performance regression test `T15426.hs`, and I have
 annotated the change in `OldList.hs` with:
 {{{
 #!haskell
 -- (Note that making this INLINABLE instead of INLINE allows
 -- 'findIndex' to fuse, fixing #15426.)
 }}}
 assuming that's sufficient.

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


More information about the ghc-tickets mailing list