From owner-svn-src-all@freebsd.org Fri Aug 28 14:38:56 2015 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B07FD9C555D; Fri, 28 Aug 2015 14:38:56 +0000 (UTC) (envelope-from joerg@britannica.bec.de) Received: from mo6-p00-ob.smtp.rzone.de (mo6-p00-ob.smtp.rzone.de [IPv6:2a01:238:20a:202:5300::10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.smtp.rzone.de", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id CECDD1395; Fri, 28 Aug 2015 14:38:55 +0000 (UTC) (envelope-from joerg@britannica.bec.de) X-RZG-AUTH: :JiIXek6mfvEEUpFQdo7Fj1/zg48CFjWjQv0cW+St/nW/auYssSp3lXGnYOgGHMs= X-RZG-CLASS-ID: mo00 Received: from britannica.bec.de (ip-2-207-250-194.web.vodafone.de [2.207.250.194]) by smtp.strato.de (RZmta 37.11 DYNA|AUTH) with ESMTPSA id w02284r7SEcmrpu (using TLSv1 with cipher AES256-SHA (256 bits)) (Client did not present a certificate); Fri, 28 Aug 2015 16:38:48 +0200 (CEST) Received: by britannica.bec.de (sSMTP sendmail emulation); Fri, 28 Aug 2015 16:38:47 +0200 Date: Fri, 28 Aug 2015 16:38:47 +0200 From: Joerg Sonnenberger To: Bruce Evans Cc: Xin LI , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r287217 - head/usr.sbin/syslogd Message-ID: <20150828143847.GA24222@britannica.bec.de> References: <201508271811.t7RIB0xl077002@repo.freebsd.org> <20150828215109.G1227@besplex.bde.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150828215109.G1227@besplex.bde.org> User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Aug 2015 14:38:56 -0000 On Fri, Aug 28, 2015 at 10:17:56PM +1000, Bruce Evans wrote: > >-static void die(int); > >+static void die(int) __dead2; > > Since the function is static, it is very easy for the compiler to see > that it doesn't return. But the compiler can't tell if it is the *intention* that the function never returns. The warning behavior exists because that can easily change with macros etc. > Even gcc-4.2.1 does this by default, since > -O implies -funit-at-a-time for gcc-4.2.1. For clang, there is no way > to prevent this (except possibly -O0) since, since -fno-unit-at-a-time > is broken in clang. It is not broken. It is loadly ignored as unsupported. The very existance of the option in GCC has always been a concession to broken and badly written code, including of course GCC's own CRT. Joerg