recommit "[HIP] Add default header and include path"recommit 11d06b9511bd25aabbfad10dff548b0ce29135a5 withfix for lit tests.
Revert "recommit "[HIP] Add default header and include path""This reverts commit 1fa43e0b34d9736f62c6c1b6c371a5e39cd1624d.Still breaks tests on several bots, see https://reviews.llvm.org/D81176
Revert "[HIP] Add default header and include path"This reverts commit 11d06b9511bd25aabbfad10dff548b0ce29135a5.
[HIP] Add default header and include pathTo support std::complex and some other standard C/C++ functions in HIP device code,they need to be forced to be __host__ __device__ functions by pragmas. T
[HIP] Add default header and include pathTo support std::complex and some other standard C/C++ functions in HIP device code,they need to be forced to be __host__ __device__ functions by pragmas. This is doneby some clang standard C++ wrapper headers which are shared between cuda-clang and hip-Clang.For these standard C++ wapper headers to work properly, specific include path orderhas to be enforced: clang C++ wrapper include path standard C++ include path clang include pathAlso, these C++ wrapper headers require device version of some standard C/C++ functionsmust be declared before including them. This needs to be done by including a defaultheader which declares or defines these device functions. The default header is alwaysincluded before any other headers are included by users.This patch adds the the default header and include path for HIP.Differential Revision: https://reviews.llvm.org/D81176
show more ...