This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: get_condition causes overlow for sign extended constants
- To: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- Subject: Re: get_condition causes overlow for sign extended constants
- From: Joern Rennecke <amylaar at cygnus dot co dot uk>
- Date: Tue, 18 Mar 1997 20:02:10 +0000 (GMT)
> case GE:
> if (const_val
> != (((HOST_WIDE_INT) 1
>
> Wouldn't changing this "1" to "-1" also fix it and in a cleaner way?
> If that works, please send me the resulting patch.
It would fix the problem I pointed out, but it would create new problems.
If op0 has a narrower mode than HOST_WIDE_INT, overflow will not be
detected by your version.