Mercurial > hg > truffle
comparison src/share/vm/runtime/os.cpp @ 6814:85f1cded9793
8000230: Change os::print_location to be more descriptive when a location is pointing into an object
Reviewed-by: mgerdin, twisti
author | stefank |
---|---|
date | Fri, 28 Sep 2012 15:34:32 +0200 |
parents | a7509aff1b06 |
children | 87ac5c0a404d |
comparison
equal
deleted
inserted
replaced
6813:5c8fbbfed964 | 6814:85f1cded9793 |
---|---|
896 } else if (p == NULL && ((oopDesc*)addr)->is_oop()) { | 896 } else if (p == NULL && ((oopDesc*)addr)->is_oop()) { |
897 p = (HeapWord*) addr; | 897 p = (HeapWord*) addr; |
898 print = true; | 898 print = true; |
899 } | 899 } |
900 if (print) { | 900 if (print) { |
901 st->print_cr(INTPTR_FORMAT " is an oop", addr); | 901 if (p == (HeapWord*) addr) { |
902 st->print_cr(INTPTR_FORMAT " is an oop", addr); | |
903 } else { | |
904 st->print_cr(INTPTR_FORMAT " is pointing into object: " INTPTR_FORMAT, addr, p); | |
905 } | |
902 oop(p)->print_on(st); | 906 oop(p)->print_on(st); |
903 return; | 907 return; |
904 } | 908 } |
905 } else { | 909 } else { |
906 if (Universe::heap()->is_in_reserved(addr)) { | 910 if (Universe::heap()->is_in_reserved(addr)) { |