[GHC] #15131: Speed up certain Foldable NonEmpty methods

GHC ghc-devs at haskell.org
Mon May 14 04:07:56 UTC 2018


#15131: Speed up certain Foldable NonEmpty methods
-------------------------------------+-------------------------------------
        Reporter:  dfeuer            |                Owner:  (none)
            Type:  bug               |               Status:  patch
        Priority:  normal            |            Milestone:  8.6.1
       Component:  Core Libraries    |              Version:  8.2.2
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  Runtime           |  Unknown/Multiple
  performance bug                    |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):  Phab:D4677
       Wiki Page:                    |
-------------------------------------+-------------------------------------

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

 In [changeset:"b7139869c3c42c778fa9eb90058439323f548ec2/ghc"
 b7139869/ghc]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="b7139869c3c42c778fa9eb90058439323f548ec2"
 Improve some Foldable methods for NonEmpty

 * `length` is improved by using the default definition,
   while `foldr1` is improved by using a custom one.

 * Several methods had useless lazy pattern matches
   (i.e., the functions were actually strict in those arguments).
   Remove `~`s to clarify.

 Reviewers: hvr, bgamari, mpickering, nomeata

 Reviewed By: bgamari

 Subscribers: ygale, rwbarton, thomie, carter

 GHC Trac Issues: #15131

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

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


More information about the ghc-tickets mailing list