This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

tree-ssa bug?


Built off CVS branch tree-ssa-20020619-branch.
Linux 2.4, i386

OK, here is another very strange result, took me a bit of time to track
this one down.
  -------------------------------------------
#!/bin/sh

cat >zz.c <<EOF
#include <stdio.h>

#define XXX 2147483647

int main ()
{
        unsigned long count = 8;

        if (count > XXX)
                fprintf (stderr, "wow!\n");

        return (0);
}
EOF

/usr/local/gcc-mudflap/bin/i686-pc-linux-gnu-gcc-3.5-tree-ssa -fmudflap
\
        -Wall -o zz zz.c
./zz
  -------------------------------------------
The reult is:
wow!

Looks like a bug to me. Same result when the constant is
	0x7fffffff
or
	0x7fffffffUL

--
Eyal Lebedinsky (eyal at eyal dot emu dot id dot au) <http://samba.org/eyal/>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]