src/share/vm/gc_implementation/shared/ageTable.hpp

Print this page

        

@@ -52,12 +52,15 @@
 
   // clear table
   void clear();
 
   // add entry
-  void add(oop p, size_t oop_size) {
-    uint age = p->age();
+  void add(const oop p, const size_t oop_size) {
+    add(p->age(), oop_size);
+  }
+
+  void add(const uint age, const size_t oop_size) {
     assert(age > 0 && age < table_size, "invalid age of object");
     sizes[age] += oop_size;
   }
 
   // Merge another age table with the current one.  Used