Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Jun 1997 11:39:15 -0700 (MST)
From:      Terry Lambert <terry@lambert.org>
To:        babkin@hq.icb.chel.su (Serge A. Babkin)
Cc:        jkh@time.cdrom.com, hackers@FreeBSD.ORG
Subject:   Re: C optimizer bug ?
Message-ID:  <199706151839.LAA16658@phaeton.artisoft.com>
In-Reply-To: <199706150136.HAA07646@hq.icb.chel.su> from "Serge A. Babkin" at Jun 15, 97 07:36:45 am

next in thread | previous in thread | raw e-mail | index | archive | help
> Okay, here is the description: The function scsi_done() must check
> whether xs->bp is zero and then depending on it call biodone()

Declare this variable volitile.  You are probably suffering from
overambitious ANSI register optimization, where the value being
tested is loaded into a register and never reloaded (there's
actually no excuse for this, given that the compiler can determine
loop scoping and see from that whether or not the optimization
would fail).  Sun's ANSI C and othes have similar problems.

Probably the success depends upon whether the value is initially
zero or not.


					Terry Lambert
					terry@lambert.org
---
Any opinions in this posting are my own and not those of my present
or previous employers.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199706151839.LAA16658>