From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: Marc Bejarano <beej@alum.mit.edu>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	bugme-daemon@bugzilla.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: [Bug 11800] New: building SES support fails w/ gcc-3.4.5
Date: Thu, 23 Oct 2008 11:35:13 -0500	[thread overview]
Message-ID: <1224779713.3330.13.camel@localhost.localdomain> (raw)
In-Reply-To: <200810231614.m9NGEg1p019191@colby.verdasys.com>
On Thu, 2008-10-23 at 12:14 -0400, Marc Bejarano wrote:
> At 17:17 10/22/2008, James Bottomley wrote:
>  >On Wed, 2008-10-22 at 13:30 -0700, Andrew Morton wrote:
>  >> OK, it's here:
>  >>
>  >> 	buf = kmalloc(vpd_len, GFP_KERNEL);
>  >>
>  >> it's a gcc bug.
>  >>
>  >> Please see if you can find some way to make it go away - perhaps change
>  >> vpd_len's type to `int', things like that.
>  >>
>  >> Or use a different compiler version :(
> 
> i'm not worried about compiling this.  i already did a compilation 
> without it and i'll be fine without SES.  i just selected it on the 
> off chance i'd find time to play with it.  i was just doing my duty 
> of reporting this to save others the trouble.
> 
>  >Could it be an optimisation issue?  The static oversize test relies on
>  >the compiler optimising away a leg that can never be reached if the size
>  >is under the max. If you do a make V=1 you'll see what optimisation
>  >flags the compiler is using ... if it's -O2 then yes, the compiler
>  >should be optimising stuff away and it's a clear compiler problem.  If
>  >it's anything else, we might have a mis setting of the optimisation
>  >level in the kernel build.
> 
> looks to me like -Os:
I think we have a winner: -Os is rather less well implemented in older
versions of gcc.  Could you retry with -O2?
You do this by setting the config option
CONFIG_CC_OPTIMIZE_FOR_SIZE
to N (it defaults to Y).  If we verify this to be the root cause, we
might consider making the default for that option N if gcc version is <
4.
James
next prev parent reply	other threads:[~2008-10-23 16:35 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-21 18:36 [Bug 11800] New: building SES support fails w/ gcc-3.4.5 bugme-daemon
2008-10-21 22:52 ` Andrew Morton
     [not found]   ` <200810221943.m9MJh8bR031381@colby.verdasys.com>
2008-10-22 20:30     ` Andrew Morton
2008-10-22 21:17       ` James Bottomley
2008-10-23 16:14         ` Marc Bejarano
2008-10-23 16:35           ` James Bottomley [this message]
2008-10-27 17:48             ` Marc Bejarano
2008-10-21 22:52 ` [Bug 11800] " bugme-daemon
2008-10-22 19:43 ` bugme-daemon
2008-10-22 20:31 ` bugme-daemon
2008-10-22 21:17 ` bugme-daemon
2008-10-23 16:15 ` bugme-daemon
2008-10-23 16:35 ` bugme-daemon
2008-10-27 17:48 ` bugme-daemon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox
  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):
  git send-email \
    --in-reply-to=1224779713.3330.13.camel@localhost.localdomain \
    --to=james.bottomley@hansenpartnership.com \
    --cc=akpm@linux-foundation.org \
    --cc=beej@alum.mit.edu \
    --cc=bugme-daemon@bugzilla.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY
  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
  Be sure your reply has a Subject: header at the top and a blank line
  before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).