From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:47070) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QA4Xf-0006En-OF for qemu-devel@nongnu.org; Wed, 13 Apr 2011 14:11:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QA4Xe-0002F7-Tb for qemu-devel@nongnu.org; Wed, 13 Apr 2011 14:11:51 -0400 Received: from hall.aurel32.net ([88.191.126.93]:43071) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QA4Xe-0002F1-Ov for qemu-devel@nongnu.org; Wed, 13 Apr 2011 14:11:50 -0400 Date: Wed, 13 Apr 2011 20:11:48 +0200 From: Aurelien Jarno Message-ID: <20110413181148.GA31121@volta.aurel32.net> References: <1302645571-20500-1-git-send-email-aurelien@aurel32.net> <1302645571-20500-18-git-send-email-aurelien@aurel32.net> <20110413024032.GS23480@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <20110413024032.GS23480@codesourcery.com> Subject: Re: [Qemu-devel] [PATCH 17/19] target-ppc: fix SPE comparison functions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Nathan Froyd Cc: qemu-devel@nongnu.org, Alexander Graf On Tue, Apr 12, 2011 at 07:40:33PM -0700, Nathan Froyd wrote: > On Tue, Apr 12, 2011 at 11:59:29PM +0200, Aurelien Jarno wrote: > > Given that float32_*() functions are IEEE754 compliant, the efscmp*() > > functions are correctly implemented, while efstst*() are not. This > > patch reverse the implementation of this two groups of functions and > > fix the comments. It also use float32_eq() instead of float32_eq_quiet() > > as qNaNs should not be ignored. > > Thanks for addressing this; the E500 emulation in QEMU is more like how > we wish the hardware acted, rather than how it actually acts. :) > > It's late here, but I think this change: > > > -static inline uint32_t efscmplt(uint32_t op1, uint32_t op2) > > +static inline uint32_t efststlt(uint32_t op1, uint32_t op2) > > { > > - /* XXX: TODO: test special values (NaN, infinites, ...) */ > > + /* XXX: TODO: ignore special values (NaN, infinites, ...) */ > > return efststlt(op1, op2); > > } > > is not correct, as you've just turned this into an infinite (inlined!) > loop. You'd want to change the efststlt call into an efscmplt call. > Similarly for efstst{gt,eq}. > Thanks for catching that, I'll fix that in the next version. -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurelien@aurel32.net http://www.aurel32.net