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: <20080429090327.GA19269@cs181133002.pp.htv.fi>
Date:	Tue, 29 Apr 2008 12:03:27 +0300
From:	Adrian Bunk <bunk@...nel.org>
To:	Sam Ravnborg <sam@...nborg.org>
Cc:	Linus Torvalds <torvalds@...ux-foundation.org>,
	Ingo Molnar <mingo@...e.hu>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	"H. Peter Anvin" <hpa@...or.com>,
	Alexander van Heukelum <heukelum@...lshack.com>,
	jdike@...toit.com
Subject: Re: [2.6 patch] fs/block_dev.c:I_BDEV() mustn't be inline

On Tue, Apr 29, 2008 at 10:17:05AM +0200, Sam Ravnborg wrote:
> On Tue, Apr 29, 2008 at 11:06:31AM +0300, Adrian Bunk wrote:
> > On Mon, Apr 28, 2008 at 05:41:11PM -0700, Linus Torvalds wrote:
> > >...
> > > > -inline struct block_device *I_BDEV(struct inode *inode)
> > > > +struct block_device *I_BDEV(struct inode *inode)
> > > >  {
> > > >  	return &BDEV_I(inode)->bdev;
> > > >  }
> > > 
> > > There is NO WAY IN HELL this function shouldn't be inlined,
> > >...
> > 
> > Then CONFIG_OPTIMIZE_INLINING already broke it in your tree.
> 
> Can you please help me here.
> Previously we said: gcc shall inline
> Now we say: hi gcc - it is a good idea to inline this

Previosly we said:
"inline" means "must inline"

With CONFIG_OPTIMIZE_INLINING=y we say:
"inline" means "try a bit harder to inline"

> But even without any inline annotation we would expect gcc
> to inline it based on normal heuristics simply due to the
> small size/footprint of the function.

gcc anyway has to emit one global copy of this function.

And with the common CONFIG_CC_OPTIMIZE_FOR_SIZE=y we tell gcc to focus 
on getting the smallest possible code.

> So I cannot see how the CONFIG_OPTIMIZE_INLINING have any
> effect here.
> It all smells like a gcc bug to me.

The compile error is a gcc bug.

> 	Sam

cu
Adrian

-- 

       "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