Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1601357

Re: [PATCH 4/7] kref: Remove WARN_ON for NULL release functions

From Peter Zijlstra <peterz@infradead.org>
Newsgroups linux.kernel
Subject Re: [PATCH 4/7] kref: Remove WARN_ON for NULL release functions
Date 2017-03-15 13:30 +0100
Message-ID <tlgdY-7yR-3@gated-at.bofh.it> (permalink)
References <tl6HD-OK-3@gated-at.bofh.it> <tl6HD-OK-9@gated-at.bofh.it> <tl7aG-Zf-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, Mar 15, 2017 at 10:46:56AM +0800, Greg KH wrote:
> On Tue, Mar 14, 2017 at 07:14:28PM -0700, Andi Kleen wrote:
> > From: Andi Kleen <ak@linux.intel.com>
> > 
> > The kref functions check for NULL release functions.
> > This WARN_ON seems rather pointless. We will eventually release and
> > then just crash nicely. It is also somewhat expensive because
> > these functions are inlined in a lot of places.
> > Removing the WARN_ONs saves around 2.3k in this kernel
> > (likely more in others with more drivers)
> > 
> >    text    data     bss     dec     hex filename
> > 9083992 5367600 11116544        25568136        1862388 vmlinux-before-load-avg
> > 9070166 5367600 11116544        25554310        185ed86 vmlinux-load-avg
> 
> WARN_ON() is heavy, didn't realize that.

I actually have patches fixing that.

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH 4/7] kref: Remove WARN_ON for NULL release functions Andi Kleen <andi@firstfloor.org> - 2017-03-15 03:20 +0100
  Re: [PATCH 4/7] kref: Remove WARN_ON for NULL release functions Greg KH <gregkh@linuxfoundation.org> - 2017-03-15 03:50 +0100
    Re: [PATCH 4/7] kref: Remove WARN_ON for NULL release functions Peter Zijlstra <peterz@infradead.org> - 2017-03-15 13:30 +0100

csiph-web