From owner-svn-src-all@freebsd.org Thu May 24 16:34:50 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AAF1DEF790B; Thu, 24 May 2018 16:34:50 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from smtp.freebsd.org (unknown [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 546A976D8D; Thu, 24 May 2018 16:34:50 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from mail-it0-f54.google.com (mail-it0-f54.google.com [209.85.214.54]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) (Authenticated sender: mmacy) by smtp.freebsd.org (Postfix) with ESMTPSA id 1C1D11242B; Thu, 24 May 2018 16:34:50 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: by mail-it0-f54.google.com with SMTP id y189-v6so3182839itb.2; Thu, 24 May 2018 09:34:50 -0700 (PDT) X-Gm-Message-State: ALKqPwfazeQIeDnKggLMYgQmPs8Rk7Ed2dsSosEU5tcD2rhdFnkXnyqr 5rl2ORqK3TIXfI831plXpmf8HczzDi4Gdh01hh0= X-Google-Smtp-Source: AB8JxZrkVfdNdxcq74dNuoUwhzmqdi+p1Y87kHmkN0fKY3YMo9UwbdlqLmBPhZn9v+IbCnquuKk15KTBFYFiVKH+3yk= X-Received: by 2002:a24:5a85:: with SMTP id v127-v6mr10237919ita.128.1527179689570; Thu, 24 May 2018 09:34:49 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a02:85ca:0:0:0:0:0 with HTTP; Thu, 24 May 2018 09:34:49 -0700 (PDT) In-Reply-To: <9b7c8c0f-4c33-1a14-f0db-5370c3e5def7@FreeBSD.org> References: <201805190510.w4J5AqfS054367@repo.freebsd.org> <20180523222743.GU71675@FreeBSD.org> <20180523225729.GV71675@FreeBSD.org> <20180524044252.GW71675@FreeBSD.org> <5B9EE208-384F-44AD-9B47-059D77FE9B34@macmic.franken.de> <9b7c8c0f-4c33-1a14-f0db-5370c3e5def7@FreeBSD.org> From: Matthew Macy Date: Thu, 24 May 2018 09:34:49 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r333860 - head/sys/kern To: Pedro Giffuni Cc: Warner Losh , Michael Tuexen , Gleb Smirnoff , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.26 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: Thu, 24 May 2018 16:34:50 -0000 > > False positives are compiler bugs. No they're not. No more than missed optimization opportunities. They're limitations in the control flow analysis. > > It does happen, with GCC more than with clang, that the compiler has too > many bugs and it's a bad practice to pessimize code to work around them. It doesn't pessimize the compiled output. It may make the code less readable in the opinion of some. I've found that 10% of the warnings were actually legitimate issues. It's unfortunate that the majority are just noise that have to be waded through. > At > very least you should add a comment when adding unnecessary initializations, > something like /* workaround GCC */, but dropping broken warnings is best. That's legitimate.