Cast not your Perl before swine?

Levi Pearson levi at cold.org
Mon Dec 17 13:42:57 MST 2007


"Bryan Sant" <bryan.sant at gmail.com> writes:
>
> It is?  The JVM is actually very efficient with its use of resources.
> I think the false impression that people have about Java being loose
> with resources is that fact that the JVM will use as much memory as
> you give it permission to use.  By default, the JVM sets that limit to
> be 128MB of RAM (admittedly high for a default in my opinion).
> However, Java SE can run in 1MB of RAM, and Java ME can run in
> kilobytes on your phone.  Sloppy, resource hungry apps can be written
> in any language, including Java, but there is nothing inherently
> inefficient about the way Java handles resources.

In the literature regarding the performance of garbage collecting
runtimes vs. explicit memory management, it has been shown that GC
systems require roughly twice the heap space to be available as would
be needed in an explicitly-managed heap in order to maintain optimal
performance.  Starving the GC heap leads to extreme performance
degradation, so it's understandable that the jvm is configured with a
fairly generous heap by default.  Unfortunately, that means you get to
hear both 'Java is slow!' when it isn't anymore, and 'Java is a
resource hog!' which might be considered true, but keeps the former
from being true in many cases.

I'm sorry I don't have a reference for you for the paper right now,
but I could probably dig it up if you're really interested.

                --Levi



More information about the PLUG mailing list