# HG changeset patch # User Tom Rodriguez # Date 1430239463 25200 # Node ID a17dc2584e81a46c5dbca26ba09d878b4a398006 # Parent bf8cbbfabdcfed8a1119a4090d617c99c9a210c0 Fix time reporting in multithreaded CTW diff -r bf8cbbfabdcf -r a17dc2584e81 graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompileTheWorld.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompileTheWorld.java Fri Apr 24 12:05:38 2015 -0700 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompileTheWorld.java Tue Apr 28 09:44:23 2015 -0700 @@ -388,10 +388,14 @@ if (!running) { startThreads(); } + int wakeups = 0; while (threadPool.getCompletedTaskCount() != threadPool.getTaskCount()) { - TTY.println("CompileTheWorld : Waiting for " + (threadPool.getTaskCount() - threadPool.getCompletedTaskCount()) + " compiles"); + if (wakeups % 15 == 0) { + TTY.println("CompileTheWorld : Waiting for " + (threadPool.getTaskCount() - threadPool.getCompletedTaskCount()) + " compiles"); + } try { - threadPool.awaitTermination(15, TimeUnit.SECONDS); + threadPool.awaitTermination(1, TimeUnit.SECONDS); + wakeups++; } catch (InterruptedException e) { } }