[Openmp-dev] Offloading build fails

Jon Chesterfield via Openmp-dev openmp-dev at lists.llvm.org
Mon Nov 4 03:17:30 PST 2019


>
> I am not sure what's going on with the trunk clang at this moment.
>
> $ cat a.cpp
> #include <iostream>
> int main() {
> }
>
> $ clang++ -std=c++11 -fopenmp -nu/7.2.0/../../../../inclu
> de/c++/7.2.0/bits/std_abs.h:70:3:
> error: declaration conflicts with target of using declaration already in
> scope
>   abs(double __x)
>   ^
> /p/scratch/cpcp0/pcp0151/opt/clang/201911040249/lib/clang/10
> .0.0/include/__clang_cuda_math_forward_declares.h:50:25:
> note: target of using declaration
> __DEVICE__ const double abs(const double);


I think this is bug https://bugs.llvm.org/show_bug.cgi?id=42972. The fix
may be adding some #ifdef logic to the cuda header, I've worked around it
locally by reverting D62046
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20191104/a83bf86a/attachment.html>


More information about the Openmp-dev mailing list