This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Patch to avoid SegFault in natClass.cc


>>>>> "Bryce" == Bryce McKinlay <bryce@waitaki.otago.ac.nz> writes:

Bryce> Ideally, I think the compiler should be ensuring classes are
Bryce> initialized before calling these routines. This way many redundant
Bryce> calls can be eliminated.

It seems to me that there's a potential tradeoff between code bloat
(lots of calls to class initialization in the object code) and
performance.

There are 229 calls to instanceof in libgcj.  That's about one per
every 4 classes.  That doesn't seem too bad.  So I'm inclined to agree
that we should have the compiler ensure that the class is initialized.

I think this bug is important enough to fix in 3.0.1.  Bryce, do you
think it would be acceptable to check in Martin's patch on the branch?
Do you agree that this is important enough?

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]