# HG changeset patch # User kvn # Date 1417551871 28800 # Node ID f913964f3fde85c42ab7da376c3f7d56589c26d5 # Parent a8ebd6f1b030571349390aa452d6b6a98081c5ac 8066199: C2 escape analysis prevents VM from exiting quickly Summary: Check for safepoint and block during EA Connection graph construction. Reviewed-by: roland, vlivanov, shade diff -r a8ebd6f1b030 -r f913964f3fde src/share/vm/opto/escape.cpp --- a/src/share/vm/opto/escape.cpp Tue Dec 02 15:01:01 2014 -0800 +++ b/src/share/vm/opto/escape.cpp Tue Dec 02 12:24:31 2014 -0800 @@ -1106,6 +1106,9 @@ // Each 4 iterations calculate how much time it will take // to complete graph construction. time.stop(); + // Poll for requests from shutdown mechanism to quiesce compiler + // because Connection graph construction may take long time. + CompileBroker::maybe_block(); double stop_time = time.seconds(); double time_per_iter = (stop_time - start_time) / (double)SAMPLE_SIZE; double time_until_end = time_per_iter * (double)(java_objects_length - next);