Results 1 to 1 of 1
- 06-30-2009, 02:28 AM #1
Member
- Join Date
- Jun 2009
- Posts
- 1
- Rep Power
- 0
Using Memory Analyzer to examine the heap
[Note: Partially resolved, but please read on!]
I'm using a fairly massive array at one point in my code and am running into problems allocating enough memory to the heap. I've tried up to 1024MB, but the error still occurs. So, I want to see just how big various array sizes are in the heap using jmap to save the heap and memory analyzer to examine it.
My Eclipse command line, which runs out of a WinXP desktop shortcut:
"C:\eclipse 3.5\eclipse.exe" -vmargs -Xms512m -Xmx512m
I'm using jmap with the following command to create a heap snapshot:
jmap -dump:format=b,file=snapshot1.bin <process id>
The process ID used is that of Eclipse.
When I load the heap up in memory analyzer, it's only about 20 - 30MB regardless of whether I use a 30 x 30 array or a 4000 x 4000 array. I can't go much more beyond 4000 x 4000 before I receive:
"java.lang.OutOfMemoryError: Java heap space"
But clearly the heap is not that large. Any ideas? Maybe I'm not saving everything to the heap with my procedure above?
Thank you!
[Edit: Partially resolved this problem thanks to another post in this forum (which I can't link to due to my newbie status). However, I still don't know why my heap size is so small when exported].Last edited by Bolo33; 06-30-2009 at 02:38 AM.
Similar Threads
-
JVm Heap memory settings
By nagesh in forum Advanced JavaReplies: 2Last Post: 09-17-2009, 05:47 PM -
heap memory usage anomaly?
By jon80 in forum Threads and SynchronizationReplies: 1Last Post: 06-30-2009, 06:56 AM -
[SOLVED] JVM: Heap out of memory
By jwilley44 in forum EclipseReplies: 7Last Post: 02-01-2009, 04:13 PM -
how do I increase memory allocated to code cache (Non Heap Memory)
By manibhat in forum Advanced JavaReplies: 2Last Post: 08-21-2008, 07:33 PM -
JVM Heap memory settings
By nagesh in forum New To JavaReplies: 1Last Post: 08-11-2007, 10:17 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks