Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp169220pxu; Wed, 25 Nov 2020 16:32:22 -0800 (PST) X-Google-Smtp-Source: ABdhPJxgqcWYAaOSWWA//ugOiB+WgABPtXrFc39wvt48H6dF1qtVxS1oFbuKdV63boP/Nbn0lWRb X-Received: by 2002:a50:9f6c:: with SMTP id b99mr244295edf.90.1606350742437; Wed, 25 Nov 2020 16:32:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606350742; cv=none; d=google.com; s=arc-20160816; b=XlSDa8pfkVAzZrQ71k9bt0s3qyFxS+Pbr3iLx8smDzRwjegrs3x8KnAqa7RpxFvt/N 3mXtjRF+J4dqhVK8+9JuInicqfqSP5WVM9hi71AbhXWjUVnU04T5lvaUmfKhSAVklA0O c0d+wBIoJAoQfX68z7QOB0rVuzKRUevgISoCkXNA/OcRVQC99yVbRTg01NZYoLfTIXaL vDhCMSKrVJz+/A4XeIjQhVMLIvschHdechj3PONYLx1fjuRYOOghw3Yk0HnBonQQXGAu VD7QK5Jn7ivYIrhIExvvEtjdRmwlE7P7QcEFt6cxmigcQmGpY76E9YT+ebx4bzPifZZf G+EQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:message-id:in-reply-to :subject:cc:to:from:date; bh=M7UU1XruReqkgV2EZo8qKWtBkhyhIOgt13YiwD+M9q4=; b=B4ulcqB7cf8BLBJi+S0tyqFMtDf+lmlBssrkk1zcMVEJmtywFyMaebmdThmmjKtQXC qvmqWyIE9Ty8YOQ3QqvlUsA/e2p63+0AWykVbTvta2GmgUY7rlaxrh7RNLFZ1lTrKLzu 0fyt8vyUoHOdxYIZD7DUoNkgcl/qmV37lFVQ5ISADKL2cMo5P5Cj18oKYxK92dz+sNZO wp8Q7XIQfQ/ldBL8yNPwCABl4lvefcltm4b/fwjb7yyweQmWZXTXeKXe2RobnJA9VCOv xNwl5+gIGyufhWihhMU7aSHUKRsKow4OLONU6mtOKPpi6VVaqFqfDr4HJgPVqsg1tL/j +YgA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z10si2486246edp.346.2020.11.25.16.31.50; Wed, 25 Nov 2020 16:32:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728708AbgKZAap (ORCPT + 99 others); Wed, 25 Nov 2020 19:30:45 -0500 Received: from kvm5.telegraphics.com.au ([98.124.60.144]:42610 "EHLO kvm5.telegraphics.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726009AbgKZAao (ORCPT ); Wed, 25 Nov 2020 19:30:44 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by kvm5.telegraphics.com.au (Postfix) with ESMTP id 742A42A495; Wed, 25 Nov 2020 19:30:37 -0500 (EST) Date: Thu, 26 Nov 2020 11:30:36 +1100 (AEDT) From: Finn Thain To: Nick Desaulniers cc: James Bottomley , Kees Cook , "Gustavo A. R. Silva" , Joe Perches , Jakub Kicinski , alsa-devel@alsa-project.org, linux-atm-general@lists.sourceforge.net, reiserfs-devel@vger.kernel.org, linux-iio@vger.kernel.org, linux-wireless , linux-fbdev@vger.kernel.org, dri-devel , LKML , Nathan Chancellor , linux-ide@vger.kernel.org, dm-devel@redhat.com, keyrings@vger.kernel.org, linux-mtd@lists.infradead.org, GR-everest-linux-l2@marvell.com, wcn36xx@lists.infradead.org, samba-technical@lists.samba.org, linux-i3c@lists.infradead.org, linux1394-devel@lists.sourceforge.net, linux-afs@lists.infradead.org, usb-storage@lists.one-eyed-alien.net, drbd-dev@lists.linbit.com, devel@driverdev.osuosl.org, linux-cifs@vger.kernel.org, rds-devel@oss.oracle.com, linux-scsi@vger.kernel.org, linux-rdma@vger.kernel.org, oss-drivers@netronome.com, bridge@lists.linux-foundation.org, linux-security-module@vger.kernel.org, amd-gfx list , linux-stm32@st-md-mailman.stormreply.com, cluster-devel@redhat.com, linux-acpi@vger.kernel.org, coreteam@netfilter.org, intel-wired-lan@lists.osuosl.org, linux-input@vger.kernel.org, Miguel Ojeda , tipc-discussion@lists.sourceforge.net, linux-ext4@vger.kernel.org, linux-media@vger.kernel.org, linux-watchdog@vger.kernel.org, selinux@vger.kernel.org, linux-arm-msm , intel-gfx@lists.freedesktop.org, linux-geode@lists.infradead.org, linux-can@vger.kernel.org, linux-block@vger.kernel.org, linux-gpio@vger.kernel.org, op-tee@lists.trustedfirmware.org, linux-mediatek@lists.infradead.org, xen-devel@lists.xenproject.org, nouveau@lists.freedesktop.org, linux-hams@vger.kernel.org, ceph-devel@vger.kernel.org, virtualization@lists.linux-foundation.org, Linux ARM , linux-hwmon@vger.kernel.org, "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , linux-nfs@vger.kernel.org, GR-Linux-NIC-Dev@marvell.com, Linux Memory Management List , Network Development , linux-decnet-user@lists.sourceforge.net, linux-mmc@vger.kernel.org, Linux-Renesas , linux-sctp@vger.kernel.org, linux-usb@vger.kernel.org, netfilter-devel@vger.kernel.org, "open list:HARDWARE RANDOM NUMBER GENERATOR CORE" , patches@opensource.cirrus.com, linux-integrity@vger.kernel.org, target-devel@vger.kernel.org, linux-hardening@vger.kernel.org, Jonathan Cameron , Greg KH Subject: Re: [Intel-wired-lan] [PATCH 000/141] Fix fall-through warnings for Clang In-Reply-To: Message-ID: References: <202011201129.B13FDB3C@keescook> <20201120115142.292999b2@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> <202011220816.8B6591A@keescook> <9b57fd4914b46f38d54087d75e072d6e947cb56d.camel@HansenPartnership.com> <0147972a72bc13f3629de8a32dee6f1f308994b5.camel@HansenPartnership.com> <20201123130348.GA3119@embeddedor> <8f5611bb015e044fa1c0a48147293923c2d904e4.camel@HansenPartnership.com> <202011241327.BB28F12F6@keescook> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Wed, 25 Nov 2020, Nick Desaulniers wrote: > On Wed, Nov 25, 2020 at 1:33 PM Finn Thain wrote: > > > > Or do you think that a codebase can somehow satisfy multiple checkers > > and their divergent interpretations of the language spec? > > Have we found any cases yet that are divergent? I don't think so. You mean, aside from -Wimplicit-fallthrough? I'm glad you asked. How about -Wincompatible-pointer-types and -Wframe-larger-than? All of the following files have been affected by divergent diagnostics produced by clang and gcc. arch/arm64/include/asm/neon-intrinsics.h arch/powerpc/xmon/Makefile drivers/gpu/drm/i915/Makefile drivers/gpu/drm/i915/i915_utils.h drivers/staging/media/atomisp/pci/atomisp_subdev.c fs/ext4/super.c include/trace/events/qla.h net/mac80211/rate.c tools/lib/string.c tools/perf/util/setup.py tools/scripts/Makefile.include And if I searched for 'smatch' or 'coverity' instead of 'clang' I'd probably find more divergence. Here are some of the relevant commits. 0738c8b5915c7eaf1e6007b441008e8f3b460443 9c87156cce5a63735d1218f0096a65c50a7a32aa babaab2f473817f173a2d08e410c25abf5ed0f6b 065e5e559555e2f100bc95792a8ef1b609bbe130 93f56de259376d7e4fff2b2d104082e1fa66e237 6c4798d3f08b81c2c52936b10e0fa872590c96ae b7a313d84e853049062011d78cb04b6decd12f5c 093b75ef5995ea35d7f6bdb6c7b32a42a1999813 And before you object, "but -Wconstant-logical-operand is a clang-only warning! it can't be divergent with gcc!", consider that the special cases added to deal with clang-only warnings have to be removed when gcc catches up, which is more churn. Now multiply that by the number of checkers you care about.