[Haskell-cafe] Software Transactional Memory and LWN
lrpalmer at gmail.com
Thu Jun 11 04:35:33 EDT 2009
On Thu, Jun 11, 2009 at 2:30 AM, Ketil Malde <ketil at malde.org> wrote:
> Browsing LWN, I ran across this comment:
> The author makes a bunch of unsubstantiated claims about STM, namely
> that all implementations use locking under the hood, and that STM can
> live- and deadlock. I've seen a lot of similar sentiments in other
> places as well (comp.arch springs to mind).
> Now, I'm no expert on STM, but I was pretty sure these are incorrect,
> and I certainly had the impression that Haskell's STM guarantees some
> progress - which it couldn't in a deadlock situation.
MVars can be simulated with STM, and MVars can semantically get in a
deadlock situation, so STM can also deadlock.
Admittedly, if you're using STM to simulate MVars, you're doing it wrong.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Haskell-Cafe