This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/53385] [4.8 Regression] "Error: operand out of range" after changes for LSHIFT_EXPR in vrp.c
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 18 May 2012 08:17:42 +0000
- Subject: [Bug tree-optimization/53385] [4.8 Regression] "Error: operand out of range" after changes for LSHIFT_EXPR in vrp.c
- Auto-submitted: auto-generated
- References: <bug-53385-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53385
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #9 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-05-18 08:17:42 UTC ---
Isn't this just a fancy way of saying
i = val ? clz_hwi (val) - 1 : HOST_BITS_PER_WIDE_INT;
? Note that the predicate ensures that the whole operand isn't 0,
so one might as well use just i = clzi_hwi (val) - 1; and just adjust the
else if (GET_CODE (x) == CONST_DOUBLE && i == 32)
test to compare i == 31 instead (and tweak the body not to i-- if the low hwi
is negative and do another clz_hwi otherwise).