Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[gfx1030][ROCM 5.2.3][rocm-arch]MIOpen(HIP): Error [Do] 'amd_comgr_do_action(kind, handle, in.GetHandle(), out.GetHandle())' AMD_COMGR_ACTION_COMPILE_SOURCE_TO_BC: ERROR (1) #1764

Closed
grinness opened this issue Sep 17, 2022 · 22 comments

Comments

@grinness
Copy link

grinness commented Sep 17, 2022

Hi,

I am using the rocm-arch repos to build:

  • rocm 5.2.x -- latest available sources from the repos
  • python-pytorch-rocm and python-torchvision-rocm
  • all compiled setting the target gfx1030 for both PYTHON and AMDGPU (I have rx6800)

Testing few ML algorithms from the torchvision packages on the MINST dataset: standard feed-forward neural nets work fine, but convolutional neural networks do not (naive_conv.cpp) -- the same code used to work fine on a rx480 with rocm 4.x

I can provide the python code if required for both feed-forward nn and convolution nn.
I have reported the issue to the rocm-arch git page too, but I have not received much attention:

The full error log:

Error Log
`(HIP): Error [Do] 'amd_comgr_do_action(kind, handle, in.GetHandle(), out.GetHandle())' AMD_COMGR_ACTION_COMPILE_SOURCE_TO_BC: ERROR (1)
MIOpen(HIP): Error [BuildHip] comgr status = ERROR (1)
MIOpen(HIP): Warning [BuildHip] In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1:
In file included from /tmp/hip_pch.115095/hip_pch.h:1:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:54:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/thread:44:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/this_thread_sleep.h:36:
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:650:36: error: no matching conversion for functional-style cast from 'const duration<long, std::ratio<1, 1>>' to '__cd' (aka 'duration<long, ratio<num, den>>')
return __cd(__cd(__lhs).count() - __cd(__rhs).count());
                                 ^~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:1020:47: note: in instantiation of function template specialization 'std::chrono::operator-<long, std::ratio<1, 1000000000>, long, std::ratio<1, 1>>' requested here
return __time_point(__lhs.time_since_epoch() -__rhs);
                                            ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:1371:47: note: in instantiation of function template specialization 'std::chrono::operator-<std::filesystem::__file_clock, std::chrono::duration<long, std::ratio<1, 1000000000>>, long, std::ratio<1, 1>>' requested here
 return __file_time{__t.time_since_epoch()} - _S_epoch_diff;
                                            ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:1338:16: note: in instantiation of function template specialization 'std::filesystem::__file_clock::_S_from_sys<std::chrono::duration<long, std::ratio<1, 1000000000>>>' requested here
    { return _S_from_sys(chrono::system_clock::now()); }
             ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:498:2: note: candidate constructor not viable: no known conversion from 'const duration<[...], ratio<[...], 1>>' to 'const duration<[...], ratio<[...], 1000000000>>' for 1st argument
duration(const duration&) = default;
^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:505:23: note: candidate template ignored: requirement '__and_<std::is_convertible<const std::chrono::duration<long, std::ratio<1, 1>> &, long>, std::__or_<std::chrono::treat_as_floating_point<long>, std::__not_<std::chrono::treat_as_floating_point<std::chrono::duration<long, std::ratio<1, 1>>>>>>::value' was not satisfied [with _Rep2 = std::chrono::duration<long>]
 constexpr explicit duration(const _Rep2& __rep)
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:513:14: note: candidate template ignored: substitution failure [with _Rep2 = long, _Period2 = std::ratio<1, 1>]: non-type template argument is not a constant expression
 constexpr duration(const duration<_Rep2, _Period2>& __d)
           ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:496:12: note: candidate constructor not viable: requires 0 arguments, but 1 was provided
constexpr duration() = default;
         ^
In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1:
In file included from /tmp/hip_pch.115095/hip_pch.h:1:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434:
In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:53:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3960:
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3972:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, int, char, int>' requested here
{ return __gnu_cxx::__stoa<long, int>(&std::strtol, "stoi", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3977:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, long, char, int>' requested here
{ return __gnu_cxx::__stoa(&std::strtol, "stol", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3982:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long, unsigned long, char, int>' requested here
{ return __gnu_cxx::__stoa(&std::strtoul, "stoul", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3987:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long long, long long, char, int>' requested here
{ return __gnu_cxx::__stoa(&std::strtoll, "stoll", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3992:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long long, unsigned long long, char, int>' requested here
{ return __gnu_cxx::__stoa(&std::strtoull, "stoull", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3998:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<float, float, char>' requested here
{ return __gnu_cxx::__stoa(&std::strtof, "stof", __str.c_str(), __idx); }
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4002:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<double, double, char>' requested here
{ return __gnu_cxx::__stoa(&std::strtod, "stod", __str.c_str(), __idx); }
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4006:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long double, long double, char>' requested here
{ return __gnu_cxx::__stoa(&std::strtold, "stold", __str.c_str(), __idx); }
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1:
In file included from /tmp/hip_pch.115095/hip_pch.h:1:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434:
In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:41:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/allocator.h:46:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/x86_64-pc-linux-gnu/bits/c++allocator.h:33:
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/new_allocator.h:153:6: error: call to '__builtin_operator_delete' selects non-usual deallocation function
   __builtin_operator_delete((__p),
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/alloc_traits.h:496:13: note: in instantiation of member function 'std::__new_allocator<char>::deallocate' requested here
    { __a.deallocate(__p, __n); }
          ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:292:24: note: in instantiation of member function 'std::allocator_traits<std::allocator<char>>::deallocate' requested here
    { _Alloc_traits::deallocate(_M_get_allocator(), _M_data(), __size + 1); }
                     ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:286:4: note: in instantiation of member function 'std::basic_string<char>::_M_destroy' requested here
 _M_destroy(_M_allocated_capacity);
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:795:9: note: in instantiation of member function 'std::basic_string<char>::_M_dispose' requested here
    { _M_dispose(); }
      ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4020:12: note: in instantiation of member function 'std::basic_string<char>::~basic_string' requested here
  string __str(__neg + __len, '-');
         ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/new:153:6: note: non-usual 'operator delete' declared here
void operator delete(void*, std::align_val_t)
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1:
In file included from /tmp/hip_pch.115095/hip_pch.h:1:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434:
In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:53:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3960:
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4115:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, int, wchar_t, int>' requested here
{ return __gnu_cxx::__stoa<long, int>(&std::wcstol, "stoi", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4120:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, long, wchar_t, int>' requested here
{ return __gnu_cxx::__stoa(&std::wcstol, "stol", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4125:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long, unsigned long, wchar_t, int>' requested here
{ return __gnu_cxx::__stoa(&std::wcstoul, "stoul", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4130:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long long, long long, wchar_t, int>' requested here
{ return __gnu_cxx::__stoa(&std::wcstoll, "stoll", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4135:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long long, unsigned long long, wchar_t, int>' requested here
{ return __gnu_cxx::__stoa(&std::wcstoull, "stoull", __str.c_str(),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4141:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<float, float, wchar_t>' requested here
{ return __gnu_cxx::__stoa(&std::wcstof, "stof", __str.c_str(), __idx); }
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4145:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<double, double, wchar_t>' requested here
{ return __gnu_cxx::__stoa(&std::wcstod, "stod", __str.c_str(), __idx); }
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
 || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
    ^~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4149:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long double, long double, wchar_t>' requested here
{ return __gnu_cxx::__stoa(&std::wcstold, "stold", __str.c_str(), __idx); }
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
 _S_chk(_TRet, std::false_type) { return false; }
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
 _S_chk(_TRet __val, std::true_type)
 ^
In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1:
In file included from /tmp/hip_pch.115095/hip_pch.h:1:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62:
In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434:
In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:41:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/allocator.h:46:
In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/x86_64-pc-linux-gnu/bits/c++allocator.h:33:
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/new_allocator.h:153:6: error: call to '__builtin_operator_delete' selects non-usual deallocation function
   __builtin_operator_delete((__p),
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/alloc_traits.h:496:13: note: in instantiation of member function 'std::__new_allocator<wchar_t>::deallocate' requested here
    { __a.deallocate(__p, __n); }
          ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:292:24: note: in instantiation of member function 'std::allocator_traits<std::allocator<wchar_t>>::deallocate' requested here
    { _Alloc_traits::deallocate(_M_get_allocator(), _M_data(), __size + 1); }
                     ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:286:4: note: in instantiation of member function 'std::basic_string<wchar_t>::_M_destroy' requested here
 _M_destroy(_M_allocated_capacity);
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.tcc:238:44: note: in instantiation of member function 'std::basic_string<wchar_t>::_M_dispose' requested here
 ~_Guard() { if (_M_guarded) _M_guarded->_M_dispose(); }
                                         ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.tcc:232:9: note: in instantiation of member function 'std::basic_string<wchar_t>::_M_construct(wchar_t *, wchar_t *, std::forward_iterator_tag)::_Guard::~_Guard' requested here
struct _Guard
      ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:756:4: note: in instantiation of function template specialization 'std::basic_string<wchar_t>::_M_construct<wchar_t *>' requested here
 _M_construct(__beg, __end, std::__iterator_category(__beg));
 ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:115:14: note: in instantiation of function template specialization 'std::basic_string<wchar_t>::basic_string<wchar_t *, void>' requested here
    return _String(__s, __s + __len);
           ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4155:23: note: in instantiation of function template specialization '__gnu_cxx::__to_xstring<std::basic_string<wchar_t>, wchar_t>' requested here
{ return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, 4 * sizeof(int),
                    ^
/usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/new:153:6: note: non-usual 'operator delete' declared here
void operator delete(void*, std::align_val_t)
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated when compiling for gfx1030.

terminate called after throwing an instance of 'miopen::Exception'
what():  /home/marco/.cache/yay/miopen-hip/src/MIOpen-rocm-5.2.3/src/hipoc/hipoc_program.cpp:300: Code object build failed. Source: naive_conv.cpp
@grinness grinness changed the title [gdx1030][ROCM 5.2.3][rocm-arch]MIOpen(HIP): Error [Do] 'amd_comgr_do_action(kind, handle, in.GetHandle(), out.GetHandle())' AMD_COMGR_ACTION_COMPILE_SOURCE_TO_BC: ERROR (1) [gfx1030][ROCM 5.2.3][rocm-arch]MIOpen(HIP): Error [Do] 'amd_comgr_do_action(kind, handle, in.GetHandle(), out.GetHandle())' AMD_COMGR_ACTION_COMPILE_SOURCE_TO_BC: ERROR (1) Sep 17, 2022
@grinness
Copy link
Author

The link to the rocm-arch git issue:

rocm-arch/rocm-arch#857

@mdrokz
Copy link

mdrokz commented Sep 25, 2022

Hi,

I am using the rocm-arch repos to build:

  • rocm 5.2.x -- latest available sources from the repos
  • python-pytorch-rocm and python-torchvision-rocm
  • all compiled setting the target gfx1030 for both PYTHON and AMDGPU (I have rx6800)

Testing few ML algorithms from the torchvision packages on the MINST dataset: standard feed-forward neural nets work fine, but convolutional neural networks do not (naive_conv.cpp) -- the same code used to work fine on a rx480 with rocm 4.x

I can provide the python code if required for both feed-forward nn and convolution nn. I have reported the issue to the rocm-arch git page too, but I have not received much attention:

The full error log:

> `(HIP): Error [Do] 'amd_comgr_do_action(kind, handle, in.GetHandle(), out.GetHandle())' AMD_COMGR_ACTION_COMPILE_SOURCE_TO_BC: ERROR (1) MIOpen(HIP): Error [BuildHip] comgr status = ERROR (1) MIOpen(HIP): Warning [BuildHip] In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1: In file included from /tmp/hip_pch.115095/hip_pch.h:1: In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:54: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/thread:44: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/this_thread_sleep.h:36: /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:650:36: error: no matching conversion for functional-style cast from 'const duration<long, std::ratio<1, 1>>' to '__cd' (aka 'duration<long, ratio<num, den>>') return __cd(__cd(__lhs).count() - __cd(__rhs).count()); ^~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:1020:47: note: in instantiation of function template specialization 'std::chrono::operator-<long, std::ratio<1, 1000000000>, long, std::ratio<1, 1>>' requested here return __time_point(__lhs.time_since_epoch() -__rhs); ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:1371:47: note: in instantiation of function template specialization 'std::chrono::operator-<std::filesystem::__file_clock, std::chrono::duration<long, std::ratio<1, 1000000000>>, long, std::ratio<1, 1>>' requested here return __file_time{__t.time_since_epoch()} - _S_epoch_diff; ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:1338:16: note: in instantiation of function template specialization 'std::filesystem::__file_clock::_S_from_sys<std::chrono::duration<long, std::ratio<1, 1000000000>>>' requested here { return _S_from_sys(chrono::system_clock::now()); } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:498:2: note: candidate constructor not viable: no known conversion from 'const duration<[...], ratio<[...], 1>>' to 'const duration<[...], ratio<[...], 1000000000>>' for 1st argument duration(const duration&) = default; ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:505:23: note: candidate template ignored: requirement '__and_<std::is_convertible<const std::chrono::duration<long, std::ratio<1, 1>> &, long>, std::__or_<std::chrono::treat_as_floating_point, std::__not_<std::chrono::treat_as_floating_point<std::chrono::duration<long, std::ratio<1, 1>>>>>>::value' was not satisfied [with _Rep2 = std::chrono::duration] constexpr explicit duration(const _Rep2& __rep) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:513:14: note: candidate template ignored: substitution failure [with _Rep2 = long, _Period2 = std::ratio<1, 1>]: non-type template argument is not a constant expression constexpr duration(const duration<_Rep2, _Period2>& __d) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/chrono.h:496:12: note: candidate constructor not viable: requires 0 arguments, but 1 was provided constexpr duration() = default; ^ In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1: In file included from /tmp/hip_pch.115095/hip_pch.h:1: In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62: In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434: In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:53: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3960: /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3972:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, int, char, int>' requested here { return __gnu_cxx::__stoa<long, int>(&std::strtol, "stoi", __str.c_str(), ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3977:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, long, char, int>' requested here { return __gnu_cxx::__stoa(&std::strtol, "stol", __str.c_str(), ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3982:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long, unsigned long, char, int>' requested here { return __gnu_cxx::__stoa(&std::strtoul, "stoul", __str.c_str(), ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3987:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long long, long long, char, int>' requested here { return __gnu_cxx::__stoa(&std::strtoll, "stoll", __str.c_str(), ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3992:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long long, unsigned long long, char, int>' requested here { return __gnu_cxx::__stoa(&std::strtoull, "stoull", __str.c_str(), ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3998:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<float, float, char>' requested here { return __gnu_cxx::__stoa(&std::strtof, "stof", __str.c_str(), __idx); } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4002:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<double, double, char>' requested here { return __gnu_cxx::__stoa(&std::strtod, "stod", __str.c_str(), __idx); } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk' || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{})) ^~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4006:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long double, long double, char>' requested here { return __gnu_cxx::__stoa(&std::strtold, "stold", __str.c_str(), __idx); } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument _S_chk(_TRet, std::false_type) { return false; } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument _S_chk(_TRet __val, std::true_type) ^ In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1: In file included from /tmp/hip_pch.115095/hip_pch.h:1: In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62: In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434: In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:41: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/allocator.h:46: In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/x86_64-pc-linux-gnu/bits/c++allocator.h:33: /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/new_allocator.h:153:6: error: call to '__builtin_operator_delete' selects non-usual deallocation function __builtin_operator_delete((__p), ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/alloc_traits.h:496:13: note: in instantiation of member function 'std::__new_allocator::deallocate' requested here { __a.deallocate(__p, __n); } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:292:24: note: in instantiation of member function 'std::allocator_traits<std::allocator>::deallocate' requested here { _Alloc_traits::deallocate(_M_get_allocator(), _M_data(), __size + 1); } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:286:4: note: in instantiation of member function 'std::basic_string::_M_destroy' requested here _M_destroy(_M_allocated_capacity); ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:795:9: note: in instantiation of member function 'std::basic_string::_M_dispose' requested here { _M_dispose(); } ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4020:12: note: in instantiation of member function 'std::basic_string::~basic_string' requested here string __str(__neg + __len, '-'); ^ /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/new:153:6: note: non-usual 'operator delete' declared here void operator delete(void*, std::align_val_t)
> 
> ```
> In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1:
> In file included from /tmp/hip_pch.115095/hip_pch.h:1:
> In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62:
> In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434:
> In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35:
> In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39:
> In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:53:
> In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:3960:
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4115:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, int, wchar_t, int>' requested here
> { return __gnu_cxx::__stoa<long, int>(&std::wcstol, "stoi", __str.c_str(),
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<int, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4120:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long, long, wchar_t, int>' requested here
> { return __gnu_cxx::__stoa(&std::wcstol, "stol", __str.c_str(),
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4125:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long, unsigned long, wchar_t, int>' requested here
> { return __gnu_cxx::__stoa(&std::wcstoul, "stoul", __str.c_str(),
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4130:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long long, long long, wchar_t, int>' requested here
> { return __gnu_cxx::__stoa(&std::wcstoll, "stoll", __str.c_str(),
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4135:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<unsigned long long, unsigned long long, wchar_t, int>' requested here
> { return __gnu_cxx::__stoa(&std::wcstoull, "stoull", __str.c_str(),
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<unsigned long long, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4141:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<float, float, wchar_t>' requested here
> { return __gnu_cxx::__stoa(&std::wcstof, "stof", __str.c_str(), __idx); }
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<float, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4145:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<double, double, wchar_t>' requested here
> { return __gnu_cxx::__stoa(&std::wcstod, "stod", __str.c_str(), __idx); }
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:85:7: error: no matching function for call to '_S_chk'
>  || _Range_chk::_S_chk(__tmp, std::is_same<_Ret, int>{}))
>     ^~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4149:23: note: in instantiation of function template specialization '__gnu_cxx::__stoa<long double, long double, wchar_t>' requested here
> { return __gnu_cxx::__stoa(&std::wcstold, "stold", __str.c_str(), __idx); }
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:70:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::false_type' (aka 'integral_constant<bool, false>') for 2nd argument
>  _S_chk(_TRet, std::false_type) { return false; }
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:73:4: note: candidate function not viable: no known conversion from 'std::is_same<long double, int>' to 'std::true_type' (aka 'integral_constant<bool, true>') for 2nd argument
>  _S_chk(_TRet __val, std::true_type)
>  ^
> In file included from /tmp/comgr-a8ec8e/input/naive_conv.cpp:1:
> In file included from /tmp/hip_pch.115095/hip_pch.h:1:
> In file included from /home/marco/.cache/yay/hip-runtime-amd/src/HIP-rocm-5.2.3/include/hip/hip_runtime.h:62:
> In file included from /home/marco/.cache/yay/hip-runtime-amd/src/hipamd-rocm-5.2.3/include/hip/amd_detail/amd_hip_runtime.h:434:
> In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35:
> In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/stdexcept:39:
> In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/string:41:
> In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/allocator.h:46:
> In file included from /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/x86_64-pc-linux-gnu/bits/c++allocator.h:33:
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/new_allocator.h:153:6: error: call to '__builtin_operator_delete' selects non-usual deallocation function
>    __builtin_operator_delete((__p),
>    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/alloc_traits.h:496:13: note: in instantiation of member function 'std::__new_allocator<wchar_t>::deallocate' requested here
>     { __a.deallocate(__p, __n); }
>           ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:292:24: note: in instantiation of member function 'std::allocator_traits<std::allocator<wchar_t>>::deallocate' requested here
>     { _Alloc_traits::deallocate(_M_get_allocator(), _M_data(), __size + 1); }
>                      ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:286:4: note: in instantiation of member function 'std::basic_string<wchar_t>::_M_destroy' requested here
>  _M_destroy(_M_allocated_capacity);
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.tcc:238:44: note: in instantiation of member function 'std::basic_string<wchar_t>::_M_dispose' requested here
>  ~_Guard() { if (_M_guarded) _M_guarded->_M_dispose(); }
>                                          ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.tcc:232:9: note: in instantiation of member function 'std::basic_string<wchar_t>::_M_construct(wchar_t *, wchar_t *, std::forward_iterator_tag)::_Guard::~_Guard' requested here
> struct _Guard
>       ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:756:4: note: in instantiation of function template specialization 'std::basic_string<wchar_t>::_M_construct<wchar_t *>' requested here
>  _M_construct(__beg, __end, std::__iterator_category(__beg));
>  ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/ext/string_conversions.h:115:14: note: in instantiation of function template specialization 'std::basic_string<wchar_t>::basic_string<wchar_t *, void>' requested here
>     return _String(__s, __s + __len);
>            ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/bits/basic_string.h:4155:23: note: in instantiation of function template specialization '__gnu_cxx::__to_xstring<std::basic_string<wchar_t>, wchar_t>' requested here
> { return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, 4 * sizeof(int),
>                     ^
> /usr/lib64/cmake/llvm/../../../bin/../lib64/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../include/c++/12.2.0/new:153:6: note: non-usual 'operator delete' declared here
> void operator delete(void*, std::align_val_t)
> ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> fatal error: too many errors emitted, stopping now [-ferror-limit=]
> 20 errors generated when compiling for gfx1030.
> 
> terminate called after throwing an instance of 'miopen::Exception'
> what():  /home/marco/.cache/yay/miopen-hip/src/MIOpen-rocm-5.2.3/src/hipoc/hipoc_program.cpp:300: Code object build failed. Source: naive_conv.cpp

i had the same issue on fedora 36 i solved it by installing the miopen-opencl package from official ROCM repos, you get that error when you are missing miopen libraries sudo dnf install miopen-opencl

@grinness
Copy link
Author

@mdrokz

Thanks for the hint (miopen-opencl).
There is currently a package/dependency issue in the rocm-arch repo that prevents testing.

I flagged the issue:
https://github.com/rocm-arch/python-pytorch-rocm/issues/51

@mdrokz
Copy link

mdrokz commented Sep 27, 2022

@mdrokz

Thanks for the hint (miopen-opencl).
There is currently a package/dependency issue in the rocm-arch repo that prevents testing.

I flagged the issue:
https://github.com/rocm-arch/python-pytorch-rocm/issues/51

Ah no problem, i had the same issue on arch but could never figure out what was wrong, when i switched to Fedora i stumbled upon an YouTube video that showed how to install rocm and miopen

@atamazov
Copy link
Contributor

@grinness @mdrokz Huge logs impede reading. Please read this and edit your comments: https://github.com/ROCmSoftwarePlatform/MIOpen/wiki/How-to-insert-console-logs-into-github-pages

@atamazov
Copy link
Contributor

@mdrokz Please avoid quoting huge logs. You can insert a link to the comment that contains log. Thanks.

@atamazov
Copy link
Contributor

@grinness

In file included from /usr/lib/clang/14.0.6/include/cuda_wrappers/complex:35:

Usage of this file looks suspicious. HIP compiler should use header from /opt/rocm/llvm/lib/clang/14.0.0/include/cuda_wrappers. I think this is configuration problem. Please check if you've used CXX=/opt/rocm/llvm/bin/clang++ cmake ... as necessary.

@mdrokz
Copy link

mdrokz commented Sep 27, 2022

@grinness @mdrokz Huge logs impede reading. Please read this and edit your comments: https://github.com/ROCmSoftwarePlatform/MIOpen/wiki/How-to-insert-console-logs-into-github-pages

Sorry I had no idea about this, i will do it

@grinness
Copy link
Author

grinness commented Sep 27, 2022

@atamazov

rocm, pytorch and pytorch vision come from the rocm-arch AUR repos -- and there are possibly 50+ packages

Looking at miopen-hip PKGBUILD, the variable seems to be set correctly:

prepare() {
  cd "$_dirname"

  # -fcf-protection is not supported by HIP, see
  # https://docs.amd.com/bundle/ROCm-Compiler-Reference-Guide-v5.2/page/Appendix_A.html
  # -fPIC fixes linking errors.
  export CC=/opt/rocm/llvm/bin/clang
  export CXX=/opt/rocm/llvm/bin/clang++
  export CXXFLAGS="${CXXFLAGS} -fcf-protection=none -fPIC"

  # We can use the system SQLite and Boost
  msg2 "Building dependencies"
  sed -i 's|^sqlite|#\0|' {,min-}requirements.txt
  sed -i 's|^boost|#\0|' {,min-}requirements.txt
  sed -i 's|^ROCmSoftwarePlatform/llvm-project-mlir|#\0|' {,min-}requirements.txt
  ./install_deps.cmake --minimum --prefix "$srcdir/deps"

  msg2 "Patching files"
  for p in $srcdir/*.patch ; do
    patch -p1 < $p
  done
}

Below link to the git file:
https://github.com/rocm-arch/rocm-arch/blob/master/miopen-hip/PKGBUILD

@grinness
Copy link
Author

@atamazov

with regards to your query on CC and CXX env variables, python-pytorch-rocm PKGBUILD uses gcc, not the rocm clang binaries:

  export CC=/usr/bin/gcc-11
  export CXX=/usr/bin/g++-11
  export CUDAHOSTCXX=/usr/bin/g++-11
  export CUDA_HOST_COMPILER="${CUDAHOSTCXX}"
  export CUDA_HOME=/opt/cuda

I'll try to set the above to cang/clang++ and see if compiles

Thanks,

https://github.com/rocm-arch/python-pytorch-rocm/blob/master/PKGBUILD

@grinness
Copy link
Author

FYI,

python-pytoch-rocm does not compile with rocm clang

@atamazov
Copy link
Contributor

[informative] I run into similar issue with ROCm 5.2.3 when building CK (composable kernels) library. I'll look into it...

@grinness
Copy link
Author

grinness commented Sep 28, 2022

Hi,

to verify if miopen-opencl backend works in place of miopen-hip for pytorch (after going around a number of packaging and dependency issues in rocm-arch AUR), I tried to compile python-pytorch-rocm (AUR) but the build breaks in multiple places ('no matching function' or 'no known conversion') -- not sure where to go from here:

In file included from /opt/hd02/projects/pkgbuild/python-pytorch-rocm.git/src/pytorch-1.12.1-rocm/caffe2/operators/hip/accuracy_op.hip:3:
/opt/hd02/projects/pkgbuild/python-pytorch-rocm.git/src/pytorch-1.12.1-rocm/caffe2/core/hip/context_gpu.h:137:22: error: no matching function for call to 'miopenSetStream'
      MIOPEN_ENFORCE(miopenSetStream(r, hip_stream));
                     ^~~~~~~~~~~~~~~
/opt/hd02/projects/pkgbuild/python-pytorch-rocm.git/src/pytorch-1.12.1-rocm/caffe2/core/hip/common_miopen.h:58:33: note: expanded from macro 'MIOPEN_ENFORCE'
        miopenStatus_t status = condition;                                  \
                                ^~~~~~~~~
/opt/rocm/include/miopen/miopen.h:194:30: note: candidate function not viable: no known conversion from 'c10::hip::HIPStream' to 'miopenAcceleratorQueue_t' (aka '_cl_command_queue *') for 2nd argument
MIOPEN_EXPORT miopenStatus_t miopenSetStream(miopenHandle_t handle,
                             ^
26 warnings and 1 error generated when compiling for gfx1030.
CMake Error at torch_hip_generated_accuracy_op.hip.o.cmake:200 (message):
  Error generating file
  /opt/hd02/projects/pkgbuild/python-pytorch-rocm.git/src/pytorch-1.12.1-rocm/build/caffe2/CMakeFiles/torch_hip.dir/operators/hip/./torch_hip_generated_accuracy_op.hip.o

@atamazov
Copy link
Contributor

atamazov commented Sep 28, 2022

@grinness I am not sure where to go as well. Thanks for opening https://github.com/rocm-arch/python-pytorch-rocm/issues/51.

Please indicate importance/urgency of this issue for you, if you have any workaround or not (e.g. you can use previous rocm) and let's stay in touch.

/cc @junliume

@grinness
Copy link
Author

grinness commented Sep 28, 2022

@atamazov,

in terms of importance: I use pytorch AI algorithms on the rocm platform and synthetic datasets as proof of concepts (POC) for work
in terms of urgency: there is no immediate urgency on my end, but I do have a list of POCs to run (and it would be useful to verify how they work with rocm)

I could use a docker, but most of the pre-compiled rocm distributions do not have gfx 1030 enabled (AFAIK), I could use CPU -- I do not have available another ROCM version to use or AMD gpu to swap to at the moment -- at least on the system I currently use.

If there is some solutions to test, I would be glad to do so.

Thanks

@mdrokz
Copy link

mdrokz commented Sep 30, 2022

@atamazov,

in terms of importance: I use pytorch AI algorithms on the rocm platform and synthetic datasets as proof of concepts (POC) for work in terms of urgency: there is no immediate urgency on my end, but I do have a list of POCs to run (and it would be useful to verify how they work with rocm)

I could use a docker, but most of the pre-compiled rocm distributions do not have gfx 1030 enabled (AFAIK), I could use CPU -- I do not have available another ROCM version to use or AMD gpu to swap to at the moment -- at least on the system I currently use.

If there is some solutions to test, I would be glad to do so.

Thanks

Hi on arch i was using a Dockerfile as well to run ROCM on gfx1030 if you want i can share the Dockerfile with you.

@grinness
Copy link
Author

grinness commented Oct 5, 2022

@mdrokz

Thanks of the offer, I would be happy to try it out.

I also saw that the new ROCM 5.3 is out -- maybe worth testing that out too ?

Thanks

@grinness
Copy link
Author

grinness commented Oct 5, 2022

@mdrokz

I tested using docker image provided in :

https://hub.docker.com/r/rocm/pytorch/#!

the latest version of the docker image supports gfx 1030 (rocm is version 5.2.0)
Convolutional neural-networs and feeed-forward neural network work fine (pytorch/torchvision) -- Note that I use standard Arch Zen Linux kernel with the docker image, not the rocm version and no issues.

It must be something with the rocm-arch packages -- I noticed that pytorch rocm in the arch repos requires hipmagma; when I compiled (on archlinux) pythorch rocm from sources for my old gpu (rx480, rocm 4.x) i did not use that (possibly not related)

Should I close this issue?

Thanks

@atamazov
Copy link
Contributor

atamazov commented Oct 6, 2022

@grinness It seems like you've run into some very specific issue. And most likely this is a configuration problem that can't be fixed in MIOpen. If the problem is now resolved for you then I do not see any reason to keep this ticket open.

@mdrokz Do you agree?

@mdrokz
Copy link

mdrokz commented Oct 7, 2022

@mdrokz

Thanks of the offer, I would be happy to try it out.

I also saw that the new ROCM 5.3 is out -- maybe worth testing that out too ?

Thanks

You can also try this docker file https://gist.github.com/mdrokz/04ff6d96e8b32f6842061306f127530b

@mdrokz
Copy link

mdrokz commented Oct 7, 2022

@grinness It seems like you've run into some very specific issue. And most likely this is a configuration problem that can't be fixed in MIOpen. If the problem is now resolved for you then I do not see any reason to keep this ticket open.

@mdrokz Do you agree?

I agree it's most likely a configuration problem, you can close this issue :)

@grinness
Copy link
Author

grinness commented Oct 8, 2022

Hi all,

thanks for all the info, closing now: issue with rocm-arch repo packages

Best

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
BUG tracker
  
Closed
Development

No branches or pull requests

5 participants