On Sat, Dec 30, 2000 at 01:18:23AM -0800, Mr.Bad wrote:
> >>>>> "TB" == Travis Bemann
><[EMAIL PROTECTED]> writes:
>
> TB> One possible memory leak is the protected/private memory leak,
> TB> which is a major problem in Java that is somewhat equivalent
> TB> to the classical memory leak in languages such as C and C++.
>
> Travis,
>
> I'm not sure I understand the problem you're explaining (although it
> sounds completely plausible). Could you maybe post a code sample that
> illustrates this memory overuse? (Scott seems determined not to call
> it a "leak", which I guess it isn't technically.)
>
> A couple of places I would look at for memory probs, just off the top
> of my noggin:
>
> 1) The StandardDataStore* uses a hash and an array for storing
> the same DSItems. This kind of rings some bells about
> circular refs and whatnot, and it -seems- like
In Java, circular references are not a problem. However, in some
languages such as Python which use reference count based GC, this is a
major problem that has to be dealt with.
> 2) The thread pools.** Creating new threads -does- eat memory,
> and having a ton of them around might be a problem. I've
> noticed that if I reduce the maximumConnectThreads
> parameter for my node to 10-15 from the default 50, memory
> usage stays in the 10-20Mb range rather than up around the
> 60s and 70s. This might be illusory, but it could be a good
> place to investigate.
This is quite correct. However, there are important advantages to
thread pools, such as no thread creation overhead (which isn't a
significant factor under Linux but is very signficant under
environments such as Windows 95/98/ME or Windows NT/2K where thread
creation is as slow as process creation.
--
Travis Bemann
Sendmail is still screwed up on my box.
My email address is really [EMAIL PROTECTED]
PGP signature