From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 92807DDFBA for ; Tue, 14 Apr 2009 19:38:27 +1000 (EST) In-Reply-To: <49E39F3D.4060501@twiddle.net> References: <49E39F3D.4060501@twiddle.net> Mime-Version: 1.0 (Apple Message framework v753.1) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: From: Segher Boessenkool Subject: Re: alpha: half done futex implementation Date: Tue, 14 Apr 2009 11:40:50 +0200 To: Richard Henderson Cc: Oliver Falk , linux-kernel@vger.kernel.org, linuxppc-dev@ozlabs.org, Ivan Kokshaysky , linux-alpha@vger.kernel.org, Matt Turner , Jay Estabrook List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , > Also, there's a bug in the powerpc implementation. It appears that > oparg is clobbered, and if stwcx fails the operation will be > repeated with incorrect inputs. If either the lwarx or the stwcx. faults, the routine returns -EFAULT and doesn't retry (label "3" is the end of the asm). If the stwcx. fails because the CPU lost the reservation, %1 isn't clobbered as far as I see? Segher