This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/30911] VRP fails to eliminate range checks in Ada code
- From: "baldrick at free dot fr" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Mar 2008 22:48:22 -0000
- Subject: [Bug tree-optimization/30911] VRP fails to eliminate range checks in Ada code
- References: <bug-30911-13647@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #51 from baldrick at free dot fr 2008-03-28 22:48 -------
Subject: Re: VRP fails to eliminate range checks in Ada code
> This is fold simplifying (js__TtB) target_first == -128 to
> target_first == 128 via fold_sign_changed_comparison.
Right, that was my instant guess. The Ada f-e is pretty
systematic about converting everything to the base type
before doing comparisons. While fold happily creates the
kind of strangeness you observed.
> And thus PR31023 which now also blocks this PR.
In fact PR31023 was split out of this because of exactly
this kind of problem in the testcase! I should have marked
it as blocking this one, sorry.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30911