0
0
mirror of https://github.com/llvm/llvm-project.git synced 2025-04-27 11:46:07 +00:00
Fraser Cormack ad48fffb53
[libclc] Move several 'native' builtins to CLC library ()
This commit moves the 'native' builtins that use asm statements to
generate LLVM intrinsics to the CLC library. In doing so it converts
them to use the appropriate elementwise builtin to generate the same
intrinsic; there are no codegen changes to any target except to AMDGPU
targets where `native_log` is no longer custom implemented and instead
used the clang elementwise builtin.

This work forms part of  and indeed with this commit there are no
'generic' builtins using/abusing asm statements - the remaining builtins
are specific to the amdgpu and r600 targets.
2025-04-01 09:20:54 +01:00

23 lines
698 B
C

//===----------------------------------------------------------------------===//
//
// 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
//
//===----------------------------------------------------------------------===//
#ifndef __CLC_MATH_CLC_NATIVE_LOG10_H__
#define __CLC_MATH_CLC_NATIVE_LOG10_H__
#define __FLOAT_ONLY
#define __CLC_FUNCTION __clc_native_log10
#define __CLC_BODY <clc/shared/unary_decl.inc>
#include <clc/math/gentype.inc>
#undef __CLC_BODY
#undef __CLC_FUNCTION
#undef __FLOAT_ONLY
#endif // __CLC_MATH_CLC_NATIVE_LOG10_H__