[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Reasonable values for the -Xmx parameter ?

Le lundi 08 mars 2010 à 20:11 +0100, Vincent Fourmond a écrit :
> Hello,
>   I'm wondering really what could be a decent value for -Xmx parameter.
> I used to think that the lowest parameter that seem to let the program
> run for every arch is good, but I don't think anymore this is a good idea:
>   * the program might be clever enough to not allocate more memory than
> it can, while still being able to use significantly more to speedup (for
> instance through the use of caches)
>   * the tightest the memory, the more often the GC has to run, which
> could lead to performance penalties.
>   My question then is: is there a problem setting it to a value big
> enough (say, -Xmx1G) for a standard app ? (I'm thinking about freecol,
> that takes up quite a lot of memory) After all, most of the other
> programming languages don't limit memory by default, and the use of the
> ulimit shell builtin permits some fine tuning for this parameter (and
> others).
>   What do you think ?
I had previous bad experiences on setting more memory than available. It
leaded to unexpected crashes and I had to come back to 256m. 
It is a really pity that it is still mandatory to specify it... 


Reply to: