Seems that Eclipse Memory Analyzer Can I run Java garbage collection against a heap dump file? do that:
By default unreachable objects are removed
@Guntram Blohm. As you say the reason for OOME is out of memory or storage manager was unable to reclaim enough memory. In case if you require long array for fragmented memory it is possible that GC isn't performed at all!