Skip to content

Commit 9538849

Browse files
author
JackAKirk
committed
Add comments to explain exp2/tanh impl.
Signed-off-by: JackAKirk <[email protected]>
1 parent e4cbfaf commit 9538849

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

sycl/include/sycl/ext/oneapi/experimental/builtins.hpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,8 @@ int printf(const FormatT *__format, Args... args) {
9393
namespace native {
9494

9595
// genfloatfh tanh (genfloatfh x)
96+
// sycl::native::tanh is only implemented on nvptx backend so far. For other
97+
// backends we revert to the sycl::tanh impl.
9698
template <typename T>
9799
inline __SYCL_ALWAYS_INLINE
98100
sycl::detail::enable_if_t<sycl::detail::is_svgenfloatf<T>::value ||
@@ -140,6 +142,8 @@ tanh(sycl::marray<T, N> x) __NOEXC {
140142
}
141143

142144
// genfloath exp2 (genfloath x)
145+
// sycl::native::exp2 (using half) is only implemented on nvptx backend so far.
146+
// For other backends we revert to the sycl::exp2 impl.
143147
template <typename T>
144148
inline __SYCL_ALWAYS_INLINE
145149
sycl::detail::enable_if_t<sycl::detail::is_svgenfloath<T>::value, T>

0 commit comments

Comments
 (0)