Bruce Evans wrote: > On Sat, 3 Aug 2002, Mike Barcroft wrote: > > >>Andrew Kolchoogin <[EMAIL PROTECTED]> writes: >> >>>... >>>sorry, but some time ago I read here that gcc -O2 breaks our printf() in >>>libc. I haven't find any assembler code in /usr/src/lib/libc/stdio/vfprintf.c, >>>as such, if some C compiler can't handle VALID and STANDARDS-COMPLIANT C code, >>>this compiler is broken. Isn't it? >>> >>>Indeed, all of FreeBSD users could help to catch such a bug in gcc optimizer >>>code. :) >> >>If someone could find the small segment of code where the optimizer >>screws up, and write a small program to demonstrate the problem, we >>would have a good chance of it getting fixed. > > > Er, someone (Dan Lukes) has already done this. See PR 40209. I'm sorry > I haven't found time to look at it in detail.
O2-compiling -CURRENT (and -march=athlon ...) still manages to break DCCs in xchat, like: Program received signal SIGBUS, Bus error. 0x286b3220 in __vfprintf () from /usr/lib/libc.so.5 (gdb) bt #0 0x286b3220 in __vfprintf () from /usr/lib/libc.so.5 #1 0x286b20ca in __vfprintf () from /usr/lib/libc.so.5 #2 0x286ad622 in snprintf () from /usr/lib/libc.so.5 #3 0x08066036 in fe_dcc_update_recv () #4 0x08086ee0 in dcc_check_timeouts () #5 0x0809dd83 in lag_check () #6 0x2825c496 in g_timeout_dispatch () from /usr/local/lib/libglib12.so.3 #7 0x2825b658 in g_main_dispatch () from /usr/local/lib/libglib12.so.3 #8 0x2825bbf9 in g_main_iterate () from /usr/local/lib/libglib12.so.3 #9 0x2825bd86 in g_main_run () from /usr/local/lib/libglib12.so.3 #10 0x2844fa38 in gtk_main () from /usr/X11R6/lib/libgtk12.so.2 #11 0x08069311 in fe_main () #12 0x0809e950 in main () #13 0x080638c1 in _start () Regards, -- Michael Nottebrock "And the reasons? There are no reasons."
Description: PGP signature