hg: jdk9/hs-rt/hotspot: 6498581: ThreadInterruptTest3 produces wrong output on Windows
yumin.qi at oracle.com
yumin.qi at oracle.com
Wed Feb 26 16:55:50 PST 2014
Changeset: f6301b007a16
Author: minqi
Date: 2014-02-26 15:20 -0800
URL: http://hg.openjdk.java.net/jdk9/hs-rt/hotspot/rev/f6301b007a16
6498581: ThreadInterruptTest3 produces wrong output on Windows
Summary: There is race condition between os::interrupt and os::is_interrupted on Windows. In JVM_Sleep(Thread.sleep), check if thread gets interrupted, it may see interrupted but not really interrupted so cause spurious waking up (early return from sleep). Fix by checking if interrupt event really gets set thus prevent false return. For intrinsic of _isInterrupted, on Windows, go fastpath only on bit not set.
Reviewed-by: acorn, kvn
Contributed-by: david.holmes at oracle.com, yumin.qi at oracle.com
! src/os/windows/vm/os_windows.cpp
! src/share/vm/opto/library_call.cpp
More information about the jdk9-all-changes
mailing list