My weekend project consists of writing a cross-platform library of concurrency primitives (critical sections, read / write mutexes, locking chains, events, etc.) and wondered how unit test this stuff. I understand that testing parallel code in itself is difficult, but testing the primitives of the specified code cannot be so tough, right?
It turns out it's so complicated. At least for me it is.
So how would you approach this? As an example, I don’t even know where to start testing critical sections.
c ++ concurrency unit-testing
Clark gaebel
source share