Re: cvs.transvirtual.com unreachable and other news

Date view Thread view Subject view Author view

From: Godmar Back (gback@cs.utah.edu)
Date: Mon Oct 19 1998 - 12:26:17 EDT


>
> Godmar Back writes:
> > > Are you talking about the problem of objects that contain pointers
> > > to non-object blocks of memory (such objects are necessarily used
> > > by native code)?
> >
> > Yes.
> >
> > > If so, why not just create a byte[] array to hold the native-private data?
> > > I'm not sure I know what I'm asking about however..
> >
> > Well, a byte[] array would be the clean way, but it would be unnecessary
> > overhead in memory and access time (and require lots of rewriting, which
> > I'm not inclined to do).
>
> In general, this non-object memory would need to get garbage
> collected along with the object itself, right? Having a byte[]
> array lets this happen automatically with your precise gc.
>
> Otherwise, won't every object that has such "private memory"
> require a special finalizer to free it? Sounds ripe for potential
> memory leaks.
>
> It may actually be easier to use byte[] than to add finalizers to
> all these objects, not to mention that using byte[] carries no
> maintenance penalty, whereas remembering to free private memory
> does.
>
> When you're talking about embedded systems, a slightly slower system
> with no memory leaks is vastly preferable to the reverse.
>

 In most cases, you need special destructors anyway because the
object referred to is something "special" that requires an explicit
free operation, be it jthread_destroy or XWindowDestroy or whatever.

That reminds me: do we free the backtraces if a throwable is gc'ed?
I have to check that.

        - Godmar


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 19:57:00 EDT