Similar issue recently fixed: JDK-8171084
[2017-03-12T15:44:23.11] Dumping core ...
[2017-03-12T15:45:11.78] /export/home/aginfra/sandbox/results/ResultDir/JMapHeapCore/run.sh: line 30: 23131 Aborted (core dumped) ${JAVA} ${JAVA_OPTS} heapdump.share.EatMemory -core
[2017-03-12T15:45:11.78] Found core file: core.23131
[2017-03-12T15:45:12.20] Attaching to core core.23131 from executable /export/home/aginfra/CommonData/TEST_JAVA_HOME/bin/java, please wait...
[2017-03-12T15:45:14.01] Debugger attached successfully.
[2017-03-12T15:45:14.01] Server compiler detected.
[2017-03-12T15:45:14.01] JVM version is 9-internal+0-2017-03-12-072902.jesper.dev2104-hs
[2017-03-12T15:46:21.21] WARNING: Cannot dump array of type Object with length 1073741823; truncating to length 536870909
[2017-03-12T15:47:20.58] Exception in thread "main" java.lang.RuntimeException: Heap segment size overflow.
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.utilities.HeapHprofBinWriter.fillInHeapRecordLength(HeapHprofBinWriter.java:495)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.utilities.HeapHprofBinWriter.writeHeapRecordEpilogue(HeapHprofBinWriter.java:479)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.utilities.AbstractHeapGraphWriter$1.doObj(AbstractHeapGraphWriter.java:101)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.oops.ObjectHeap.iterateLiveRegions(ObjectHeap.java:354)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.oops.ObjectHeap.iterate(ObjectHeap.java:172)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.utilities.AbstractHeapGraphWriter.write(AbstractHeapGraphWriter.java:51)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.utilities.HeapHprofBinWriter.write(HeapHprofBinWriter.java:433)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.writeHeapHprofBin(JMap.java:182)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.run(JMap.java:97)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.startInternal(Tool.java:260)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.start(Tool.java:223)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.execute(Tool.java:118)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.main(JMap.java:176)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.SALauncher.runJMAP(SALauncher.java:326)
[2017-03-12T15:47:20.58] at jdk.hotspot.agent/sun.jvm.hotspot.SALauncher.main(SALauncher.java:455)
[2017-03-12T15:47:22.43] jmap exited with exit status 1