When we run a STM
expression which hits retry
, the thread is blocked and the transaction is run once again if the entries are modified.
But I was wondering :
If we read a STM variable which, in that specific branch leading to retry, is not actually used , would updating it try to perform the transaction again ?
While the thread is blocked, is it really blocked ? or is it recycled in a thread pool to be used by other potentially waiting operations ?