yaxunl added inline comments.
================ Comment at: clang/lib/Headers/__clang_hip_libdevice_declares.h:319 +// relevant. +__device__ inline _Float16 __llvm_amdgcn_rcp_f16(_Float16 x) { + return ((_Float16)1.0f) / x; ---------------- arsenm wrote: > arsenm wrote: > > yaxunl wrote: > > > Can we add the deprecated attribute to urge people not to use them? > > I initially added those, but thought it was a bit aggressive to put in > > always included headers. Is there an established practice for deprecating > > builtin header functions? > Is there a hip header version macro I could guard this on? > I initially added those, but thought it was a bit aggressive to put in always > included headers. Is there an established practice for deprecating builtin > header functions? I saw it used by libstdc++ headers and pthread headers to deprecate APIs. I think it is common practice to use deprecate attibute. We'd also better mention it in clang release note and give a timeline to remove it, e.g. next clang major release. ================ Comment at: clang/lib/Headers/__clang_hip_libdevice_declares.h:319 +// relevant. +__device__ inline _Float16 __llvm_amdgcn_rcp_f16(_Float16 x) { + return ((_Float16)1.0f) / x; ---------------- yaxunl wrote: > arsenm wrote: > > arsenm wrote: > > > yaxunl wrote: > > > > Can we add the deprecated attribute to urge people not to use them? > > > I initially added those, but thought it was a bit aggressive to put in > > > always included headers. Is there an established practice for deprecating > > > builtin header functions? > > Is there a hip header version macro I could guard this on? > > I initially added those, but thought it was a bit aggressive to put in > > always included headers. Is there an established practice for deprecating > > builtin header functions? > > I saw it used by libstdc++ headers and pthread headers to deprecate APIs. > > I think it is common practice to use deprecate attibute. > > We'd also better mention it in clang release note and give a timeline to > remove it, e.g. next clang major release. > Is there a hip header version macro I could guard this on? Yes like https://github.com/llvm/llvm-project/blob/main/clang/lib/Headers/__clang_hip_runtime_wrapper.h#L80 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155982/new/ https://reviews.llvm.org/D155982 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits