Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[libclc] Move rootn to the CLC library; optimize #133735

Merged
merged 1 commit into from
Apr 1, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -6,6 +6,15 @@
//
//===----------------------------------------------------------------------===//

#define __CLC_BODY <math/clc_rootn.inc>
#ifndef __CLC_MATH_CLC_ROOTN_H__
#define __CLC_MATH_CLC_ROOTN_H__

#define __CLC_BODY <clc/math/binary_decl_with_int_second_arg.inc>
#define __CLC_FUNCTION __clc_rootn

#include <clc/math/gentype.inc>

#undef __CLC_BODY
#undef __CLC_FUNCTION

#endif // __CLC_MATH_CLC_ROOTN_H__
1 change: 1 addition & 0 deletions libclc/clc/lib/generic/SOURCES
Original file line number Diff line number Diff line change
@@ -52,6 +52,7 @@ math/clc_powr.cl
math/clc_remainder.cl
math/clc_remquo.cl
math/clc_rint.cl
math/clc_rootn.cl
math/clc_round.cl
math/clc_rsqrt.cl
math/clc_sincos_helpers.cl
21 changes: 21 additions & 0 deletions libclc/clc/lib/generic/math/clc_rootn.cl
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
//===----------------------------------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//

#include <clc/clc_convert.h>
#include <clc/float/definitions.h>
#include <clc/internal/clc.h>
#include <clc/math/clc_fabs.h>
#include <clc/math/clc_fma.h>
#include <clc/math/clc_ldexp.h>
#include <clc/math/clc_mad.h>
#include <clc/math/clc_subnormal_config.h>
#include <clc/math/math.h>
#include <clc/math/tables.h>

#define __CLC_BODY <clc_rootn.inc>
#include <clc/math/gentype.inc>
Loading
Oops, something went wrong.