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: <20071024164113.GX30533@stusta.de>
Date:	Wed, 24 Oct 2007 18:41:13 +0200
From:	Adrian Bunk <bunk@...nel.org>
To:	Paul Menage <menage@...gle.com>
Cc:	Paul Jackson <pj@....com>, linux-kernel@...r.kernel.org
Subject: Re: [2.6 patch] kernel/cgroup.c: make 2 functions static

On Wed, Oct 24, 2007 at 09:32:26AM -0700, Paul Menage wrote:
> On 10/24/07, Adrian Bunk <bunk@...nel.org> wrote:
> > cgroup_is_releasable() and notify_on_release() should be static,
> > not global inline.
> >
> 
> They seem like they could be usefully static inline - or will the
> compiler inline them anyway since they're simple enough?

gcc [1] will currently always inline a static cgroup_is_releasable() as 
long as it only has one caller.

Besides this, the compiler has the opportunity to inline all static 
functions when it thinks this makes sense, and it can base it's decision 
on things like whether we gave it -Os/-O2 and which CPU it's compiling 
for.

Long term manually forced "inline" has negative effects since functions 
tend to become larger and more often called without the "inline" 
removed, so don't use it unless there is a visible performance 
difference.

> Paul

cu
Adrian

[1] I'm talking about gcc 4

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ