This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
org.netbeans.lib.profiler.heap.StringSegment has a big HashMap<Long,Long>. In 700M heap dump, it has about 600000 entries and consumes over 50M of memory. The memory consumption of the StringSegment instance can be improved by replacing HashMap<Long,Long> with a special type of map. It uses long[] to store the key/values pairs (similar idea is used in IdentityHashMap, where key/value pairs are stored in Object[]). Such map consumes around 15M in the same heap dump.
Fixed in profiler-main changeset: 266015:ca4b9d2ce94a user: Tomas Hurka <thurka@netbeans.org> date: Thu Oct 31 16:30:02 2013 +0100 summary: issue #237864, use LongHashMap instead of HashMap<Long,Long>