Hi,
I keep finding examples where CSmith outputs programs that won't
compiler with -Werror.
Try for example seed: 2039717906
GCC:
$ gcc -v
Using built-in specs.
Target: i386-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--enable-checking=release --with-system-zlib --enable-__cxa_atexit
--disable-libunwind-exceptions --enable-libgcj-multifile
--enable-languages=c,c++,objc,java,f95,ada --enable-java-awt=gtk
--with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre
--host=i386-redhat-linux
Thread model: posix
gcc version 4.0.2 20051125 (Red Hat 4.0.2-8)
Output:
$ gcc -Werror -O -o test test.c -I../local/csmith-runtime
cc1: warnings being treated as errors
test.c:44: warning: integer constant is too large for 'unsigned long' type
test.c:46: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:64: warning: integer constant is too large for 'unsigned long' type
test.c:74: warning: integer constant is too large for 'unsigned long' type
test.c:82: warning: integer constant is too large for 'unsigned long' type
test.c:88: warning: integer constant is too large for 'unsigned long' type
test.c:102: warning: integer constant is too large for 'unsigned long' type
test.c:109: warning: integer constant is too large for 'unsigned long' type
test.c:109: warning: integer constant is too large for 'unsigned long' type
test.c:117: warning: integer constant is too large for 'unsigned long' type
test.c:121: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c:122: warning: integer constant is too large for 'unsigned long' type
test.c: In function 'func_29':
test.c:469: warning: integer constant is too large for 'unsigned long' type
test.c: In function 'func_45':
test.c:638: warning: comparison is always true due to limited range of
data type
test.c:750: warning: overflow in implicit constant conversion
test.c:817: warning: integer constant is too large for 'unsigned long' type
test.c:915: confused by earlier errors, bailing out
What's going on? CSmith bug?
Cheers,