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


Groups > linux.kernel > #1378420

Re: [PATCH] net: force inlining of netif_tx_start/stop_queue, sock_hold, __sock_put

From David Miller <davem@davemloft.net>
Newsgroups linux.kernel
Subject Re: [PATCH] net: force inlining of netif_tx_start/stop_queue, sock_hold, __sock_put
Date 2016-04-14 04:50 +0200
Message-ID <rnFvX-30r-5@gated-at.bofh.it> (permalink)
References <rlGZc-67T-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Denys Vlasenko <dvlasenk@redhat.com>
Date: Fri,  8 Apr 2016 17:51:54 +0200

> Sometimes gcc mysteriously doesn't inline
> very small functions we expect to be inlined. See
>     https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66122
> Arguably, gcc should do better, but gcc people aren't willing
> to invest time into it, asking to use __always_inline instead.
> 
> With this .config:
> http://busybox.net/~vda/kernel_config_OPTIMIZE_INLINING_and_Os,
> the following functions get deinlined many times.
  ...
> This patch fixes this via s/inline/__always_inline/.
> 
> Code size decrease after the patch is ~2.5k:
> 
>     text      data      bss       dec     hex filename
> 56719876  56364551 36196352 149280779 8e5d80b vmlinux_before
> 56717440  56364551 36196352 149278343 8e5ce87 vmlinux
> 
> Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>

Applied to net-next, thanks.

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


Thread

[PATCH] net: force inlining of netif_tx_start/stop_queue, sock_hold, __sock_put Denys Vlasenko <dvlasenk@redhat.com> - 2016-04-08 18:00 +0200
  Re: [PATCH] net: force inlining of netif_tx_start/stop_queue,  sock_hold, __sock_put David Miller <davem@davemloft.net> - 2016-04-14 04:50 +0200

csiph-web