mirror of
https://sourceware.org/git/glibc.git
synced 2025-12-24 17:51:17 +03:00
Add exp10 macro to <tgmath.h> (bug 26108)
glibc has had exp10 functions since long before they were standardized; now they are standardized in TS 18661-4 and C2X, they are also specified there to have a corresponding type-generic macro. Add one to <tgmath.h>, so fixing bug 26108. glibc doesn't have other functions from TS 18661-4 yet, but when added, it will be natural to add the type-generic macro for each function family at the same time as the functions. Tested for x86_64.
This commit is contained in:
@@ -48,7 +48,7 @@ volatile int count_cdouble;
|
||||
volatile int count_cfloat;
|
||||
volatile int count_cldouble;
|
||||
|
||||
#define NCALLS 156
|
||||
#define NCALLS 158
|
||||
#define NCALLS_INT 4
|
||||
#define NCCALLS 47
|
||||
|
||||
@@ -253,6 +253,7 @@ F(compile_test) (void)
|
||||
a = log1p (log1p (x));
|
||||
b = logb (logb (a));
|
||||
a = exp2 (exp2 (x));
|
||||
a = exp10 (exp10 (x));
|
||||
b = log2 (log2 (a));
|
||||
a = pow (pow (x, a), pow (c, b));
|
||||
b = sqrt (sqrt (a));
|
||||
@@ -365,6 +366,7 @@ F(compile_test) (void)
|
||||
a = log1p (y);
|
||||
a = logb (y);
|
||||
a = exp2 (y);
|
||||
a = exp10 (y);
|
||||
a = log2 (y);
|
||||
a = pow (y, y);
|
||||
a = sqrt (y);
|
||||
@@ -615,6 +617,14 @@ TYPE
|
||||
return x;
|
||||
}
|
||||
|
||||
TYPE
|
||||
(F(exp10)) (TYPE x)
|
||||
{
|
||||
++count;
|
||||
P ();
|
||||
return x;
|
||||
}
|
||||
|
||||
TYPE
|
||||
(F(exp2)) (TYPE x)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user