> One other thing: since unsafePerformIO already has a NOINLINE > pragma on it, > I don't think it's necessary to explicitly NOINLINE all these > top-level > mutable thingies. Oh yes it is: foo :: IORef Int foo = unsafePerformIO (newIORef 0) baz :: IO Int baz = do { v <- readIORef foo; writeIORef foo (v+1); return v } Compare with: baz :: IO Int baz = do { v <- readIORef (unsafePerformIO (newIORef 0)); writeIORef (unsafePerformIO (newIORef 0))(v+1); return v } Simon
- Re: Threads in GHC's RTS Herbert Graeber
- Re: Q: Threads in GHC's RTS Sven Panne
- Re: Q: Threads in GHC's RTS Manuel M. T. Chakravarty
- RE: Q: Threads in GHC's RTS Simon Peyton-Jones
- Re: Q: Threads in GHC's RTS Sven Panne
- RE: Q: Threads in GHC's RTS Sigbjorn Finne (Intl Vendor)
- Re: Q: Threads in GHC's RTS Sven Panne
- RE: Q: Threads in GHC's RTS Simon Marlow
- RE: Q: Threads in GHC's RTS Simon Marlow
- RE: Q: Threads in GHC's RTS Sigbjorn Finne (Intl Vendor)
- RE: Q: Threads in GHC's RTS Simon Peyton-Jones
- RE: Q: Threads in GHC's RTS Sigbjorn Finne (Intl Vendor)
- Re: Q: Threads in GHC's RTS Sven Panne
- RE: Q: Threads in GHC's RTS Simon Peyton-Jones
- Re: Q: Threads in GHC's RTS Sven Panne