Projects
Tom Tromey
tromey@cygnus.com
Thu May 4 10:55:00 GMT 2000
>>>>> "Jon" == Jonathan P Olson <olson@mmsi.com> writes:
>> I think they still make sense. We don't have to solve the whole
>> problem, because in general we aren't going to be allocated unions
>> or weird C structures using the GC. We only have to solve the part
>> of the problem relating to GCable objects -- i.e., Java objects.
Jon> I disagree with the idea that only Java should get garbage
Jon> collection. Garbage collection makes most problems much simpler
Jon> and makes many problems tractable that are totally intractable
Jon> without a collector.
Ok, I don't disagree. I like GC. I think more people should use it.
I think we can do both things, by choosing the write barrier and GC
implementations appropriately. In some situations, it makes sense to
have precise (and maybe copying) GC for Java and the subset of C++
that deals with Java objects. In other situations, something else is
more appropriate.
Jon> With CNI, there isn't really a clear distinction between what is
Jon> a C++ object and what is a Java object.
That's only partly true. We can definitely tell the difference.
Sometimes we generate different code depending on what kinds of object
are in use.
Anyway, I'm not arguing that we must only do one solution or the
other. I think we should make it possible to do either thing,
depending on the task at hand.
On of my concerns here is that JITs these days have precise, copying
GCs, and we know that GC performance is an important part of overall
system performance. I think we'll need similar technology to continue
to do as well as (or better than) the JITs. This is not to say that
our system doesn't have other benefits which don't apply to JITs. But
I think we have to accept that performance is definitely an important
benefit of precompilation.
Tom
More information about the Java
mailing list