Martin Zabel
-
2012-03-29
- priority: 5 --> 9
In version 2.0 of JemBench a race-condition might occur in jembench.EnumeratedExecutor$Worker.run(). While waiting for new work, the method checks for "!finished" in the first if-statement and sets "finished=true" in the else case. If work comes available after the check, another thread sets "finished=false" which is reset to "true" by the worker in the else case. So the worker does not see, that their is work available. Thus, the work is unbalanced across the multiple cores, giving worse results for parallel benchmarks.
I have also uploaded a patch (ID 3512739) which will resolve this issue.