3 ms·
Now I'm curious. Was the mutex actually necessary, or was the performance increase purchased at the cost of race conditions?
by MereInterest 10y ago
Now I'm curious. Was the mutex actually necessary, or was the performance increase purchased at the cost of race conditions?
- huhtenberg 10y agoYeah, the mutex was necessary and it was pretty bloody obvious from looking at few lines of context around those calls.
- SomeCollegeBro 10y agoUnfortunately, most of the time when you come across a mutex you have to assume it's necessary. It's very hard to regression test code after removing a mutex, chances are you are not going to encounter the race condition which the mutex protects against (unless it's well documented, of course).