From patchwork Tue Dec 7 14:13:42 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 74552 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 12C55B70A9 for ; Wed, 8 Dec 2010 01:33:57 +1100 (EST) Received: from localhost ([127.0.0.1]:45759 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PPyc5-0004TW-Uv for incoming@patchwork.ozlabs.org; Tue, 07 Dec 2010 09:33:54 -0500 Received: from [140.186.70.92] (port=56902 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PPyX8-0002BH-An for qemu-devel@nongnu.org; Tue, 07 Dec 2010 09:28:48 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PPyX3-00010N-Ks for qemu-devel@nongnu.org; Tue, 07 Dec 2010 09:28:46 -0500 Received: from mnementh.archaic.org.uk ([81.2.115.146]:47408) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PPyX3-0000zN-DS for qemu-devel@nongnu.org; Tue, 07 Dec 2010 09:28:41 -0500 Received: from pm215 by mnementh.archaic.org.uk with local (Exim 4.69) (envelope-from ) id 1PPyIb-0000pM-Om; Tue, 07 Dec 2010 14:13:45 +0000 From: Peter Maydell To: qemu-devel@nongnu.org Date: Tue, 7 Dec 2010 14:13:42 +0000 Message-Id: <1291731225-3155-3-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1291731225-3155-1-git-send-email-peter.maydell@linaro.org> References: <1291731225-3155-1-git-send-email-peter.maydell@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) Cc: Juha.Riihimaki@nokia.com Subject: [Qemu-devel] [PATCH 2/5] ARM: Fix VQSHL of signed 64 bit values X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Juha Riihimäki Add a missing '-' which meant that we were misinterpreting the shift argument for VQSHL of 64 bit signed values and treating almost every shift value as if it were an extremely large right shift. Signed-off-by: Juha Riihimäki Reviewed-by: Peter Maydell --- target-arm/neon_helper.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/target-arm/neon_helper.c b/target-arm/neon_helper.c index 5e6452b..d29b884 100644 --- a/target-arm/neon_helper.c +++ b/target-arm/neon_helper.c @@ -610,7 +610,7 @@ uint64_t HELPER(neon_qshl_s64)(CPUState *env, uint64_t valop, uint64_t shiftop) SET_QC(); val = (val >> 63) & ~SIGNBIT64; } - } else if (shift <= 64) { + } else if (shift <= -64) { val >>= 63; } else if (shift < 0) { val >>= -shift;