This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Why does GCJ generate so many explicit checks for null pointers?
- From: Tom Tromey <tromey at redhat dot com>
- To: David Daney <ddaney at avtrex dot com>
- Cc: java at gcc dot gnu dot org
- Date: 26 Jul 2003 22:07:31 -0600
- Subject: Re: Why does GCJ generate so many explicit checks for null pointers?
- References: <3F231FE8.9090204@avtrex.com>
- Reply-to: tromey at redhat dot com
>>>>> "David" == David Daney <ddaney@avtrex.com> writes:
David> I am running gcj 3.3 on a i386-linux platform.
How did you configure?
David> I have noticed that in the code the GCJ generates, most (if not
David> all) places that a reference (or is that a pointer) is
David> dereferenced, an explicit check for null is done.
This doesn't happen for me. Do you have sample code that shows the
problem? The smaller the better.
Right now I think the only time we generate an explicit check is when
calling a final method. In this case we must check to see if the
object is null, since we won't get a SEGV if it is.
David> Am I missing something here?
I'm guessing some kind of configuration problem.
Tom