[PATCH] D35034: compiler-rt: use fp_t instead of long double, for consistency
Ed Maste via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 5 14:14:36 PDT 2017
emaste created this revision.
Herald added a subscriber: dberris.
Most builtins accepting or returning long double use the fp_t typedef. Change the remaining few cases to do so.
https://reviews.llvm.org/D35034
Files:
lib/builtins/addtf3.c
lib/builtins/divtf3.c
lib/builtins/extenddftf2.c
lib/builtins/extendsftf2.c
Index: lib/builtins/extendsftf2.c
===================================================================
--- lib/builtins/extendsftf2.c
+++ lib/builtins/extendsftf2.c
@@ -16,7 +16,7 @@
#define DST_QUAD
#include "fp_extend_impl.inc"
-COMPILER_RT_ABI long double __extendsftf2(float a) {
+COMPILER_RT_ABI fp_t __extendsftf2(float a) {
return __extendXfYf2__(a);
}
Index: lib/builtins/extenddftf2.c
===================================================================
--- lib/builtins/extenddftf2.c
+++ lib/builtins/extenddftf2.c
@@ -16,7 +16,7 @@
#define DST_QUAD
#include "fp_extend_impl.inc"
-COMPILER_RT_ABI long double __extenddftf2(double a) {
+COMPILER_RT_ABI fp_t __extenddftf2(double a) {
return __extendXfYf2__(a);
}
Index: lib/builtins/divtf3.c
===================================================================
--- lib/builtins/divtf3.c
+++ lib/builtins/divtf3.c
@@ -195,7 +195,7 @@
// Round
absResult += round;
// Insert the sign and return
- const long double result = fromRep(absResult | quotientSign);
+ const fp_t result = fromRep(absResult | quotientSign);
return result;
}
}
Index: lib/builtins/addtf3.c
===================================================================
--- lib/builtins/addtf3.c
+++ lib/builtins/addtf3.c
@@ -18,7 +18,7 @@
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
#include "fp_add_impl.inc"
-COMPILER_RT_ABI long double __addtf3(long double a, long double b){
+COMPILER_RT_ABI long double __addtf3(fp_t a, fp_t b){
return __addXf3__(a, b);
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D35034.105335.patch
Type: text/x-patch
Size: 1581 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170705/a8e05bdb/attachment.bin>
More information about the llvm-commits
mailing list