Received: from [140.186.70.92] (port=40088 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PwOP4-0005pB-Go for qemu-devel@nongnu.org; Sun, 06 Mar 2011 19:34:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PwOP2-0000vE-In for qemu-devel@nongnu.org; Sun, 06 Mar 2011 19:34:26 -0500 Received: from fmmailgate02.web.de ([217.72.192.227]:37778) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PwOP2-0000up-2B for qemu-devel@nongnu.org; Sun, 06 Mar 2011 19:34:24 -0500 Received: from smtp06.web.de ( [172.20.5.172]) by fmmailgate02.web.de (Postfix) with ESMTP id 426FB19A20B6D for ; Mon, 7 Mar 2011 01:34:23 +0100 (CET) From: =?UTF-8?q?Andreas=20F=C3=A4rber?= Date: Mon, 7 Mar 2011 01:34:13 +0100 Message-Id: <1299458053-69428-10-git-send-email-andreas.faerber@web.de> In-Reply-To: <1299458053-69428-9-git-send-email-andreas.faerber@web.de> References: <1294169951-5153-5-git-send-email-andreas.faerber@web.de> <1299458053-69428-1-git-send-email-andreas.faerber@web.de> <1299458053-69428-2-git-send-email-andreas.faerber@web.de> <1299458053-69428-3-git-send-email-andreas.faerber@web.de> <1299458053-69428-4-git-send-email-andreas.faerber@web.de> <1299458053-69428-5-git-send-email-andreas.faerber@web.de> <1299458053-69428-6-git-send-email-andreas.faerber@web.de> <1299458053-69428-7-git-send-email-andreas.faerber@web.de> <1299458053-69428-8-git-send-email-andreas.faerber@web.de> <1299458053-69428-9-git-send-email-andreas.faerber@web.de> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: andreas.faerber@web.de Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PATCH v5 10/10] softfloat: Use [u]int_fast64_t consistently List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Andreas=20F=C3=A4rber?= v5: * Initial. Signed-off-by: Andreas F=C3=A4rber --- fpu/softfloat-native.c | 26 +++++++++++++------------- fpu/softfloat-native.h | 28 ++++++++++++++-------------- fpu/softfloat.c | 4 ++-- 3 files changed, 29 insertions(+), 29 deletions(-) diff --git a/fpu/softfloat-native.c b/fpu/softfloat-native.c index 2c08958..3aa64f6 100644 --- a/fpu/softfloat-native.c +++ b/fpu/softfloat-native.c @@ -103,24 +103,24 @@ floatx80 int32_to_floatx80(int_fast32_t v STATUS_PA= RAM) return (floatx80)v; } #endif -float32 int64_to_float32( int64_t v STATUS_PARAM) +float32 int64_to_float32( int_fast64_t v STATUS_PARAM) { return (float32)v; } -float32 uint64_to_float32( uint64_t v STATUS_PARAM) +float32 uint64_to_float32( uint_fast64_t v STATUS_PARAM) { return (float32)v; } -float64 int64_to_float64( int64_t v STATUS_PARAM) +float64 int64_to_float64( int_fast64_t v STATUS_PARAM) { return (float64)v; } -float64 uint64_to_float64( uint64_t v STATUS_PARAM) +float64 uint64_to_float64( uint_fast64_t v STATUS_PARAM) { return (float64)v; } #ifdef FLOATX80 -floatx80 int64_to_floatx80( int64_t v STATUS_PARAM) +floatx80 int64_to_floatx80( int_fast64_t v STATUS_PARAM) { return (floatx80)v; } @@ -152,12 +152,12 @@ int_fast32_t float32_to_int32_round_to_zero( float3= 2 a STATUS_PARAM) { return (int32_t)a; } -int64_t float32_to_int64( float32 a STATUS_PARAM) +int_fast64_t float32_to_int64( float32 a STATUS_PARAM) { return llrintf(a); } =20 -int64_t float32_to_int64_round_to_zero( float32 a STATUS_PARAM) +int_fast64_t float32_to_int64_round_to_zero( float32 a STATUS_PARAM) { return (int64_t)a; } @@ -274,11 +274,11 @@ int_fast32_t float64_to_int32_round_to_zero( float6= 4 a STATUS_PARAM) { return (int32_t)a; } -int64_t float64_to_int64( float64 a STATUS_PARAM) +int_fast64_t float64_to_int64( float64 a STATUS_PARAM) { return llrint(a); } -int64_t float64_to_int64_round_to_zero( float64 a STATUS_PARAM) +int_fast64_t float64_to_int64_round_to_zero( float64 a STATUS_PARAM) { return (int64_t)a; } @@ -329,7 +329,7 @@ uint_fast32_t float64_to_uint32_round_to_zero( float6= 4 a STATUS_PARAM) } return res; } -uint64_t float64_to_uint64 (float64 a STATUS_PARAM) +uint_fast64_t float64_to_uint64 (float64 a STATUS_PARAM) { int64_t v; =20 @@ -337,7 +337,7 @@ uint64_t float64_to_uint64 (float64 a STATUS_PARAM) =20 return v - INT64_MIN; } -uint64_t float64_to_uint64_round_to_zero (float64 a STATUS_PARAM) +uint_fast64_t float64_to_uint64_round_to_zero (float64 a STATUS_PARAM) { int64_t v; =20 @@ -435,11 +435,11 @@ int_fast32_t floatx80_to_int32_round_to_zero( float= x80 a STATUS_PARAM) { return (int)a; } -int64_t floatx80_to_int64( floatx80 a STATUS_PARAM) +int_fast64_t floatx80_to_int64( floatx80 a STATUS_PARAM) { return llrintl(a); } -int64_t floatx80_to_int64_round_to_zero( floatx80 a STATUS_PARAM) +int_fast64_t floatx80_to_int64_round_to_zero( floatx80 a STATUS_PARAM) { return (int64_t)a; } diff --git a/fpu/softfloat-native.h b/fpu/softfloat-native.h index 6cf5dc3..b198f48 100644 --- a/fpu/softfloat-native.h +++ b/fpu/softfloat-native.h @@ -160,15 +160,15 @@ floatx80 int32_to_floatx80( int_fast32_t STATUS_PAR= AM); #ifdef FLOAT128 float128 int32_to_float128( int_fast32_t STATUS_PARAM); #endif -float32 int64_to_float32( int64_t STATUS_PARAM); -float32 uint64_to_float32( uint64_t STATUS_PARAM); -float64 int64_to_float64( int64_t STATUS_PARAM); -float64 uint64_to_float64( uint64_t v STATUS_PARAM); +float32 int64_to_float32( int_fast64_t STATUS_PARAM); +float32 uint64_to_float32( uint_fast64_t STATUS_PARAM); +float64 int64_to_float64( int_fast64_t STATUS_PARAM); +float64 uint64_to_float64( uint_fast64_t v STATUS_PARAM); #ifdef FLOATX80 -floatx80 int64_to_floatx80( int64_t STATUS_PARAM); +floatx80 int64_to_floatx80( int_fast64_t STATUS_PARAM); #endif #ifdef FLOAT128 -float128 int64_to_float128( int64_t STATUS_PARAM); +float128 int64_to_float128( int_fast64_t STATUS_PARAM); #endif =20 /*----------------------------------------------------------------------= ------ @@ -178,8 +178,8 @@ int_fast32_t float32_to_int32( float32 STATUS_PARAM)= ; int_fast32_t float32_to_int32_round_to_zero( float32 STATUS_PARAM); uint_fast32_t float32_to_uint32( float32 a STATUS_PARAM); uint_fast32_t float32_to_uint32_round_to_zero( float32 a STATUS_PARAM); -int64_t float32_to_int64( float32 STATUS_PARAM); -int64_t float32_to_int64_round_to_zero( float32 STATUS_PARAM); +int_fast64_t float32_to_int64( float32 STATUS_PARAM); +int_fast64_t float32_to_int64_round_to_zero( float32 STATUS_PARAM); float64 float32_to_float64( float32 STATUS_PARAM); #ifdef FLOATX80 floatx80 float32_to_floatx80( float32 STATUS_PARAM); @@ -283,10 +283,10 @@ int_fast32_t float64_to_int32( float64 STATUS_PARAM= ); int_fast32_t float64_to_int32_round_to_zero( float64 STATUS_PARAM ); uint_fast32_t float64_to_uint32( float64 STATUS_PARAM ); uint_fast32_t float64_to_uint32_round_to_zero( float64 STATUS_PARAM ); -int64_t float64_to_int64( float64 STATUS_PARAM ); -int64_t float64_to_int64_round_to_zero( float64 STATUS_PARAM ); -uint64_t float64_to_uint64( float64 STATUS_PARAM ); -uint64_t float64_to_uint64_round_to_zero( float64 STATUS_PARAM ); +int_fast64_t float64_to_int64( float64 STATUS_PARAM ); +int_fast64_t float64_to_int64_round_to_zero( float64 STATUS_PARAM ); +uint_fast64_t float64_to_uint64( float64 STATUS_PARAM ); +uint_fast64_t float64_to_uint64_round_to_zero( float64 STATUS_PARAM ); float32 float64_to_float32( float64 STATUS_PARAM ); #ifdef FLOATX80 floatx80 float64_to_floatx80( float64 STATUS_PARAM ); @@ -392,8 +392,8 @@ INLINE float64 float64_scalbn(float64 a, int n) *-----------------------------------------------------------------------= -----*/ int_fast32_t floatx80_to_int32( floatx80 STATUS_PARAM ); int_fast32_t floatx80_to_int32_round_to_zero( floatx80 STATUS_PARAM ); -int64_t floatx80_to_int64( floatx80 STATUS_PARAM); -int64_t floatx80_to_int64_round_to_zero( floatx80 STATUS_PARAM); +int64_fast_t floatx80_to_int64( floatx80 STATUS_PARAM); +int64_fast_t floatx80_to_int64_round_to_zero( floatx80 STATUS_PARAM); float32 floatx80_to_float32( floatx80 STATUS_PARAM ); float64 floatx80_to_float64( floatx80 STATUS_PARAM ); #ifdef FLOAT128 diff --git a/fpu/softfloat.c b/fpu/softfloat.c index 6b2cbd7..1a1281d 100644 --- a/fpu/softfloat.c +++ b/fpu/softfloat.c @@ -5938,7 +5938,7 @@ uint_fast16_t float64_to_uint16_round_to_zero( floa= t64 a STATUS_PARAM ) } =20 /* FIXME: This looks broken. */ -uint64_t float64_to_uint64 (float64 a STATUS_PARAM) +uint_fast64_t float64_to_uint64 (float64 a STATUS_PARAM) { int64_t v; =20 @@ -5949,7 +5949,7 @@ uint64_t float64_to_uint64 (float64 a STATUS_PARAM) return v - INT64_MIN; } =20 -uint64_t float64_to_uint64_round_to_zero (float64 a STATUS_PARAM) +uint_fast64_t float64_to_uint64_round_to_zero (float64 a STATUS_PARAM) { int64_t v; =20 --=20 1.7.3.4