lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200309064806.GB46830@google.com>
Date:   Mon, 9 Mar 2020 15:48:06 +0900
From:   Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>
To:     Joe Perches <joe@...ches.com>
Cc:     Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Johannes Weiner <hannes@...xchg.org>,
        Michal Hocko <mhocko@...nel.org>,
        Vladimir Davydov <vdavydov.dev@...il.com>,
        Hugh Dickins <hughd@...gle.com>,
        Minchan Kim <minchan@...nel.org>,
        Nitin Gupta <ngupta@...are.org>, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org, cgroups@...r.kernel.org,
        Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>
Subject: Re: [PATCH] mm: Use fallthrough;

On (20/03/09 15:20), Sergey Senozhatsky wrote:
[..]
> > <shrug, maybe>  I've no real opinion about that necessity.
> > 
> > fallthrough commments are relatively rarely used as a
> > separating element between case labels.
> > 
> > It's by far most common to just have consecutive case labels
> > without any other content.
> > 
> > It's somewhere between 500:1 to 1000:1 in the kernel.
> 
> I thought that those labels were used by some static code analysis
> tools, so that the removal of some labels raised questions. But I
> don't think I have opinions otherwise.

... I guess GCC counts as a static code analysis tool :)

Looking at previous commits, people wanted to have proper 'fall through'


    Replace "fallthru" with a proper "fall through" annotation.
    This fix is part of the ongoing efforts to enabling
    -Wimplicit-fallthrough

---

-       case ZPOOL_MM_RW: /* fallthru */
+       case ZPOOL_MM_RW: /* fall through */

---


> Consecutive case labels do not need an interleaving fallthrough;

I suppose this means that GCC -Wimplicit-fallthrough handles it?

	-ss

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ