Subject: toolchain/25591: gcc 3.3.3 nb2 for arm loops while compiling several of groff's files
To: None <gnats-bugs@gnats.netbsd.org>
From: None <he@netbsd.org>
List: netbsd-bugs
Date: 05/16/2004 10:07:03
>Number: 25591
>Category: toolchain
>Synopsis: gcc 3.3.3 nb2 for arm loops while compiling several of groff's files
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: toolchain-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sun May 16 08:08:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator: Havard Eidnes
>Release: NetBSD 2.0E May 14, (host: NetBSD 2.0_BETA May 10)
>Organization:
>Environment:
System: NetBSD stegg.urc.uninett.no 2.0_BETA NetBSD 2.0_BETA (STEGG.MP) #6: Mon May 10 23:17:24 CEST 2004 he@stegg.urc.uninett.no:/usr/obj/sys/arch/i386/compile.i386/STEGG.MP i386
Architecture: arm
Machine: netwinder
>Description:
A recently built cross compiler for arm loops while compiling
several of groff's files in gnu/usr.bin/groff/src/libs/libgroff.
I observed it using 511 CPU minutes on cmap.cpp, and 4+ on
color.cpp.
The compiler is:
stegg: {6} /usr/tools/bin/arm--netbsdelf-g++ --version
arm--netbsdelf-g++ (GCC) 3.3.3 (NetBSD nb2 20040502)
Copyright (C) 2003 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
stegg: {7}
>How-To-Repeat:
Try to cross-build libgroff for arm with a recently updated
toolchain.
>Fix:
This works as a workaround for this directory, but this should
be fixed properly by finding and fixing the gcc optimizer bug:
Index: Makefile
===================================================================
RCS file: /usr/users/he/nbcvs/netbsd/src/gnu/usr.bin/groff/src/libs/libgroff/Makefile,v
retrieving revision 1.5
diff -u -r1.5 Makefile
--- Makefile 21 Oct 2003 10:01:20 -0000 1.5
+++ Makefile 16 May 2004 08:03:05 -0000
@@ -23,6 +23,17 @@
.include <bsd.lib.mk>
+.if ${MACHINE_CPU} == "arm"
+COPTS.cmap.cpp+= -O0
+COPTS.color.cpp+= -O0
+COPTS.cset.cpp+= -O0
+COPTS.errarg.cpp+= -O0
+COPTS.font.cpp+= -O0
+COPTS.nametoindex.cpp+= -O0
+COPTS.paper.cpp+= -O0
+COPTS.tmpname.cpp+= -O0
+.endif
+
version.cpp: ${GROFF_DIST}/VERSION ${GROFF_DIST}/REVISION
${_MKTARGET_CREATE}
(\
>Release-Note:
>Audit-Trail:
>Unformatted: