< prev index next >

src/hotspot/share/gc/g1/g1CollectedHeap.cpp

Print this page
rev 56784 : [mq]: tschatzl_review

@@ -1988,11 +1988,11 @@
     default:                                return is_user_requested_concurrent_full_gc(cause);
   }
 }
 
 bool G1CollectedHeap::should_upgrade_to_full_gc(GCCause::Cause cause) {
-  if(policy()->force_upgrade_to_full()) {
+  if (policy()->force_upgrade_to_full()) {
     return true;
   } else if (should_do_concurrent_full_gc(_gc_cause)) {
     return false;
   } else if (has_regions_left_for_allocation()) {
     return false;

@@ -2084,25 +2084,26 @@
 
 void G1CollectedHeap::collect(GCCause::Cause cause) {
   try_collect(cause);
 }
 
+// Return true if (x < y) with allowance for wraparound.
 static bool gc_counter_less_than(uint x, uint y) {
   return (x - y) > (UINT_MAX/2);
 }
 
 // LOG_COLLECT_CONCURRENTLY(cause, msg, args...)
 // Macro so msg printing is format-checked.
 #define LOG_COLLECT_CONCURRENTLY(cause, ...)                            \
   do {                                                                  \
-    LogTarget(Debug, gc) LOG_COLLECT_CONCURRENTLY_lt;                   \
+    LogTarget(Trace, gc) LOG_COLLECT_CONCURRENTLY_lt;                   \
     if (LOG_COLLECT_CONCURRENTLY_lt.is_enabled()) {                     \
       ResourceMark rm; /* For thread name. */                           \
       LogStream LOG_COLLECT_CONCURRENTLY_s(&LOG_COLLECT_CONCURRENTLY_lt); \
-      LOG_COLLECT_CONCURRENTLY_s.print("Try Collect Concurrently (%s) for %s: ", \
-                                       GCCause::to_string(cause),       \
-                                       Thread::current()->name());      \
+      LOG_COLLECT_CONCURRENTLY_s.print("%s: Try Collect Concurrently (%s): ", \
+                                       Thread::current()->name(),       \
+                                       GCCause::to_string(cause));      \
       LOG_COLLECT_CONCURRENTLY_s.print(__VA_ARGS__);                    \
     }                                                                   \
   } while (0)
 
 #define LOG_COLLECT_CONCURRENTLY_COMPLETE(cause, result) \
< prev index next >