[GHC] #14375: Implement with# primop

GHC ghc-devs at haskell.org
Tue Oct 2 18:26:09 UTC 2018


#14375: Implement with# primop
-------------------------------------+-------------------------------------
        Reporter:  simonpj           |                Owner:  bgamari
            Type:  bug               |               Status:  new
        Priority:  highest           |            Milestone:  8.8.1
       Component:  Compiler          |              Version:  8.2.1
      Resolution:                    |             Keywords:  JoinPoints
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:  #14346            |  Differential Rev(s):  ​Phab:D4110,
       Wiki Page:                    |  Phab:D4189
-------------------------------------+-------------------------------------

Comment (by dfeuer):

 I don't understand why this has to wait for the continuation arguments
 machinery. Yes, that will make it more efficient, but shouldn't we get the
 correctness now and worry about efficiency later? If we write

 {{{#!hs
 with# a m s =
   case m s of
     (# s', r #) -> (# touch# a s', r #)
 {-# NOINLINE with# #-}
 }}}

 won't that at least let users write reliable backwards-compatible code?

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


More information about the ghc-tickets mailing list