Date: Sat, 6 Jul 1996 11:18:25 +0900 (JST) From: Michael Hancock <michaelh@cet.co.jp> To: Greg Lehey <grog@lemis.de> Cc: FreeBSD Hackers <hackers@FreeBSD.ORG> Subject: Re: gcc lies? Message-ID: <Pine.SV4.3.93.960706111658.28865A-100000@parkplace.cet.co.jp> In-Reply-To: <199607051011.MAA15302@allegro.lemis.de>
next in thread | previous in thread | raw e-mail | index | archive | help
This is probably why BSDI uses gcc 1.x for the kernel and gives their screaming customers 2.7.2. -mike hancock On Fri, 5 Jul 1996, Greg Lehey wrote: > I ran into a bug in gcc yesterday: certain initializers caused it to > SIGSEGV. Before sending in a bug report, I tried it with the BSD/OS > cc, and it worked fine. So I ported 2.7.2, and that worked fine as > well, so I decided not to file a bug report (though I do intend to try > it with the released version of 2.7.2). > > So I installed 2.7.2 as my standard compiler, and hey! suddenly I get > thousands of warnings from my kernel builds. For example, > > gcc -c -O -W -Wreturn-type -Wcomment -Wredundant-decls -Wimplicit -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Winline -Wunused -g -nostdinc -I. -I../.. -I../../sys -I../../../include -DI486_CPU -DI586_CPU -DHARDFONTS -DSCSIDEBUG -DIPACCT -DCOMPAT_43 -DCD9660 -DMSDOSFS -DNFS -DFFS -DINET -DKERNEL ../../kern/kern_descrip.c > ../../kern/kern_descrip.c: In function `getdtablesize': > ../../kern/kern_descrip.c:99: warning: unused parameter `uap' > ../../kern/kern_descrip.c: In function `dup2': > ../../kern/kern_descrip.c:127: warning: comparison between signed and unsigned > ../../kern/kern_descrip.c:130: warning: comparison between signed and unsigned > ../../kern/kern_descrip.c:136: warning: comparison between signed and unsigned > ../../kern/kern_descrip.c:139: warning: comparison between signed and unsigned > ../../kern/kern_descrip.c: In function `dup': > ../../kern/kern_descrip.c:181: warning: comparison between signed and unsigned > ../../kern/kern_descrip.c: In function `fcntl': > ../../kern/kern_descrip.c:213: warning: comparison between signed and unsigned > ../../kern/kern_descrip.c:222: warning: comparison between signed and unsigned > ../../kern/kern_descrip.c: In function `close': > > (that's not all, but it's enough). > > If I compile the same module with the standard release gcc, I get no > warnings at all. How come? At first I thought it might be the header > files, but there's a -nostdinc in there, and I checked: it really does > include just the kernel header files. > > Greg > -- michaelh@cet.co.jp http://www.cet.co.jp CET Inc., Daiichi Kasuya BLDG 8F 2-5-12, Higashi Shinbashi, Minato-ku, Tokyo 105 Japan Tel: +81-3-3437-1761 Fax: +81-3-3437-1766
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.SV4.3.93.960706111658.28865A-100000>