RFR: 8229278: Improve hs_err location printing to assume less about GC internals
erik.osterlund at oracle.com
Tue Aug 27 14:49:50 UTC 2019
Thank you for the review. I like your cleanups. I folded them in to the
next webrev: http://cr.openjdk.java.net/~eosterlund/8229278/webrev.01/
On 2019-08-27 15:20, Stefan Karlsson wrote:
> Hi Erik,
> On 2019-08-08 11:46, Erik Österlund wrote:
>> Today when we crash and print hs_err files, the printing utility for
>> describing heap locations assumes:
>> 1) That the Java heap memory reservation is contiguous
>> 2) That the Java heap is parseable
>> We should let the GC describe a location instead, opting in to such
>> This patch adds a print_location pure virtual function on CollectedHeap
>> allowing the GC to choose printing strategy. A new LocationPrinter
>> utility was added, allowing GCs to implement the functionality easily
>> without much code duplication.
> This looks good, but I have some cleanups I'd like to make. If you agree
> we can either fold this into your patch, or I can create a separate RFE
> for it:
> 1) Fixed some includes.
> 2) Replaced address with void*. I'd like to no propagate the usage of
> 'address' into GC code.
> 3) Fixed the usage of is_readable_range to actually include check that
> the address of the klass field is readable.
> 4) Changed/removed some casts.
> 5) Removed redundant is_in check in ZGC's print_location.
More information about the hotspot-gc-dev