From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57753) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VsZyJ-0006Jk-2B for qemu-devel@nongnu.org; Mon, 16 Dec 2013 10:20:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VsZyD-0006cl-8R for qemu-devel@nongnu.org; Mon, 16 Dec 2013 10:20:38 -0500 Message-ID: <52AF1A3B.4060806@gmail.com> Date: Mon, 16 Dec 2013 09:20:27 -0600 From: Tom Musta MIME-Version: 1.0 References: <1386604035-2507-1-git-send-email-tommusta@gmail.com> <1386604035-2507-10-git-send-email-tommusta@gmail.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 09/18] softfloat: Fix Handling of Small Negatives in float64_to_uint64 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: "qemu-ppc@nongnu.org" , QEMU Developers On 12/12/2013 6:13 PM, Peter Maydell wrote: > On 9 December 2013 15:47, Tom Musta wrote: >> The float64_to_uint64 routine exits early for all negative numbers. >> While the integer result is always correctly returned as 0, the >> exception flags are also always set to float_flag_invalid. This >> is incorrect for those cases where a small negative number (-1 < x < 0) >> rounds to zero. In such a case, the flag should be reported as >> inexact. > >> -static int64 roundAndPackUint64(uint64_t absZ0, uint64_t absZ1 STATUS_PARAM) >> +static int64 roundAndPackUint64(flag zSign, uint64_t absZ0, >> + uint64_t absZ1 STATUS_PARAM) > > This function isn't in the copy of fpu/softfloat.c that's in master, > unless I'm confused. Does this series depend on something else? > > thanks > -- PMM > Peter: Yes, it does. See http://lists.nongnu.org/archive/html/qemu-devel/2013-11/msg00045.html and specifically patch 1/19.