Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IurDU-0007kQ-TI for qemu-devel@nongnu.org; Wed, 21 Nov 2007 10:10:16 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IurDU-0007kE-AT for qemu-devel@nongnu.org; Wed, 21 Nov 2007 10:10:16 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IurDU-0007kB-8M for qemu-devel@nongnu.org; Wed, 21 Nov 2007 10:10:16 -0500 Received: from hall.aurel32.net ([88.191.38.19]) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1IurDT-00053f-Tb for qemu-devel@nongnu.org; Wed, 21 Nov 2007 10:10:16 -0500 Date: Wed, 21 Nov 2007 16:10:11 +0100 From: Aurelien Jarno Subject: Re: [Qemu-devel] qemu fpu/softfloat-specialize.h fpu/softfloat.c... Message-ID: <20071121151011.GD23909@hall.aurel32.net> References: <4743F1AA.2020904@aurel32.net> <47440B0D.1050601@aurel32.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <47440B0D.1050601@aurel32.net> Sender: "aurel32,,," Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: paul@nowt.org On Wed, Nov 21, 2007 at 11:40:13AM +0100, Aurelien Jarno wrote: > Aurelien Jarno a écrit : > > Blue Swirl a écrit : > >> On 11/18/07, Paul Brook wrote: > >>> CVSROOT: /sources/qemu > >>> Module name: qemu > >>> Changes by: Paul Brook 07/11/18 14:33:24 > >>> > >>> Modified files: > >>> fpu : softfloat-specialize.h softfloat.c softfloat.h > >>> target-arm/nwfpe: double_cpdo.c single_cpdo.c > >>> target-m68k : helper.c op.c > >>> target-mips : op_helper.c > >>> > >>> Log message: > >>> Add strict checking mode for softfp code. > >> This commit has broken sparc-softmmu, for example Aurora 1.0 normally prints: > >> Running anaconda - please wait... > > > > There are also FPU regressions for mips-softmmu, but I haven't found > > time to find the commit that has broken it, I just know it has been > > broken over the week-end. > > > > More later... > > I am now able to confirm this very same commit has also broken the FPU > on mips-softmmu, but I still don't know what is wrong in this commit. > Ok the problem comes from bad copy&paste. Please find a patch below that fixes the problem on MIPS. Index: fpu/softfloat.c =================================================================== RCS file: /sources/qemu/qemu/fpu/softfloat.c,v retrieving revision 1.8 diff -u -d -p -r1.8 softfloat.c --- fpu/softfloat.c 18 Nov 2007 14:33:23 -0000 1.8 +++ fpu/softfloat.c 21 Nov 2007 15:06:19 -0000 @@ -3012,7 +3012,7 @@ int float64_eq( float64 a, float64 b STA return 0; } av = float64_val(a); - bv = float64_val(a); + bv = float64_val(b); return ( av == bv ) || ( (bits64) ( ( av | bv )<<1 ) == 0 ); } @@ -3038,7 +3038,7 @@ int float64_le( float64 a, float64 b STA aSign = extractFloat64Sign( a ); bSign = extractFloat64Sign( b ); av = float64_val(a); - bv = float64_val(a); + bv = float64_val(b); if ( aSign != bSign ) return aSign || ( (bits64) ( ( av | bv )<<1 ) == 0 ); return ( av == bv ) || ( aSign ^ ( av < bv ) ); @@ -3064,7 +3064,7 @@ int float64_lt( float64 a, float64 b STA aSign = extractFloat64Sign( a ); bSign = extractFloat64Sign( b ); av = float64_val(a); - bv = float64_val(a); + bv = float64_val(b); if ( aSign != bSign ) return aSign && ( (bits64) ( ( av | bv )<<1 ) != 0 ); return ( av != bv ) && ( aSign ^ ( av < bv ) ); @@ -3088,7 +3088,7 @@ int float64_eq_signaling( float64 a, flo return 0; } av = float64_val(a); - bv = float64_val(a); + bv = float64_val(b); return ( av == bv ) || ( (bits64) ( ( av | bv )<<1 ) == 0 ); } @@ -3116,7 +3116,7 @@ int float64_le_quiet( float64 a, float64 aSign = extractFloat64Sign( a ); bSign = extractFloat64Sign( b ); av = float64_val(a); - bv = float64_val(a); + bv = float64_val(b); if ( aSign != bSign ) return aSign || ( (bits64) ( ( av | bv )<<1 ) == 0 ); return ( av == bv ) || ( aSign ^ ( av < bv ) ); @@ -3145,7 +3145,7 @@ int float64_lt_quiet( float64 a, float64 aSign = extractFloat64Sign( a ); bSign = extractFloat64Sign( b ); av = float64_val(a); - bv = float64_val(a); + bv = float64_val(b); if ( aSign != bSign ) return aSign && ( (bits64) ( ( av | bv )<<1 ) != 0 ); return ( av != bv ) && ( aSign ^ ( av < bv ) ); -- .''`. Aurelien Jarno | GPG: 1024D/F1BCDB73 : :' : Debian developer | Electrical Engineer `. `' aurel32@debian.org | aurelien@aurel32.net `- people.debian.org/~aurel32 | www.aurel32.net