Lazy ST vs concurrency

David Feuer david at
Mon Jan 30 19:29:10 UTC 2017

On Monday, January 30, 2017 1:50:29 PM EST Reid Barton wrote:
> I wrote a lazy ST microbenchmark ( that uses
> nothing but lazy ST monad operations in the inner loop.

This benchmark doesn't really look like code I'd expect people to use in 
practice. Normally, they're using lazy ST because they actually need to use 
STRefs or STArrays in the loop! I suspect your test case is likely about the 
worst possible slowdown for the fix. And 3x slowdown in lazy ST doesn't 
necessarily translate to a 3x slowdown in an application using it.


More information about the ghc-devs mailing list