NetBSD Problem Report #32117
From tsutsui@ceres.dti.ne.jp Sat Nov 19 14:17:54 2005
Return-Path: <tsutsui@ceres.dti.ne.jp>
Received: from smtp00.dti.ne.jp (smtp00.dti.ne.jp [202.216.228.136])
by narn.netbsd.org (Postfix) with ESMTP id 7012663B90F
for <gnats-bugs@gnats.NetBSD.org>; Sat, 19 Nov 2005 14:17:53 +0000 (UTC)
Message-Id: <200511191417.jAJEHpAG029399@mirage.ceres.dti.ne.jp>
Date: Sat, 19 Nov 2005 23:17:51 +0900 (JST)
From: tsutsui@ceres.dti.ne.jp
Reply-To: tsutsui@ceres.dti.ne.jp
To: gnats-bugs@netbsd.org
Cc: tsutsui@ceres.dti.ne.jp
Subject: ld.elf_so/Makefile shouldn't set -O3 for all ports
X-Send-Pr-Version: 3.95
>Number: 32117
>Category: bin
>Synopsis: ld.elf_so/Makefile shouldn't set -O3 for all ports
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: bin-bug-people
>State: closed
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Sat Nov 19 14:18:00 +0000 2005
>Closed-Date: Fri Nov 01 23:54:56 +0000 2019
>Last-Modified: Fri Nov 01 23:54:56 +0000 2019
>Originator: Izumi Tsutsui
>Release: NetBSD 3.99.11
>Organization:
>Environment:
NetBSD/i386, but possibly affects all ports.
>Description:
src/libexec/ld.elf_so/Makefile explicitly sets DBG=-O3 -fomit-frame-pointer ,
but on some ports gcc -O3 may be problematic so it shouldn't be
specified by defaut.
>How-To-Repeat:
Code inspection.
>Fix:
Override DBG only on ports whose gcc -O3 is confirmed working properly.
At least, ports which have DBG=-O (not -O2) by default shouldn't use -O3
here.
Index: Makefile
===================================================================
RCS file: /cvsroot/src/libexec/ld.elf_so/Makefile,v
retrieving revision 1.72
diff -u -r1.72 Makefile
--- Makefile 4 Jun 2005 16:17:17 -0000 1.72
+++ Makefile 19 Nov 2005 14:09:00 -0000
@@ -47,7 +47,9 @@
#CPPFLAGS+= -DRTLD_DEBUG
#CPPFLAGS+= -DRTLD_DEBUG_RELOC
#DBG= -g
+.if (${MACHINE_ARCH} == "i386")
DBG= -O3 -fomit-frame-pointer
+.endif
.if ${SHLIBDIR} != ${LIBDIR}
CPPFLAGS+= -DRTLD_DEFAULT_LIBRARY_PATH=\"${SHLIBDIR}:${LIBDIR}\"
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback
State-Changed-By: maya@NetBSD.org
State-Changed-When: Wed, 23 Oct 2019 14:59:19 +0000
State-Changed-Why:
This has been the default for a while. Are there cases that you suspected would be broken by it?
State-Changed-From-To: feedback->closed
State-Changed-By: tsutsui@NetBSD.org
State-Changed-When: Fri, 01 Nov 2019 23:54:56 +0000
State-Changed-Why:
No visible problem, just a matter of opinion for possible risk and benefit.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.