[GHC] #14998: Sort out the strictness mess for exceptions

GHC ghc-devs at haskell.org
Mon Apr 9 12:07:06 UTC 2018


#14998: Sort out the strictness mess for exceptions
-------------------------------------+-------------------------------------
        Reporter:  simonpj           |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:  8.4.3
       Component:  Compiler          |              Version:  8.2.2
      Resolution:                    |             Keywords:  Exceptions
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by sgraf):

 There's no binary difference in `dump-cmm` for the hello world example (as
 expected) and there is no binary difference in the object files generated
 for GHC.IO.Handle.Text either, after `strip`ping.

 The only difference in GHC.IO.Handle.Internals seems to be in
 `do_operation` (no wonder, that was the only place Core differed). Here's
 the [https://www.diffchecker.com/w0h8gImt diff]. You can see that HEAD on
 the right somehow can jump to cbPP directly, whereas the patched version
 on the left needs to allocate a closure for actually calling the `act`ion
 (which I presume got ripped out into the `sat_entry` at the top). I'm not
 proficient enough with Stg/Cmm to tell why the single bang leads to better
 code, while the diff in Core is boring. Maybe a suprise hides in the way
 `catch#` is lowered?

 So, what should a Note look like that explains Phab:D4574? Just 'plugging
 a space leak'?

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


More information about the ghc-tickets mailing list