[lworld] Integrated: 8267697: [lworld] [lw3] VM crashes during heap dump if Java heap contains flat arrays
amenkov at openjdk.java.net
Mon Sep 13 19:43:27 UTC 2021
On Wed, 8 Sep 2021 23:18:56 GMT, Alex Menkov <amenkov at openjdk.org> wrote:
> Updated HeapDumper to generate HPROF_GC_INSTANCE_DUMP records for inlined objects (flattened fields and flattened arrays).
> Field values of the inlined objects are read directly from container object/array
> HPROF_GC_INSTANCE_DUMP record requires unique object ID (for identity objects address of the oop is used).
> To generate it InlinedObjectSupport class is implemented which generates ID as 1,2,3,...
> The idea is to write inlined objects in 2 pass:
> - save state of DumpWriter::inlined_object_support;
> - 1st pass (dumping parent object instance fields or array elements): write inlined object ids (generated by DumpWriter::inlined_object_support);
> - 2nd pass: generate HPROF_GC_INSTANCE_DUMP record for inlined objects using ids from saved inlined_object_support.
> 2nd pass works the same way as dumping of parent object, so if inlined objects contain inlined fields HPROF_GC_INSTANCE_DUMP records will be generated for them after dumping of parent object is completed. The process is repeated recursively for all levels of inlined fields nesting.
This pull request has now been integrated.
Author: Alex Menkov <amenkov at openjdk.org>
Stats: 671 lines in 3 files changed: 631 ins; 3 del; 37 mod
8267697: [lworld] [lw3] VM crashes during heap dump if Java heap contains flat arrays
More information about the valhalla-dev