From: Michal Jaegermann <michal@ellpspace.math.ualberta.ca>
To: axp-list@redhat.com
Subject: Re: problems with md driver (RAID-1) on RH 7.2, DP264 machine -- SOLUTION
Date: Tue, 24 Sep 2002 10:42:00 -0600 [thread overview]
Message-ID: <20020924104200.A15133@ellpspace.math.ualberta.ca> (raw)
In-Reply-To: <3D907DB5.828F52A1@iplink.net>; from alvin@iplink.net on Tue, Sep 24, 2002 at 10:59:01AM -0400
On Tue, Sep 24, 2002 at 10:59:01AM -0400, alvin wrote:
> Chris Szilagyi wrote:
> >
> > The solution to this problem is to
> > add "-fno-strength-reduce" to CFLAGS in arch/alpha/Makefile and recompile
> > the entire kernel.
But this affects files in a subdirectory arch/alpha or these flags
are inherited by the entire kernel?
>
> I actaully ended up finding the offending code in the md driver I
> believe that this is a bug in the gcc optimizer but I had no luck
> creating a small test case and the gcc boys don't like being sent a full
> kernel as an example of the bug.
>
> the offending code was:
>
> new_disk--;
> if (new_disk == disk) {
And this code is drivers/md/raid1.c so adding "-fno-strength-reduce"
only in this subdirectory should provide a workaround as well. Right?
You mean that if you are recompiling only 'raid1.c' code, not
mentioning 'raid1_read_balance ()' function then this bug is not showing
up? AFAIK an optimizer in gcc is not crossing file boundaries.
> and breaks on the test of new_disk in the if statement. by changing the
> code to
>
> new_disk--;
> md_bugcheck(disk);
> if (new_disk == disk) {
>
> where md_bugcheck does nothing but return caused the optimizer to handle
> the case differently.
This is not that surprising. 'md_bugcheck' may have side effects
Michal
next prev parent reply other threads:[~2002-09-24 16:42 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-09-03 14:21 problems with md driver (RAID-1) on RH 7.2, DP264 machine Chris Szilagyi
2002-09-24 13:58 ` problems with md driver (RAID-1) on RH 7.2, DP264 machine -- SOLUTION Chris Szilagyi
2002-09-24 14:59 ` alvin
2002-09-24 15:46 ` Falk Hueffner
2002-09-24 16:31 ` alvin
2002-09-24 16:40 ` George France
2002-09-24 16:38 ` George France
2002-09-24 16:42 ` Michal Jaegermann [this message]
2002-09-24 17:05 ` Chris Szilagyi
2002-09-24 17:21 ` alvin
2002-09-24 17:47 ` Chris Szilagyi
2002-09-24 18:28 ` Michal Jaegermann
2002-09-24 18:51 ` George France
2002-09-25 2:49 ` compiler features (was: problems with md driver (RAID-1) on RH 7.2, DP264 machine -- SOLUTION) Alvin Starr
2002-09-25 3:01 ` George France
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox