From a4edb70a4b3b204ac59aa93ad9b07f1e80e48808 Mon Sep 17 00:00:00 2001 From: kvn Date: Tue, 2 Dec 2014 12:24:31 -0800 Subject: [PATCH] 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 --- src/share/vm/opto/escape.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/share/vm/opto/escape.cpp b/src/share/vm/opto/escape.cpp index 4af344928..384fe0810 100644 --- a/src/share/vm/opto/escape.cpp +++ b/src/share/vm/opto/escape.cpp @@ -1106,6 +1106,9 @@ bool ConnectionGraph::complete_connection_graph( // 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); -- GitLab