From owner-freebsd-stable@FreeBSD.ORG Wed Oct 11 17:33:00 2006 Return-Path: X-Original-To: stable@freebsd.org Delivered-To: freebsd-stable@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0C2CE16A415; Wed, 11 Oct 2006 17:33:00 +0000 (UTC) (envelope-from mi+mx@aldan.algebra.com) Received: from corbulon.video-collage.com (static-151-204-231-237.bos.east.verizon.net [151.204.231.237]) by mx1.FreeBSD.org (Postfix) with ESMTP id BCD9C43DE7; Wed, 11 Oct 2006 17:23:04 +0000 (GMT) (envelope-from mi+mx@aldan.algebra.com) Received: from [172.21.130.86] (mx-broadway [38.98.68.18]) by corbulon.video-collage.com (8.13.6/8.13.6) with ESMTP id k9BHN3gv023700 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 11 Oct 2006 13:23:03 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) From: Mikhail Teterin Organization: Virtual Estates, Inc. To: stable@freebsd.org Date: Wed, 11 Oct 2006 13:22:57 -0400 User-Agent: KMail/1.9.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200610111322.57735.mi+mx@aldan.algebra.com> X-Virus-Scanned: ClamAV 0.88.4/2024/Wed Oct 11 06:53:09 2006 on corbulon.video-collage.com X-Virus-Status: Clean X-Scanned-By: MIMEDefang 2.43 Cc: gerald@freebsd.org Subject: Bug in 6.x' C++ compiler X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Oct 2006 17:33:00 -0000 GCC would not fix the bug described in http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29390 because the compiler is of an unsupported version (they only support 4.x now). Yet, the problem is rather real and hits when the devel/icu port is built with low optimization (-O1 or -O0). Any chance, someone with interest in GCC internals and FreeBSD can find the fix? Simply compiling the loctest.ii, that is attached to the above bugzilla report, is enough to reproduce the problem. Compiling with `-march=pentium4' triggers the bug -- a bogus symbol is inserted: % c++ -O0 -g -c -pipe -march=pentium4 loctest.ii % nm locate.o | fgrep .LC U .LC786 Compiling without the -march (or with -O2) does not insert the bogus symbol: % c++ -O2 -g -c -pipe -march=pentium4 loctest.ii % nm loctest.o | fgrep .LC % c++ -O0 -g -c -pipe loctest.ii % nm loctest.o | fgrep .LC % I'm seeing this with both 3.4.4 and 3.4.6 versions of GCC... Thanks! -mi