This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Null pointer check elimination
On Sat, 2005-11-12 at 12:30 -0500, Diego Novillo wrote:
> On Saturday 12 November 2005 12:24, Laurent GUERBY wrote:
> > Note that this correspond to the "not null" feature added to Ada 2006
> > in various places, including pointer type definitions:
> >
> > type Ptr is not null access Integer;
> >
> Ah, this is different and it would be very helpful. If it's a language
> mandated thing, then VRP could just rely in this type attribute and
> default to 'non-zero' when it can't infer any other useful value.
Yes it's language mandated (well when the ISO Ada 2006 revision is out
next year :), my guess is that the Ada front-end remove some of it's own
checks based on this but that this information is not passed outside the
front-end, may be Richard Kenner or Robert Dewar can comment on this.
Laurent