From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52302) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YsEAm-0007vb-8K for qemu-devel@nongnu.org; Tue, 12 May 2015 13:40:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YsEAi-0007ku-Vv for qemu-devel@nongnu.org; Tue, 12 May 2015 13:40:52 -0400 Received: from mail-qc0-x233.google.com ([2607:f8b0:400d:c01::233]:35207) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YsEAi-0007km-JV for qemu-devel@nongnu.org; Tue, 12 May 2015 13:40:48 -0400 Received: by qcbgu10 with SMTP id gu10so8592871qcb.2 for ; Tue, 12 May 2015 10:40:48 -0700 (PDT) Received: from anchor.com (50-194-63-110-static.hfc.comcastbusiness.net. [50.194.63.110]) by mx.google.com with ESMTPSA id f4sm13701736qhe.9.2015.05.12.10.40.46 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 12 May 2015 10:40:47 -0700 (PDT) Sender: Richard Henderson From: Richard Henderson Date: Tue, 12 May 2015 10:39:45 -0700 Message-Id: <1431452387-20280-16-git-send-email-rth@twiddle.net> In-Reply-To: <1431452387-20280-1-git-send-email-rth@twiddle.net> References: <1431452387-20280-1-git-send-email-rth@twiddle.net> Subject: [Qemu-devel] [PATCH v2 15/17] target-alpha: Suppress underflow from CVTTQ if DNZ List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org I.e. respect flush_inputs_to_zero. Reported-by: Al Viro Signed-off-by: Richard Henderson --- target-alpha/fpu_helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target-alpha/fpu_helper.c b/target-alpha/fpu_helper.c index ea1f2e2..fa4401d 100644 --- a/target-alpha/fpu_helper.c +++ b/target-alpha/fpu_helper.c @@ -452,7 +452,7 @@ static uint64_t do_cvttq(CPUAlphaState *env, uint64_t a, int roundmode) frac = a & 0xfffffffffffffull; if (exp == 0) { - if (unlikely(frac != 0)) { + if (unlikely(frac != 0) && !env->fp_status.flush_inputs_to_zero) { goto do_underflow; } } else if (exp == 0x7ff) { -- 2.1.0