Well, the GC is free to delay garbage collection until "out of memory", so the scenario could be that heap builds up, and as memory is needed, "trash" is swapped out by the OS as you suggest, until the -Xmx limit is hit, and the GC will now walk (and compact) the heap, checking each block if it has been marked or not.
I suspect that many of the tuning parameters affect the behavior, as well as the exact usage patterns in the code. I am not suggesting one way over the other, just that your categorical statement that OS will swap out unused memory isn't that simple. Cheers Niclas On Sun, Dec 4, 2011 at 8:03 PM, Luke Daley <[email protected]> wrote: > > > > > On 04/12/2011, at 12:11 AM, Niclas Hedhman <[email protected]> wrote: > >> On Sun, Dec 4, 2011 at 6:14 AM, Luke Daley <[email protected]> wrote: >>> I don't think this is much of an issue. The OS will page out the unused JVM >>> heap. >> >> Depends on GC settings. Potentially you keep filling up all memory >> with dead objects, then hit a full GC cycle which may take 'forever' >> to complete. > > I don't quite understand the kind of lifecycle that would trigger this. > > Would you mind going into a bit more detail? > > > > > --------------------------------------------------------------------- > To unsubscribe from this list, please visit: > > http://xircles.codehaus.org/manage_email > > -- Niclas Hedhman, Software Developer http://www.qi4j.org - New Energy for Java I live here; http://tinyurl.com/3xugrbk I work here; http://tinyurl.com/6a2pl4j I relax here; http://tinyurl.com/2cgsug --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
