[PATCH] D104904: [OpenMP][AMDGCN] Initial math headers support
Johannes Doerfert via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 30 10:03:24 PDT 2021
jdoerfert added inline comments.
================
Comment at: clang/lib/Headers/__clang_hip_cmath.h:96
+__DEVICE__ __CONSTEXPR__ bool isnan(float __x) { return ::__isnanf(__x); }
+__DEVICE__ __CONSTEXPR__ bool isnan(double __x) { return ::__isnan(__x); }
----------------
pdhaliwal wrote:
> jdoerfert wrote:
> > ^ This is how OpenMP resolves the overload issue wrt. different return types.
> I tried the exact same way. The lit tests compile and run fine. I could not get the runtime tests compile without the errors. It might be that I am not using match patterns correctly. I also tried some other combinations of the match selector but none of them worked.
Not sure what to say. If we want it to work in the wild, I doubt there is much we can do but to make this work. Not sure what your errors were or why they were caused, I'd recommend to determine that instead of punting and hoping nobody will run into this.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D104904/new/
https://reviews.llvm.org/D104904
More information about the cfe-commits
mailing list