Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Unexpected behavior on unit test with assign/erase/assign #31
Apologies if this turns out to be due to my own mishandling of the library.
I've written a test in some of my own code to see what container I should use for a concurrent hash map. The test is as follow (adapted to junction):
My understanding is that an assign operation followed by an erase and then another assign ought to essentially cancel each other out. However, I'm getting spurious failures with junction:
Are my expectations incorrect?
Sure. I've tried with both of those as well now, and it happens with all 3. It seems that Grampa is the worst of all.. many failures. Linear seems to have a lower frequency of these than Leapfrog. I probably shouldn't make such statements about the frequency between Linear and Leapfrog.. I don't have enough samples to really say. The Grampa was significant in that there were over a dozen failures whereas the others would have 0-3 over 200 runs.