[libclc] [libclc] Move rsqrt to the CLC library (PR #129045)
Matt Arsenault via cfe-commits
cfe-commits at lists.llvm.org
Thu Feb 27 05:12:34 PST 2025
================
@@ -0,0 +1,4 @@
+__attribute__((weak)) _CLC_OVERLOAD _CLC_DEF __CLC_GENTYPE
+__clc_rsqrt(__CLC_GENTYPE val) {
+ return __CLC_FP_LIT(1.0) / __clc_sqrt(val);
----------------
arsenm wrote:
```suggestion
__clc_rsqrt(__CLC_GENTYPE val) {
#pragma clang fp contract(fast)
return __CLC_FP_LIT(1.0) / __clc_sqrt(val);
```
https://github.com/llvm/llvm-project/pull/129045
More information about the cfe-commits
mailing list