[flang-commits] [flang] [flang][runtime] Use cuda::std::complex in F18 runtime CUDA build. (PR #109078)

LLVM Continuous Integration via flang-commits flang-commits at lists.llvm.org
Wed Sep 18 11:18:04 PDT 2024


llvm-ci wrote:

LLVM Buildbot has detected a new failure on builder `flang-runtime-cuda-gcc` running on `as-builder-7` while building `flang` at step 5 "build-FortranRuntime".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/152/builds/399

<details>
<summary>Here is the relevant piece of the build log for the reference</summary>

```
Step 5 (build-FortranRuntime) failure: build (failure)
...
10.424 [1/27/38] Building CUDA object CMakeFiles/FortranRuntime.dir/array-constructor.cpp.o
10.548 [1/26/39] Building CUDA object CMakeFiles/FortranRuntime.dir/descriptor-io.cpp.o
10.563 [1/25/40] Building CUDA object CMakeFiles/FortranRuntime.dir/type-info.cpp.o
10.569 [1/24/41] Building CUDA object CMakeFiles/FortranRuntime.dir/inquiry.cpp.o
10.646 [1/23/42] Building CUDA object CMakeFiles/FortranRuntime.dir/pointer.cpp.o
10.973 [1/22/43] Building CUDA object CMakeFiles/FortranRuntime.dir/tools.cpp.o
10.996 [1/21/44] Building CUDA object CMakeFiles/FortranRuntime.dir/derived.cpp.o
11.238 [1/20/45] Building CUDA object CMakeFiles/FortranRuntime.dir/external-unit.cpp.o
11.455 [1/19/46] Building CUDA object CMakeFiles/FortranRuntime.dir/transformational.cpp.o
11.657 [1/18/47] Building CUDA object CMakeFiles/FortranRuntime.dir/product.cpp.o
FAILED: CMakeFiles/FortranRuntime.dir/product.cpp.o 
ccache /usr/local/cuda/bin/nvcc -forward-unknown-to-host-compiler -ccbin=/usr/bin/g++ -DFLANG_LITTLE_ENDIAN=1 -DGTEST_HAS_RTTI=0 -DRT_USE_LIBCUDACXX=1 -D_DEBUG -D_GLIBCXX_ASSERTIONS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/../include -I/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/build -I/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include -G -g -O3 -DNDEBUG --generate-code=arch=compute_80,code=[compute_80,sm_80]   -U_GLIBCXX_ASSERTIONS -U_LIBCPP_ENABLE_ASSERTIONS -std=c++17  -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fno-rtti --expt-relaxed-constexpr -Xcudafe --diag_suppress=20208 -Xcudafe --display_error_number -MD -MT CMakeFiles/FortranRuntime.dir/product.cpp.o -MF CMakeFiles/FortranRuntime.dir/product.cpp.o.d -x cu -dc /home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/product.cpp -o CMakeFiles/FortranRuntime.dir/product.cpp.o
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/limits: In instantiation of ‘class cuda::std::__4::numeric_limits<long double>’:
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:524:60:   required from ‘constexpr cuda::std::__4::complex<_Tp> cuda::std::__4::operator*(const cuda::std::__4::complex<_Tp>&, const cuda::std::__4::complex<_Tp>&) [with _Tp = long double]’
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:433:16:   required from ‘constexpr cuda::std::__4::complex<_Tp>& cuda::std::__4::operator*=(cuda::std::__4::complex<_Tp>&, const cuda::std::__4::complex<_Up>&) [with _Tp = long double; _Up = long double]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/product.cpp:52:1:   required from ‘bool Fortran::runtime::ComplexProductAccumulator<PART>::AccumulateAt(const SubscriptValue*) [with A = cuda::std::__4::complex<long double>; PART = long double; Fortran::runtime::SubscriptValue = long int]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/reduction-templates.h:62:47:   required from ‘void Fortran::runtime::DoTotalReduction(const Fortran::runtime::Descriptor&, int, const Fortran::runtime::Descriptor*, ACCUMULATOR&, const char*, Fortran::runtime::Terminator&) [with TYPE = cuda::std::__4::complex<long double>; ACCUMULATOR = Fortran::runtime::ComplexProductAccumulator<long double>]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/reduction-templates.h:88:44:   required from ‘Fortran::runtime::CppTypeFor<CAT, KIND> Fortran::runtime::GetTotalReduction(const Fortran::runtime::Descriptor&, const char*, int, int, const Fortran::runtime::Descriptor*, ACCUMULATOR&&, const char*) [with Fortran::common::TypeCategory CAT = Fortran::common::TypeCategory::Complex; int KIND = 10; ACCUMULATOR = Fortran::runtime::ComplexProductAccumulator<long double>; Fortran::runtime::CppTypeFor<CAT, KIND> = cuda::std::__4::complex<long double>]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/product.cpp:147:64:   required from here
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/limits:477:77: error: no type named ‘type’ in ‘class cuda::std::__4::__libcpp_numeric_limits<long double, true>’
  477 |     typedef typename __base::type type;
      |                                                                             ^   
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex: In instantiation of ‘constexpr cuda::std::__4::complex<_Tp> cuda::std::__4::operator*(const cuda::std::__4::complex<_Tp>&, const cuda::std::__4::complex<_Tp>&) [with _Tp = long double]’:
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:433:16:   required from ‘constexpr cuda::std::__4::complex<_Tp>& cuda::std::__4::operator*=(cuda::std::__4::complex<_Tp>&, const cuda::std::__4::complex<_Up>&) [with _Tp = long double; _Up = long double]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/product.cpp:52:1:   required from ‘bool Fortran::runtime::ComplexProductAccumulator<PART>::AccumulateAt(const SubscriptValue*) [with A = cuda::std::__4::complex<long double>; PART = long double; Fortran::runtime::SubscriptValue = long int]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/reduction-templates.h:62:47:   required from ‘void Fortran::runtime::DoTotalReduction(const Fortran::runtime::Descriptor&, int, const Fortran::runtime::Descriptor*, ACCUMULATOR&, const char*, Fortran::runtime::Terminator&) [with TYPE = cuda::std::__4::complex<long double>; ACCUMULATOR = Fortran::runtime::ComplexProductAccumulator<long double>]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/reduction-templates.h:88:44:   required from ‘Fortran::runtime::CppTypeFor<CAT, KIND> Fortran::runtime::GetTotalReduction(const Fortran::runtime::Descriptor&, const char*, int, int, const Fortran::runtime::Descriptor*, ACCUMULATOR&&, const char*) [with Fortran::common::TypeCategory CAT = Fortran::common::TypeCategory::Complex; int KIND = 10; ACCUMULATOR = Fortran::runtime::ComplexProductAccumulator<long double>; Fortran::runtime::CppTypeFor<CAT, KIND> = cuda::std::__4::complex<long double>]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/product.cpp:147:64:   required from here
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:524:60: error: ‘quiet_NaN’ is not a member of ‘cuda::std::__4::numeric_limits<long double>’
  524 |       return complex<_Tp>(_Tp(numeric_limits<_Tp>::quiet_NaN()), _Tp(0));
      |                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:530:60: error: ‘quiet_NaN’ is not a member of ‘cuda::std::__4::numeric_limits<long double>’
  530 |         return complex<_Tp>(_Tp(numeric_limits<_Tp>::quiet_NaN()), _Tp(0));
      |                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:532:59: error: ‘infinity’ is not a member of ‘cuda::std::__4::numeric_limits<long double>’
  532 |       return complex<_Tp>(_Tp(numeric_limits<_Tp>::infinity()), _Tp(numeric_limits<_Tp>::infinity()));
      |                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:540:60: error: ‘quiet_NaN’ is not a member of ‘cuda::std::__4::numeric_limits<long double>’
  540 |       return complex<_Tp>(_Tp(numeric_limits<_Tp>::quiet_NaN()), _Tp(0));
      |                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/cmath: In instantiation of ‘constexpr cuda::std::__4::__enable_if_t<(! cuda::std::__4::is_floating_point<_Tp>::value), bool> cuda::std::__4::__constexpr_isinf(_A1) [with _A1 = __float128; cuda::std::__4::__enable_if_t<(! cuda::std::__4::is_floating_point<_Tp>::value), bool> = bool]’:
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:512:38:   required from ‘constexpr cuda::std::__4::complex<_Tp> cuda::std::__4::operator*(const cuda::std::__4::complex<_Tp>&, const cuda::std::__4::complex<_Tp>&) [with _Tp = __float128]’
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/complex:433:16:   required from ‘constexpr cuda::std::__4::complex<_Tp>& cuda::std::__4::operator*=(cuda::std::__4::complex<_Tp>&, const cuda::std::__4::complex<_Up>&) [with _Tp = __float128; _Up = __float128]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/product.cpp:52:1:   required from ‘bool Fortran::runtime::ComplexProductAccumulator<PART>::AccumulateAt(const SubscriptValue*) [with A = cuda::std::__4::complex<__float128>; PART = __float128; Fortran::runtime::SubscriptValue = long int]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/reduction-templates.h:62:47:   required from ‘void Fortran::runtime::DoTotalReduction(const Fortran::runtime::Descriptor&, int, const Fortran::runtime::Descriptor*, ACCUMULATOR&, const char*, Fortran::runtime::Terminator&) [with TYPE = cuda::std::__4::complex<__float128>; ACCUMULATOR = Fortran::runtime::ComplexProductAccumulator<__float128>]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/reduction-templates.h:88:44:   required from ‘Fortran::runtime::CppTypeFor<CAT, KIND> Fortran::runtime::GetTotalReduction(const Fortran::runtime::Descriptor&, const char*, int, int, const Fortran::runtime::Descriptor*, ACCUMULATOR&&, const char*) [with Fortran::common::TypeCategory CAT = Fortran::common::TypeCategory::Complex; int KIND = 16; ACCUMULATOR = Fortran::runtime::ComplexProductAccumulator<__float128>; Fortran::runtime::CppTypeFor<CAT, KIND> = cuda::std::__4::complex<__float128>]’
/home/buildbot/worker/as-builder-7/ramdisk/flang-runtime-cuda-gcc/llvm-project/flang/runtime/product.cpp:156:64:   required from here
/home/buildbot/worker/third-party/nv/cccl/libcudacxx/include/cuda/std/detail/libcxx/include/cmath:666:15: error: call of overloaded ‘isinf(__float128&)’ is ambiguous
  666 |     return ::isinf(__lcpp_x);

```

</details>

https://github.com/llvm/llvm-project/pull/109078


More information about the flang-commits mailing list