Sending interrupts to the worker threads upon teardown
Chris Vest
mr.chrisvest at gmail.com
Mon May 5 12:28:31 UTC 2014
Awesome :)
Cheers,
Chris
On 05 May 2014, at 10:32, Aleksey Shipilev <aleksey.shipilev at oracle.com> wrote:
> On 04/14/2014 10:56 PM, Chris Vest wrote:
>> Yeah… both are wrong. And there is no way for the harness to know how
>> much work did or did not get done, or how much time was spent blocking.
>> I was guessing that the synchronised iterations would magically take
>> care of and exclude these kinds of outliers at the beginnings and the
>> ends from the measurement, but I guess that was a misconception?
>
> Actually, it *is* the case that synchronized iterations can consume the
> interrupts. JMH 0.7 now does it, see:
> http://hg.openjdk.java.net/code-tools/jmh/file/tip/jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_30_Interrupts.java
>
> -Aleksey.
>
More information about the jmh-dev
mailing list