File tree Expand file tree Collapse file tree 14 files changed +799
-563
lines changed Expand file tree Collapse file tree 14 files changed +799
-563
lines changed Original file line number Diff line number Diff line change 66//
77//===----------------------------------------------------------------------===//
88
9- _CLC_OVERLOAD _CLC_DECL __CLC_GENTYPE lgamma_r (__CLC_GENTYPE x, global __CLC_INTN *iptr);
10- _CLC_OVERLOAD _CLC_DECL __CLC_GENTYPE lgamma_r (__CLC_GENTYPE x, local __CLC_INTN *iptr);
11- _CLC_OVERLOAD _CLC_DECL __CLC_GENTYPE lgamma_r (__CLC_GENTYPE x, private __CLC_INTN *iptr);
9+ #ifndef __CLC_MATH_CLC_LGAMMA_H__
10+ #define __CLC_MATH_CLC_LGAMMA_H__
11+
12+ #define __CLC_BODY <clc/math/unary_decl.inc>
13+ #define __CLC_FUNCTION __clc_lgamma
14+
15+ #include <clc/math/gentype.inc>
16+
17+ #undef __CLC_BODY
18+ #undef __CLC_FUNCTION
19+
20+ #endif // __CLC_MATH_CLC_LGAMMA_H__
Original file line number Diff line number Diff line change 1+ //===----------------------------------------------------------------------===//
2+ //
3+ // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ // See https://llvm.org/LICENSE.txt for license information.
5+ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ //
7+ //===----------------------------------------------------------------------===//
8+
9+ #ifndef __CLC_MATH_CLC_LGAMMA_R_H__
10+ #define __CLC_MATH_CLC_LGAMMA_R_H__
11+
12+ #define __CLC_FUNCTION __clc_lgamma_r
13+ #define __CLC_BODY <clc/math/unary_decl_with_int_ptr.inc>
14+
15+ #include <clc/math/gentype.inc>
16+
17+ #undef __CLC_BODY
18+ #undef __CLC_FUNCTION
19+
20+ #endif // __CLC_MATH_CLC_LGAMMA_R_H__
Original file line number Diff line number Diff line change 1+ //===----------------------------------------------------------------------===//
2+ //
3+ // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ // See https://llvm.org/LICENSE.txt for license information.
5+ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ //
7+ //===----------------------------------------------------------------------===//
8+
9+ #ifndef __CLC_MATH_CLC_TGAMMA_H__
10+ #define __CLC_MATH_CLC_TGAMMA_H__
11+
12+ #define __CLC_BODY <clc/math/unary_decl.inc>
13+ #define __CLC_FUNCTION __clc_tgamma
14+
15+ #include <clc/math/gentype.inc>
16+
17+ #undef __CLC_BODY
18+ #undef __CLC_FUNCTION
19+
20+ #endif // __CLC_MATH_CLC_TGAMMA_H__
Original file line number Diff line number Diff line change 66//
77// ===----------------------------------------------------------------------===//
88
9- _CLC_OVERLOAD _CLC_DEF __CLC_GENTYPE lgamma_r (__CLC_GENTYPE x, __CLC_ADDRSPACE __CLC_INTN *iptr) {
10- __CLC_INTN private_iptr;
11- __CLC_GENTYPE ret = lgamma_r (x, &private_iptr);
12- *iptr = private_iptr;
13- return ret;
9+ _CLC_OVERLOAD _CLC_DEF __CLC_GENTYPE __CLC_FUNCTION (__CLC_GENTYPE x) {
10+ return __CLC_CONVERT_GENTYPE (__CLC_FUNCTION (__CLC_CONVERT_FLOATN (x)));
1411}
Original file line number Diff line number Diff line change @@ -45,6 +45,8 @@ math/clc_floor.cl
4545math/clc_frexp.cl
4646math/clc_hypot.cl
4747math/clc_ldexp.cl
48+ math/clc_lgamma.cl
49+ math/clc_lgamma_r.cl
4850math/clc_log.cl
4951math/clc_log10.cl
5052math/clc_log1p.cl
@@ -79,6 +81,7 @@ math/clc_sqrt.cl
7981math/clc_sw_fma.cl
8082math/clc_tables.cl
8183math/clc_tanpi.cl
84+ math/clc_tgamma.cl
8285math/clc_trunc.cl
8386relational/clc_all.cl
8487relational/clc_any.cl
Original file line number Diff line number Diff line change 1+ //===----------------------------------------------------------------------===//
2+ //
3+ // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ // See https://llvm.org/LICENSE.txt for license information.
5+ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ //
7+ //===----------------------------------------------------------------------===//
8+
9+ #include <clc/internal/clc.h>
10+ #include <clc/math/clc_lgamma_r.h>
11+
12+ #define __CLC_BODY <clc_lgamma.inc>
13+ #include <clc/math/gentype.inc>
Original file line number Diff line number Diff line change 1+ // ===----------------------------------------------------------------------===//
2+ //
3+ // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ // See https://llvm.org/LICENSE.txt for license information.
5+ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ //
7+ // ===----------------------------------------------------------------------===//
8+
9+ _CLC_OVERLOAD _CLC_DEF __CLC_GENTYPE __clc_lgamma (__CLC_GENTYPE x) {
10+ __CLC_INTN s;
11+ return __clc_lgamma_r (x, &s);
12+ }
You can’t perform that action at this time.
0 commit comments