[GHC] #8281: The impossible happened: primRepToFFIType

GHC ghc-devs at haskell.org
Fri Mar 10 07:23:03 UTC 2017


#8281: The impossible happened: primRepToFFIType
-------------------------------------+-------------------------------------
        Reporter:  tibbe             |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  high              |            Milestone:  8.4.1
       Component:  Compiler          |              Version:  7.6.2
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  Compile-time      |  Unknown/Multiple
  crash                              |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by winter):

 I'd really like to see some documents on how `UnliftedFFITypes` interact
 with GC and an `unsafe` FFI call.

 According to my understanding, passing `ByteArray#` is safe here because
 GC can't happen during an `unsafe` call. Am i right on this? Or perhaps
 RTS do some thing else to prevent GC move the `ByteArray#` during FFI when
 `UnliftedFFITypes` enable?

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


More information about the ghc-tickets mailing list