From owner-svn-src-projects@FreeBSD.ORG Sun Apr 8 09:38:20 2012 Return-Path: Delivered-To: svn-src-projects@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E4A19106566C; Sun, 8 Apr 2012 09:38:20 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C55448FC12; Sun, 8 Apr 2012 09:38:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q389cK2Y004526; Sun, 8 Apr 2012 09:38:20 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q389cKeM004523; Sun, 8 Apr 2012 09:38:20 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201204080938.q389cKeM004523@svn.freebsd.org> From: Andrew Turner Date: Sun, 8 Apr 2012 09:38:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-projects@freebsd.org X-SVN-Group: projects MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234030 - projects/arm_eabi/lib/libc/arm/aeabi X-BeenThere: svn-src-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the src " projects" tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 08 Apr 2012 09:38:21 -0000 Author: andrew Date: Sun Apr 8 09:38:20 2012 New Revision: 234030 URL: http://svn.freebsd.org/changeset/base/234030 Log: Update the __aeabi_* floating point functions to work Modified: projects/arm_eabi/lib/libc/arm/aeabi/aeabi_double.c projects/arm_eabi/lib/libc/arm/aeabi/aeabi_float.c Modified: projects/arm_eabi/lib/libc/arm/aeabi/aeabi_double.c ============================================================================== --- projects/arm_eabi/lib/libc/arm/aeabi/aeabi_double.c Sun Apr 8 09:33:50 2012 (r234029) +++ projects/arm_eabi/lib/libc/arm/aeabi/aeabi_double.c Sun Apr 8 09:38:20 2012 (r234030) @@ -32,81 +32,70 @@ __FBSDID("$FreeBSD$"); #include "milieu.h" #include "softfloat.h" -float64 __adddf3(float64 a, float64 b); -float64 __divdf3(float64 a, float64 b); -float64 __muldf3(float64 a, float64 b); -float64 __subdf3(float64 a, float64 b); - -float32 __truncdfsf2(float64 a); - -int32 __fixdfsi(float64); -float64 __floatsidf(int32 a); -flag __gedf2(float64, float64); -flag __ledf2(float64, float64); flag __unorddf2(float64, float64); -int __aeabi_dcmpeq(double a, double b) +int __aeabi_dcmpeq(float64 a, float64 b) { - return __ledf2(a, b) == 0; + return float64_eq(a, b); } -int __aeabi_dcmplt(double a, double b) +int __aeabi_dcmplt(float64 a, float64 b) { - return __ledf2(a, b) < 0; + return float64_lt(a, b); } -int __aeabi_dcmple(double a, double b) +int __aeabi_dcmple(float64 a, float64 b) { - return __ledf2(a, b) <= 0; + return float64_le(a, b); } -int __aeabi_dcmpge(double a, double b) +int __aeabi_dcmpge(float64 a, float64 b) { - return __gedf2(a, b) >= 0; + return float64_le(b, a); } -int __aeabi_dcmpgt(double a, double b) +int __aeabi_dcmpgt(float64 a, float64 b) { - return __gedf2(a, b) > 0; + return float64_lt(b, a); } -int __aeabi_dcmpun(double a, double b) +int __aeabi_dcmpun(float64 a, float64 b) { return __unorddf2(a, b); } -int __aeabi_d2iz(double a) +int __aeabi_d2iz(float64 a) { - return __fixdfsi(a); + return float64_to_int32_round_to_zero(a); } -float __aeabi_d2f(double a) +float32 __aeabi_d2f(float64 a) { - return __truncdfsf2(a); + return float64_to_float32(a); } -double __aeabi_i2d(int a) +float64 __aeabi_i2d(int a) { - return __floatsidf(a); + return int32_to_float64(a); } -double __aeabi_dadd(double a, double b) +float64 __aeabi_dadd(float64 a, float64 b) { - return __adddf3(a, b); + return float64_add(a, b); } -double __aeabi_ddiv(double a, double b) +float64 __aeabi_ddiv(float64 a, float64 b) { - return __divdf3(a, b); + return float64_div(a, b); } -double __aeabi_dmul(double a, double b) +float64 __aeabi_dmul(float64 a, float64 b) { - return __muldf3(a, b); + return float64_mul(a, b); } -double __aeabi_dsub(double a, double b) +float64 __aeabi_dsub(float64 a, float64 b) { - return __subdf3(a, b); + return float64_sub(a, b); } Modified: projects/arm_eabi/lib/libc/arm/aeabi/aeabi_float.c ============================================================================== --- projects/arm_eabi/lib/libc/arm/aeabi/aeabi_float.c Sun Apr 8 09:33:50 2012 (r234029) +++ projects/arm_eabi/lib/libc/arm/aeabi/aeabi_float.c Sun Apr 8 09:38:20 2012 (r234030) @@ -32,81 +32,70 @@ __FBSDID("$FreeBSD$"); #include "milieu.h" #include "softfloat.h" -float32 __addsf3(float32 a, float32 b); -float32 __divsf3(float32 a, float32 b); -float32 __mulsf3(float32 a, float32 b); -float32 __subsf3(float32 a, float32 b); - -float64 __extendsfdf2(float32 a); - -int32 __fixsfsi(float32); -float32 __floatsisf(int32 a); -flag __gesf2(float32, float32); -flag __lesf2(float32, float32); flag __unordsf2(float32, float32); -int __aeabi_fcmpeq(float a, float b) +int __aeabi_fcmpeq(float32 a, float32 b) { - return __lesf2(a, b) == 0; + return float32_eq(a, b); } -int __aeabi_fcmplt(float a, float b) +int __aeabi_fcmplt(float32 a, float32 b) { - return __lesf2(a, b) < 0; + return float32_lt(a, b); } -int __aeabi_fcmple(float a, float b) +int __aeabi_fcmple(float32 a, float32 b) { - return __lesf2(a, b) <= 0; + return float32_le(a, b); } -int __aeabi_fcmpge(float a, float b) +int __aeabi_fcmpge(float32 a, float32 b) { - return __gesf2(a, b) >= 0; + return float32_le(b, a); } -int __aeabi_fcmpgt(float a, float b) +int __aeabi_fcmpgt(float32 a, float32 b) { - return __gesf2(a, b) > 0; + return float32_lt(b, a); } -int __aeabi_fcmpun(float a, float b) +int __aeabi_fcmpun(float32 a, float32 b) { return __unordsf2(a, b); } -int __aeabi_f2iz(float a) +int __aeabi_f2iz(float32 a) { - return __fixsfsi(a); + return float32_to_int32_round_to_zero(a); } -double __aeabi_f2d(float a) +float32 __aeabi_f2d(float32 a) { - return __extendsfdf2(a); + return float32_to_float64(a); } -float __aeabi_i2f(int a) +float32 __aeabi_i2f(int a) { - return __floatsisf(a); + return int32_to_float32(a); } -float __aeabi_fadd(float a, float b) +float32 __aeabi_fadd(float32 a, float32 b) { - return __addsf3(a, b); + return float32_add(a, b); } -float __aeabi_fdiv(float a, float b) +float32 __aeabi_fdiv(float32 a, float32 b) { - return __divsf3(a, b); + return float32_div(a, b); } -float __aeabi_fmul(float a, float b) +float32 __aeabi_fmul(float32 a, float32 b) { - return __mulsf3(a, b); + return float32_mul(a, b); } -float __aeabi_fsub(float a, float b) +float32 __aeabi_fsub(float32 a, float32 b) { - return __subsf3(a, b); + return float32_sub(a, b); }