Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LBotQ-0006sB-PK for qemu-devel@nongnu.org; Sun, 14 Dec 2008 06:12:13 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LBotQ-0006rt-7K for qemu-devel@nongnu.org; Sun, 14 Dec 2008 06:12:12 -0500 Received: from [199.232.76.173] (port=49426 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LBotP-0006rg-Lz for qemu-devel@nongnu.org; Sun, 14 Dec 2008 06:12:11 -0500 Received: from savannah.gnu.org ([199.232.41.3]:60031 helo=sv.gnu.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LBotP-0003Nj-J5 for qemu-devel@nongnu.org; Sun, 14 Dec 2008 06:12:11 -0500 Received: from cvs.savannah.gnu.org ([199.232.41.69]) by sv.gnu.org with esmtp (Exim 4.63) (envelope-from ) id 1LBotO-0002oS-Ty for qemu-devel@nongnu.org; Sun, 14 Dec 2008 11:12:11 +0000 Received: from aurel32 by cvs.savannah.gnu.org with local (Exim 4.63) (envelope-from ) id 1LBotO-0002oN-KQ for qemu-devel@nongnu.org; Sun, 14 Dec 2008 11:12:10 +0000 MIME-Version: 1.0 Errors-To: aurel32 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Aurelien Jarno Message-Id: Date: Sun, 14 Dec 2008 11:12:10 +0000 Subject: [Qemu-devel] [6026] target-ppc: fix fsel instruction 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 Revision: 6026 http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6026 Author: aurel32 Date: 2008-12-14 11:12:10 +0000 (Sun, 14 Dec 2008) Log Message: ----------- target-ppc: fix fsel instruction Fix fsel instruction. Eliminate unneeded temporaries while we're at it, too. Signed-off-by: Nathan Froyd Signed-off-by: Aurelien Jarno Modified Paths: -------------- trunk/target-ppc/op_helper.c Modified: trunk/target-ppc/op_helper.c =================================================================== --- trunk/target-ppc/op_helper.c 2008-12-14 11:12:02 UTC (rev 6025) +++ trunk/target-ppc/op_helper.c 2008-12-14 11:12:10 UTC (rev 6026) @@ -1592,16 +1592,14 @@ /* fsel - fsel. */ uint64_t helper_fsel (uint64_t arg1, uint64_t arg2, uint64_t arg3) { - CPU_DoubleU farg1, farg2, farg3; + CPU_DoubleU farg1; farg1.ll = arg1; - farg2.ll = arg2; - farg3.ll = arg3; if (!fpisneg(farg1.d) || iszero(farg1.d)) - return farg2.ll; + return arg2; else - return farg2.ll; + return arg3; } uint32_t helper_fcmpu (uint64_t arg1, uint64_t arg2)