I've been noticing a strange thing for a while on Windows 8/8.1 and the equivalent server versions. The issue occurs when I'm using a Slim Reader/Writer Lock (SRWL) exclusively in exclusive mode (as a replacement for critical sections). What happens is, when a thread that has just unlocked a SRWL exits cleanly, immediately after unlocking the lock, sometimes threads that are waiting on the lock do not get woken and none of them acquire the lock. At first I spent ages thinking that this was some kind of subtle bug in my LockExplorer tool as initially the problem only manifested…
Continue reading Surprising Slim Reader/Writer Lock thread exit issues..