8000230: Change os::print_location to be more descriptive when a location is pointing into an object
authorstefank
Fri, 28 Sep 2012 15:34:32 +0200
changeset 13921 cfc740741651
parent 13920 3e5c173b8525
child 13922 ab7d352debe6
8000230: Change os::print_location to be more descriptive when a location is pointing into an object Reviewed-by: mgerdin, twisti
hotspot/src/share/vm/runtime/os.cpp
--- a/hotspot/src/share/vm/runtime/os.cpp	Mon Oct 01 11:07:31 2012 +0200
+++ b/hotspot/src/share/vm/runtime/os.cpp	Fri Sep 28 15:34:32 2012 +0200
@@ -898,7 +898,11 @@
       print = true;
     }
     if (print) {
-      st->print_cr(INTPTR_FORMAT " is an oop", addr);
+      if (p == (HeapWord*) addr) {
+        st->print_cr(INTPTR_FORMAT " is an oop", addr);
+      } else {
+        st->print_cr(INTPTR_FORMAT " is pointing into object: " INTPTR_FORMAT, addr, p);
+      }
       oop(p)->print_on(st);
       return;
     }