This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Improve PR30911 and PR31023, Ada and VRP
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- To: duncan dot sands at math dot u-psud dot fr
- Cc: ebotcazou at adacore dot com, gcc-patches at gcc dot gnu dot org, rguenther at suse dot de
- Date: Tue, 01 Apr 2008 09:38:09 EDT
- Subject: Re: [PATCH] Improve PR30911 and PR31023, Ada and VRP
- References: <Pine.LNX.4.64.0803291749290.4133@zhemvz.fhfr.qr> <200803310940.50027.duncan.sands@math.u-psud.fr> <200803312220.27682.ebotcazou@adacore.com> <200804011422.08311.duncan.sands@math.u-psud.fr>
> I still think that the right thing to do in the long-term is to introduce
> __builtin_assume and remove funky integer types from the middle-end. If
> Richard's experiment works out then that would show that the front-end could
> generate calls to __builtin_assume at the start of every subroutine, saying
> to assume that parameters belong to their ranges, without breaking anything.
> It would make it much easier to play with different levels of assumptions,
> for example trying to find a sweet spot between Bob Duff and Richard Kenner.
I'm not at all clear that the only useful case is parameters. Consider the
case where there's a pragma saying that everything must be initialized. In
that case, nearly *all* values (including fields of records) must be valid
and I don't think you can do all that with __builtin_assume.