Hacker News new | ask | show | jobs
by JulianMorrison 3655 days ago
With a mutex, an A -> B -> A call would deadlock if the mutex is the stop-and-wait or spin-and-retry sort. It would have to be a succeed-or-exception mutex, which is not a common design.
2 comments

EVM doesn't allow the implementation of a blocking mutex and a "spin-and-retry" would simply run out of gas.
Keep in mind that Ethereum only runs one thread. It puts transactions in order and runs one after another.