--- old/src/share/vm/opto/library_call.cpp Tue Feb 25 17:39:24 2014 +++ new/src/share/vm/opto/library_call.cpp Tue Feb 25 17:39:24 2014 @@ -3236,7 +3236,8 @@ // private native boolean java.lang.Thread.isInterrupted(boolean ClearInterrupted); bool LibraryCallKit::inline_native_isInterrupted() { // Add a fast path to t.isInterrupted(clear_int): - // (t == Thread.current() && (!TLS._osthread._interrupted || !clear_int)) + // (t == Thread.current() && + // (!TLS._osthread._interrupted || WINDOWS_ONLY(false) NOT_WINDOWS(!clear_int))) // ? TLS._osthread._interrupted : /*slow path:*/ t.isInterrupted(clear_int) // So, in the common case that the interrupt bit is false, // we avoid making a call into the VM. Even if the interrupt bit @@ -3299,6 +3300,12 @@ Node* bol_arg = _gvn.transform(new (C) BoolNode(cmp_arg, BoolTest::ne)); IfNode* iff_arg = create_and_map_if(control(), bol_arg, PROB_FAIR, COUNT_UNKNOWN); +#ifdef TARGET_OS_FAMILY_windows + // To return true on Windows you must read the _interrupted field + // and check the the event state i.e. take the slow path. + result_rgn->init_req(no_clear_result_path, top()); + result_val->init_req(no_clear_result_path, top()); +#else // Second fast path: ... else if (!clear_int) return true; Node* false_arg = _gvn.transform(new (C) IfFalseNode(iff_arg)); result_rgn->init_req(no_clear_result_path, false_arg); @@ -3310,6 +3317,7 @@ // (d) Otherwise, go to the slow path. slow_region->add_req(control()); set_control( _gvn.transform(slow_region)); +#endif if (stopped()) { // There is no slow path.