When a corefile gets created, the CDS archive regions mapped as MAP_SHARED do not get dumped into the corefile. To overcome this limitation, these regions get read in the Serviceability Agent (SA) directly from the classes.jsa in ps_core.c. For reading the regions in, the FileMapHeader structure (from src/hotspot/share/memory/filemap.hpp) is replicated in SA in ps_core.c. This replication is error prone and the copy in SA gets out of sync quickly w.r.t. the version in hotspot. This should be avoidable on Linux by setting the coredump_filter to dump the MAP_SHARED regions. (Need to explore the corresponding mechanism for other platforms). If there is no such mechanism for other platforms, then a lesser solution of including filemap.hpp in SA could be explored.
- duplicates
-
JDK-8200613 SA: jstack throws UnmappedAddressException with a CDS core file
- Resolved
- relates to
-
JDK-8200613 SA: jstack throws UnmappedAddressException with a CDS core file
- Resolved
-
JDK-8174994 SA: clhsdb printmdo throws WrongTypeException when attached to a process with CDS
- Resolved