[libclc] r211577 - Add MAXFLOAT

Jeroen Ketema j.ketema at imperial.ac.uk
Tue Jun 24 02:41:28 PDT 2014


Author: jketema
Date: Tue Jun 24 04:41:28 2014
New Revision: 211577

URL: http://llvm.org/viewvc/llvm-project?rev=211577&view=rev
Log:
Add MAXFLOAT

Align definitions while we are here.

Reviewed-by: Tom Stellard <tom at stellard.net>

Modified:
    libclc/trunk/generic/include/clc/float/definitions.h

Modified: libclc/trunk/generic/include/clc/float/definitions.h
URL: http://llvm.org/viewvc/llvm-project/libclc/trunk/generic/include/clc/float/definitions.h?rev=211577&r1=211576&r2=211577&view=diff
==============================================================================
--- libclc/trunk/generic/include/clc/float/definitions.h (original)
+++ libclc/trunk/generic/include/clc/float/definitions.h Tue Jun 24 04:41:28 2014
@@ -1,6 +1,7 @@
-#define INFINITY __builtin_inff()
-#define NAN __builtin_nanf("")
-#define HUGE_VALF __builtin_huge_valf()
+#define MAXFLOAT        0x1.fffffep127f
+#define HUGE_VALF       __builtin_huge_valf()
+#define INFINITY        __builtin_inff()
+#define NAN             __builtin_nanf("")
 
 #define FLT_DIG         6
 #define FLT_MANT_DIG    24
@@ -9,7 +10,7 @@
 #define FLT_MIN_10_EXP  -37
 #define FLT_MIN_EXP     -125
 #define FLT_RADIX       2
-#define FLT_MAX         0x1.fffffep127f
+#define FLT_MAX         MAXFLOAT
 #define FLT_MIN         0x1.0p-126f
 #define FLT_EPSILON     0x1.0p-23f
 
@@ -29,7 +30,7 @@
 
 #ifdef cl_khr_fp64
 
-#define HUGE_VAL __builtin_huge_val()
+#define HUGE_VAL        __builtin_huge_val()
 
 #define DBL_DIG         15
 #define DBL_MANT_DIG    53





More information about the cfe-commits mailing list