< prev index next >

src/share/vm/gc_implementation/g1/heapRegionType.cpp

Print this page

        

@@ -65,5 +65,20 @@
   }
   ShouldNotReachHere();
   // keep some compilers happy
   return NULL;
 }
+
+G1HeapRegionTraceType::Type HeapRegionType::get_trace_type() {
+  hrt_assert_is_valid(_tag);
+  switch (_tag) {
+    case FreeTag:               return G1HeapRegionTraceType::Free;
+    case EdenTag:               return G1HeapRegionTraceType::Eden;
+    case SurvTag:               return G1HeapRegionTraceType::Survivor;
+    case HumStartsTag:          return G1HeapRegionTraceType::StartsHumongous;
+    case HumContTag:            return G1HeapRegionTraceType::ContinuesHumongous;
+    case OldTag:                return G1HeapRegionTraceType::Old;
+    default:
+      ShouldNotReachHere();
+      return G1HeapRegionTraceType::Free; // keep some compilers happy
+  }
+}
< prev index next >