On Tuesday 30 September 2008 02:12:46 Bernhard Reutner-Fischer wrote: > On Mon, Sep 29, 2008 at 09:28:57PM -0500, Rob Landley wrote: > >On Monday 29 September 2008 10:56:04 Bernhard Reutner-Fischer wrote: > >> On Sun, Sep 28, 2008 at 11:55:53AM -0500, Rob Landley wrote: > >> >So with the attached .config, building last night's svn snapshot, is > >> > anybody else seeing this: > >> > > >> >libc/inet/addr.c: In function 'inet_ntoa_r': > >> >libc/inet/addr.c:144: internal compiler error: in output_move_qimode, > >> > at config/m68k/m68k.c:1827 > >> > >> Seems to work for me with the current, stable release of gcc. > > > >I tried 4.1.2 and 4.2.2. You seem to be saying that uClibc for m68k is > > not supported on those. > > No, i'm saying that it compiles for me with the current, stable release > of gcc, i.e. 4.3.2 at the time of this writing. I did not try to use an > outdated version from the old 4.2.x series.
David Wu emailed me offline to say that he's seen this with -O3. I traced down the appropriate line with V=1: ~/firmware/firmware/build/cross-compiler-m68k/bin/m68k-gcc -c \ libc/inet/inet_ntoa.c -o \ libc/inet/inet_ntoa.os -include ./include/libc-symbols.h -Wall \ -Wstrict-prototypes -fno-strict-aliasing -fno-stack-protector -fno-builtin \ -nostdinc -I./include -I. -I./libc/sysdeps/linux/m68k -fno-asm \ -DUCLIBC_INTERNAL -std=gnu99 -Os -funit-at-a-time \ -fno-tree-loop-optimize -fno-tree-dominator-opts \ -fno-strength-reduce -Wa,--bitwise-or \ -I./libpthread/linuxthreads.old/sysdeps/unix/sysv/linux/m68k \ -I./libpthread/linuxthreads.old/sysdeps/m68k \ -I./libpthread/linuxthreads.old/sysdeps/unix/sysv/linux \ -I./libpthread/linuxthreads.old/sysdeps/pthread \ -I./libpthread/linuxthreads.old -I./libpthread \ -I/home/landley/firmware/firmware/build/cross-compiler-m68k/include \ -I/home/landley/firmware/firmware/build/cross-compiler-m68k/bin/../gcc//include-fixed \ -I/home/landley/firmware/firmware/build/cross-compiler-m68k/bin/../gcc/include \ -DNDEBUG -Wa,--bitwise-or -fpic -MT libc/inet/inet_ntoa.os \ -MD -MP -MF libc/inet/.inet_ntoa.os.dep And lo and behold, there's an -Os in there, and removing it does indeed avoid the error. (I've confirmed that any optimization level, including -O2 and -O, triggers the bug in this file.) For the moment, I'm getting by with this patch: --- uClibc/Rules.mak 2008-09-28 02:10:20.000000000 -0500 +++ alt-uClibc/Rules.mak 2008-09-30 16:56:19.000000000 -0500 @@ -144,7 +144,9 @@ # Flags in OPTIMIZATION are used only for non-debug builds OPTIMIZATION:= # Use '-Os' optimization if available, else use -O2, allow Config to override +ifneq ($(TARGET_ARCH),m68k) OPTIMIZATION+=$(call check_gcc,-Os,-O2) +endif # Use the gcc 3.4 -funit-at-a-time optimization when available OPTIMIZATION+=$(call check_gcc,-funit-at-a-time,) Which is overkill in several ways but at least gets me past the bug, and on to the next error: libc/libc_so.a(memcpy.os): In function `memcpy': memcpy.c:(.text+0x6e): undefined reference to `WORD_COPY_FWD' Which I'll worry about in the morning, I guess... Rob _______________________________________________ uClibc mailing list uClibc@uclibc.org http://busybox.net/cgi-bin/mailman/listinfo/uclibc