This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug optimization/14682] [tree-ssa] error: Invalid operand to binary operator
- From: "law at redhat dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 22 Mar 2004 22:43:05 -0000
- Subject: [Bug optimization/14682] [tree-ssa] error: Invalid operand to binary operator
- References: <20040322193838.14682.aj@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From law at redhat dot com 2004-03-22 22:42 -------
Subject: Re: [tree-ssa] error: Invalid operand to
binary operator
In message <20040322221127.1513.qmail@sources.redhat.com>, "pinskia at gcc dot
gnu dot org" writes:
>
>------- Additional Comments From pinskia at gcc dot gnu dot org 2004-03-22 2
>2:11 -------
>Here is a version which uses char instead of long/long long's:
>int __atomic_readv_replacement(unsigned char iov_len, int count, int i) {
> unsigned char bytes = 0;
> if ((unsigned char)((char)127 - bytes) < iov_len)
> return 22;
> return 0;
>}
>
>The problem is that fold is converting 127 < iov_len into (char)( iov_len) <
> 0 which is
>right but it is not gimple.
This is a known problem and already on my list of issues to address.
jeff
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14682