< prev index next >

src/share/vm/memory/heapInspection.cpp

Print this page
rev 9978 : 8146395: Add inline qualifier in oop.hpp and fix inlining in gc files
Summary: Fix remaining issues after 8146401. Also fix windows VS2010 linkage problem (g1OopClosures.hpp).
Reviewed-by: stefank, mgerdin

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 2002, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.

@@ -38,10 +38,18 @@
 #include "gc/parallel/parallelScavengeHeap.hpp"
 #endif // INCLUDE_ALL_GCS
 
 // HeapInspection
 
+int KlassSizeStats::count(oop x) {
+  return (HeapWordSize * (((x) != NULL) ? (x)->size() : 0));
+}
+
+int KlassSizeStats::count_array(objArrayOop x) {
+  return (HeapWordSize * (((x) != NULL) ? (x)->size() : 0));
+}
+
 inline KlassInfoEntry::~KlassInfoEntry() {
   if (_subclasses != NULL) {
     delete _subclasses;
   }
 }
< prev index next >