gcj/SWT gc() and memory

Heitzso heitzso@growthmodels.com
Sun Jun 20 17:35:00 GMT 2004


I'm using Mohan Embar's recent (6/7) toolkit for compiling
SWT apps on Windows and have not attempted the equiv.
on Linux (my primary dev box). 
I had not been aware of GC_MAXIMUM_HEAP_SIZE
and GC_set_max_heap_size(). Using GC_MAXIMUM_HEAP_SIZE
I am able to restrain the gcj version to the same memory
usage as the JRE version. _Thank you!_
I googled on GC_set_max_heap_size() and I didn't find
usage documentation for calling that function from within
a Java program. I found lots of .h files with the function
signature on the internet but no usage documentation.
Is there a 'howto' doc that covers setting memory constraints
similar to -Xms, -Xmx, and other gcj gc settings in the context
of gcj?
Thank you again.
Boehm, Hans wrote:
>You are observing the large heap size under Windows? Or also
>under Linux?
>>If it's under Windows, you might be running into a known issue
>with the collector scanning graphics memory for roots. You
>can get more information about what's going on by either calling
>GC_dump() explicitly, or by running the executable with
>the GC_DUMP_REGULARLY environment variable defined. Especially the
>latter will produce huge volumes of output. You are really interested
>in its description of the root set after the heap has grown.
>>Hans
>>>>>-----Original Message-----
>>From: java-owner@gcc.gnu.org 
>>[mailto:java-owner@gcc.gnu.org]On Behalf Of
>>Heitzso
>>Sent: Saturday, June 19, 2004 10:02 AM
>>To: java@gcc.gnu.org
>>Subject: gcj/SWT gc() and memory
>>>>>>I have a SWT 3.0RC app that generates hundreds of
>>thousands of small short life objects, plus some larger
>>objects. Run under Linux (IBM JRE) or Win (Sun JRE)
>>it stabilizes out around 32M. The same code compiled
>>to native with gcj stabilizes around 100+M. I need
>>to be able to run on old Win98 128M machines so 100+M
>>is too large.
>>>>Is there a better garbage collector I should be
>>turning on or using?
>>>>


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /