[GHC] #8832: Constant-folding regression wrt `clearBit (bit 0) 0 `

GHC ghc-devs at haskell.org
Thu Mar 13 12:26:44 UTC 2014


#8832: Constant-folding regression wrt `clearBit (bit 0) 0 `
--------------------------------------------+------------------------------
        Reporter:  hvr                      |            Owner:  simonpj
            Type:  bug                      |           Status:  new
        Priority:  normal                   |        Milestone:  7.8.1
       Component:  Compiler                 |          Version:  7.8.1-rc2
      Resolution:                           |         Keywords:
Operating System:  Unknown/Multiple         |     Architecture:
 Type of failure:  Runtime performance bug  |  Unknown/Multiple
       Test Case:                           |       Difficulty:  Unknown
        Blocking:                           |       Blocked By:
                                            |  Related Tickets:
--------------------------------------------+------------------------------

Comment (by Simon Peyton Jones <simonpj@…>):

 In [changeset:"f7a7b586bc89ca7fd56792da4172bd93a2acdae9/base"]:
 {{{
 #!CommitTicketReference repository="base"
 revision="f7a7b586bc89ca7fd56792da4172bd93a2acdae9"
 Add shiftR and shiftL implementations to instance Bits Integer

 Apart from simply making sense (avoid the conditional in 'shift'),
 this makes left and right shifts on Integer more likely to inline
 (plain 'shift' is just too large); and this in turn is important
 when fixing the Integer case of #8832
 }}}

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


More information about the ghc-tickets mailing list