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

fix a compile error with gcc 11 #1090

Closed
wants to merge 3 commits into from

Conversation

Neutron3529
Copy link

It seems that, gcc11 do not support a != operator for std::thread::id
I tried to fix it by switch the != operator to == and put the ! operator outside the compare op.

I don't know whether the compare op behaves correct, but that's the only way I could bypass that error.

Error:

/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp: In member function 'virtual void dnnl::impl::lru_primitive_cache_t::update_entry(const key_t&, const dnnl::impl::primitive_desc_t*)':
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:60: error: no match for 'operator!=' (operand types are 'const std::thread::id' and 'const std::thread::id')
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                      ~~~~~~~~~~~~~~~~~~~~~ ^~ ~~~~~~~~~~~~~~~
      |                                                         |                  |
      |                                                         |                  const std::thread::id
      |                                                         const std::thread::id
In file included from /usr/include/c++/11.1.0/utility:70,
                 from /usr/include/c++/11.1.0/tuple:38,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_pair.h:496:5: note: candidate: 'template<class _T1, class _T2> constexpr bool std::operator!=(const std::pair<_T1, _T2>&, const std::pair<_T1, _T2>&)'
  496 |     operator!=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_pair.h:496:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::pair<_T1, _T2>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:428:5: note: candidate: 'template<class _Iterator> bool std::operator!=(const std::reverse_iterator<_Iterator>&, const std::reverse_iterator<_Iterator>&)'
  428 |     operator!=(const reverse_iterator<_Iterator>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:428:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::reverse_iterator<_Iterator>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:467:5: note: candidate: 'template<class _IteratorL, class _IteratorR> bool std::operator!=(const std::reverse_iterator<_Iterator>&, const std::reverse_iterator<_IteratorR>&)'
  467 |     operator!=(const reverse_iterator<_IteratorL>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:467:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::reverse_iterator<_Iterator>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:1550:5: note: candidate: 'template<class _IteratorL, class _IteratorR> bool std::operator!=(const std::move_iterator<_IteratorL>&, const std::move_iterator<_IteratorR>&)'
 1550 |     operator!=(const move_iterator<_IteratorL>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:1550:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::move_iterator<_IteratorL>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:1607:5: note: candidate: 'template<class _Iterator> bool std::operator!=(const std::move_iterator<_IteratorL>&, const std::move_iterator<_IteratorL>&)'
 1607 |     operator!=(const move_iterator<_Iterator>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:1607:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::move_iterator<_IteratorL>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/array:305:5: note: candidate: 'template<class _Tp, long unsigned int _Nm> bool std::operator!=(const std::array<_Tp, _Nm>&, const std::array<_Tp, _Nm>&)'
  305 |     operator!=(const array<_Tp, _Nm>& __one, const array<_Tp, _Nm>& __two)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/array:305:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::array<_Tp, _Nm>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/tuple:1531:5: note: candidate: 'template<class ... _TElements, class ... _UElements> constexpr bool std::operator!=(const std::tuple<_Tps ...>&, const std::tuple<_Elements ...>&)'
 1531 |     operator!=(const tuple<_TElements...>& __t,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/tuple:1531:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::tuple<_Tps ...>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/iosfwd:40,
                 from /usr/include/c++/11.1.0/system_error:40,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/postypes.h:227:5: note: candidate: 'template<class _StateT> bool std::operator!=(const std::fpos<_StateT>&, const std::fpos<_StateT>&)'
  227 |     operator!=(const fpos<_StateT>& __lhs, const fpos<_StateT>& __rhs)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/postypes.h:227:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::fpos<_StateT>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:41,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/allocator.h:213:5: note: candidate: 'template<class _T1, class _T2> bool std::operator!=(const std::allocator<_CharT>&, const std::allocator<_T2>&)'
  213 |     operator!=(const allocator<_T1>&, const allocator<_T2>&)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/allocator.h:213:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::allocator<_CharT>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:55,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/basic_string.h:6288:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> bool std::operator!=(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&)'
 6288 |     operator!=(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/basic_string.h:6288:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:55,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/basic_string.h:6301:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> bool std::operator!=(const _CharT*, const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&)'
 6301 |     operator!=(const _CharT* __lhs,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/basic_string.h:6301:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   mismatched types 'const _CharT*' and 'std::thread::id'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:55,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/basic_string.h:6313:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> bool std::operator!=(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, const _CharT*)'
 6313 |     operator!=(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/basic_string.h:6313:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr_base.h:59,
                 from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unique_ptr.h:774:5: note: candidate: 'template<class _Tp, class _Dp, class _Up, class _Ep> bool std::operator!=(const std::unique_ptr<_Tp, _Dp>&, const std::unique_ptr<_Up, _Ep>&)'
  774 |     operator!=(const unique_ptr<_Tp, _Dp>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unique_ptr.h:774:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unique_ptr<_Tp, _Dp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr_base.h:59,
                 from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unique_ptr.h:781:5: note: candidate: 'template<class _Tp, class _Dp> bool std::operator!=(const std::unique_ptr<_Tp, _Dp>&, std::nullptr_t)'
  781 |     operator!=(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unique_ptr.h:781:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unique_ptr<_Tp, _Dp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr_base.h:59,
                 from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unique_ptr.h:787:5: note: candidate: 'template<class _Tp, class _Dp> bool std::operator!=(std::nullptr_t, const std::unique_ptr<_Tp, _Dp>&)'
  787 |     operator!=(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unique_ptr.h:787:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unique_ptr<_Tp, _Dp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1436:5: note: candidate: 'template<class _Tp1, class _Tp2, __gnu_cxx::_Lock_policy _Lp> bool std::operator!=(const std::__shared_ptr<_Tp1, _Lp>&, const std::__shared_ptr<_Tp2, _Lp>&)'
 1436 |     operator!=(const __shared_ptr<_Tp1, _Lp>& __a,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1436:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__shared_ptr<_Tp1, _Lp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1442:5: note: candidate: 'template<class _Tp, __gnu_cxx::_Lock_policy _Lp> bool std::operator!=(const std::__shared_ptr<_Tp, _Lp>&, std::nullptr_t)'
 1442 |     operator!=(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1442:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__shared_ptr<_Tp, _Lp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1447:5: note: candidate: 'template<class _Tp, __gnu_cxx::_Lock_policy _Lp> bool std::operator!=(std::nullptr_t, const std::__shared_ptr<_Tp, _Lp>&)'
 1447 |     operator!=(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1447:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__shared_ptr<_Tp, _Lp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr.h:470:5: note: candidate: 'template<class _Tp, class _Up> bool std::operator!=(const std::shared_ptr<_Tp>&, const std::shared_ptr<_Tp>&)'
  470 |     operator!=(const shared_ptr<_Tp>& __a, const shared_ptr<_Up>& __b) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr.h:470:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::shared_ptr<_Tp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr.h:476:5: note: candidate: 'template<class _Tp> bool std::operator!=(const std::shared_ptr<_Tp>&, std::nullptr_t)'
  476 |     operator!=(const shared_ptr<_Tp>& __a, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr.h:476:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::shared_ptr<_Tp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr.h:482:5: note: candidate: 'template<class _Tp> bool std::operator!=(std::nullptr_t, const std::shared_ptr<_Tp>&)'
  482 |     operator!=(nullptr_t, const shared_ptr<_Tp>& __a) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr.h:482:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::shared_ptr<_Tp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/future:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/std_function.h:707:5: note: candidate: 'template<class _Res, class ... _Args> bool std::operator!=(const std::function<_Res(_ArgTypes ...)>&, std::nullptr_t)'
  707 |     operator!=(const function<_Res(_Args...)>& __f, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/std_function.h:707:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::function<_Res(_ArgTypes ...)>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/future:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/std_function.h:713:5: note: candidate: 'template<class _Res, class ... _Args> bool std::operator!=(std::nullptr_t, const std::function<_Res(_ArgTypes ...)>&)'
  713 |     operator!=(nullptr_t, const function<_Res(_Args...)>& __f) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/std_function.h:713:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::function<_Res(_ArgTypes ...)>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/list:63,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:21,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_list.h:2057:5: note: candidate: 'template<class _Tp, class _Alloc> bool std::operator!=(const std::__cxx11::list<_Tp, _Alloc>&, const std::__cxx11::list<_Tp, _Alloc>&)'
 2057 |     operator!=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_list.h:2057:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__cxx11::list<_Tp, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/unordered_map:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:23,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unordered_map.h:2141:5: note: candidate: 'template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> bool std::operator!=(const std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>&, const std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>&)'
 2141 |     operator!=(const unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unordered_map.h:2141:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/unordered_map:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:23,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unordered_map.h:2155:5: note: candidate: 'template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> bool std::operator!=(const std::unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>&, const std::unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>&)'
 2155 |     operator!=(const unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unordered_map.h:2155:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/vector:67,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/internal_desc_types.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/c_types_map.hpp:23,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_vector.h:1937:5: note: candidate: 'template<class _Tp, class _Alloc> bool std::operator!=(const std::vector<_Tp, _Alloc>&, const std::vector<_Tp, _Alloc>&)'
 1937 |     operator!=(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_vector.h:1937:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::vector<_Tp, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/map:61,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_attr.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_hashing.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_map.h:1508:5: note: candidate: 'template<class _Key, class _Tp, class _Compare, class _Alloc> bool std::operator!=(const std::map<_Key, _Tp, _Compare, _Alloc>&, const std::map<_Key, _Tp, _Compare, _Alloc>&)'
 1508 |     operator!=(const map<_Key, _Tp, _Compare, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_map.h:1508:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::map<_Key, _Tp, _Compare, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/map:62,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_attr.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_hashing.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_multimap.h:1173:5: note: candidate: 'template<class _Key, class _Tp, class _Compare, class _Alloc> bool std::operator!=(const std::multimap<_Key, _Tp, _Compare, _Alloc>&, const std::multimap<_Key, _Tp, _Compare, _Alloc>&)'
 1173 |     operator!=(const multimap<_Key, _Tp, _Compare, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_multimap.h:1173:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::multimap<_Key, _Tp, _Compare, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_attr.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_hashing.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/me/incubator-mxnet/3rdparty/onednn/src/common/type_helpers.hpp:314:13: note: candidate: 'bool dnnl::impl::operator!=(const memory_desc_t&, const memory_desc_t&)'
  314 | inline bool operator!=(const memory_desc_t &lhs, const memory_desc_t &rhs) {
      |             ^~~~~~~~
/me/incubator-mxnet/3rdparty/onednn/src/common/type_helpers.hpp:314:45: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const memory_desc_t&' {aka 'const dnnl_memory_desc_t&'}
  314 | inline bool operator!=(const memory_desc_t &lhs, const memory_desc_t &rhs) {
      |                        ~~~~~~~~~~~~~~~~~~~~~^~~
In file included from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/system_error:400:3: note: candidate: 'bool std::operator!=(const std::error_code&, const std::error_code&)'
  400 |   operator!=(const error_code& __lhs, const error_code& __rhs) noexcept
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:400:32: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_code&'
  400 |   operator!=(const error_code& __lhs, const error_code& __rhs) noexcept
      |              ~~~~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/11.1.0/system_error:406:3: note: candidate: 'bool std::operator!=(const std::error_code&, const std::error_condition&)'
  406 |   operator!=(const error_code& __lhs, const error_condition& __rhs) noexcept
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:406:32: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_code&'
  406 |   operator!=(const error_code& __lhs, const error_condition& __rhs) noexcept
      |              ~~~~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/11.1.0/system_error:412:3: note: candidate: 'bool std::operator!=(const std::error_condition&, const std::error_code&)'
  412 |   operator!=(const error_condition& __lhs, const error_code& __rhs) noexcept
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:412:37: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_condition&'
  412 |   operator!=(const error_condition& __lhs, const error_code& __rhs) noexcept
      |              ~~~~~~~~~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/11.1.0/system_error:417:3: note: candidate: 'bool std::operator!=(const std::error_condition&, const std::error_condition&)'
  417 |   operator!=(const error_condition& __lhs,
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:417:37: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_condition&'
  417 |   operator!=(const error_condition& __lhs,
      |              ~~~~~~~~~~~~~~~~~~~~~~~^~~~~

Description

Please include a summary of the change. Please also include relevant motivation and context. See contribution guidelines for more details. If the change fixes an issue not documented in the project's Github issue tracker, please document all steps necessary to reproduce it.

Fixes # (github issue)

Checklist

General

  • Do all unit and benchdnn tests (make test and make test_benchdnn_*) pass locally for each commit?
  • Have you formatted the code using clang-format?

Performance improvements

  • Have you submitted performance data that demonstrates performance improvements?

New features

  • Have you published an RFC for the new feature?
  • Was the RFC approved?
  • Have you added relevant tests?

Bug fixes

  • Have you included information on how to reproduce the issue (either in a github issue or in this PR)?
  • Have you added relevant regression tests?

RFC PR

  • Does RFC document follow the template?
  • Have you added a link to the rendered document?

It seems that, gcc11 do not support a `!=` operator for `std::thread::id`
I tried to fix it by switch the `!=` operator to `==` and put the `!` operator outside the compare op.

I don't know whether the compare op behaves correct, but that's the only way I could bypass that error.

Error:
```
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp: In member function 'virtual void dnnl::impl::lru_primitive_cache_t::update_entry(const key_t&, const dnnl::impl::primitive_desc_t*)':
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:60: error: no match for 'operator!=' (operand types are 'const std::thread::id' and 'const std::thread::id')
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                      ~~~~~~~~~~~~~~~~~~~~~ ^~ ~~~~~~~~~~~~~~~
      |                                                         |                  |
      |                                                         |                  const std::thread::id
      |                                                         const std::thread::id
In file included from /usr/include/c++/11.1.0/utility:70,
                 from /usr/include/c++/11.1.0/tuple:38,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_pair.h:496:5: note: candidate: 'template<class _T1, class _T2> constexpr bool std::operator!=(const std::pair<_T1, _T2>&, const std::pair<_T1, _T2>&)'
  496 |     operator!=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_pair.h:496:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::pair<_T1, _T2>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:428:5: note: candidate: 'template<class _Iterator> bool std::operator!=(const std::reverse_iterator<_Iterator>&, const std::reverse_iterator<_Iterator>&)'
  428 |     operator!=(const reverse_iterator<_Iterator>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:428:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::reverse_iterator<_Iterator>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:467:5: note: candidate: 'template<class _IteratorL, class _IteratorR> bool std::operator!=(const std::reverse_iterator<_Iterator>&, const std::reverse_iterator<_IteratorR>&)'
  467 |     operator!=(const reverse_iterator<_IteratorL>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:467:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::reverse_iterator<_Iterator>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:1550:5: note: candidate: 'template<class _IteratorL, class _IteratorR> bool std::operator!=(const std::move_iterator<_IteratorL>&, const std::move_iterator<_IteratorR>&)'
 1550 |     operator!=(const move_iterator<_IteratorL>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:1550:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::move_iterator<_IteratorL>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/stl_algobase.h:67,
                 from /usr/include/c++/11.1.0/array:40,
                 from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_iterator.h:1607:5: note: candidate: 'template<class _Iterator> bool std::operator!=(const std::move_iterator<_IteratorL>&, const std::move_iterator<_IteratorL>&)'
 1607 |     operator!=(const move_iterator<_Iterator>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_iterator.h:1607:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::move_iterator<_IteratorL>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/tuple:39,
                 from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/array:305:5: note: candidate: 'template<class _Tp, long unsigned int _Nm> bool std::operator!=(const std::array<_Tp, _Nm>&, const std::array<_Tp, _Nm>&)'
  305 |     operator!=(const array<_Tp, _Nm>& __one, const array<_Tp, _Nm>& __two)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/array:305:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::array<_Tp, _Nm>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/mutex:38,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/tuple:1531:5: note: candidate: 'template<class ... _TElements, class ... _UElements> constexpr bool std::operator!=(const std::tuple<_Tps ...>&, const std::tuple<_Elements ...>&)'
 1531 |     operator!=(const tuple<_TElements...>& __t,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/tuple:1531:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::tuple<_Tps ...>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/iosfwd:40,
                 from /usr/include/c++/11.1.0/system_error:40,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/postypes.h:227:5: note: candidate: 'template<class _StateT> bool std::operator!=(const std::fpos<_StateT>&, const std::fpos<_StateT>&)'
  227 |     operator!=(const fpos<_StateT>& __lhs, const fpos<_StateT>& __rhs)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/postypes.h:227:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::fpos<_StateT>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:41,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/allocator.h:213:5: note: candidate: 'template<class _T1, class _T2> bool std::operator!=(const std::allocator<_CharT>&, const std::allocator<_T2>&)'
  213 |     operator!=(const allocator<_T1>&, const allocator<_T2>&)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/allocator.h:213:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::allocator<_CharT>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:55,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/basic_string.h:6288:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> bool std::operator!=(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&)'
 6288 |     operator!=(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/basic_string.h:6288:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:55,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/basic_string.h:6301:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> bool std::operator!=(const _CharT*, const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&)'
 6301 |     operator!=(const _CharT* __lhs,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/basic_string.h:6301:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   mismatched types 'const _CharT*' and 'std::thread::id'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/string:55,
                 from /usr/include/c++/11.1.0/stdexcept:39,
                 from /usr/include/c++/11.1.0/system_error:41,
                 from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/basic_string.h:6313:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> bool std::operator!=(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&, const _CharT*)'
 6313 |     operator!=(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/basic_string.h:6313:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr_base.h:59,
                 from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unique_ptr.h:774:5: note: candidate: 'template<class _Tp, class _Dp, class _Up, class _Ep> bool std::operator!=(const std::unique_ptr<_Tp, _Dp>&, const std::unique_ptr<_Up, _Ep>&)'
  774 |     operator!=(const unique_ptr<_Tp, _Dp>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unique_ptr.h:774:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unique_ptr<_Tp, _Dp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr_base.h:59,
                 from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unique_ptr.h:781:5: note: candidate: 'template<class _Tp, class _Dp> bool std::operator!=(const std::unique_ptr<_Tp, _Dp>&, std::nullptr_t)'
  781 |     operator!=(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unique_ptr.h:781:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unique_ptr<_Tp, _Dp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr_base.h:59,
                 from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unique_ptr.h:787:5: note: candidate: 'template<class _Tp, class _Dp> bool std::operator!=(std::nullptr_t, const std::unique_ptr<_Tp, _Dp>&)'
  787 |     operator!=(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unique_ptr.h:787:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unique_ptr<_Tp, _Dp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1436:5: note: candidate: 'template<class _Tp1, class _Tp2, __gnu_cxx::_Lock_policy _Lp> bool std::operator!=(const std::__shared_ptr<_Tp1, _Lp>&, const std::__shared_ptr<_Tp2, _Lp>&)'
 1436 |     operator!=(const __shared_ptr<_Tp1, _Lp>& __a,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1436:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__shared_ptr<_Tp1, _Lp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1442:5: note: candidate: 'template<class _Tp, __gnu_cxx::_Lock_policy _Lp> bool std::operator!=(const std::__shared_ptr<_Tp, _Lp>&, std::nullptr_t)'
 1442 |     operator!=(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1442:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__shared_ptr<_Tp, _Lp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/bits/shared_ptr.h:53,
                 from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1447:5: note: candidate: 'template<class _Tp, __gnu_cxx::_Lock_policy _Lp> bool std::operator!=(std::nullptr_t, const std::__shared_ptr<_Tp, _Lp>&)'
 1447 |     operator!=(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr_base.h:1447:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__shared_ptr<_Tp, _Lp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr.h:470:5: note: candidate: 'template<class _Tp, class _Up> bool std::operator!=(const std::shared_ptr<_Tp>&, const std::shared_ptr<_Tp>&)'
  470 |     operator!=(const shared_ptr<_Tp>& __a, const shared_ptr<_Up>& __b) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr.h:470:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::shared_ptr<_Tp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr.h:476:5: note: candidate: 'template<class _Tp> bool std::operator!=(const std::shared_ptr<_Tp>&, std::nullptr_t)'
  476 |     operator!=(const shared_ptr<_Tp>& __a, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr.h:476:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::shared_ptr<_Tp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/condition_variable:43,
                 from /usr/include/c++/11.1.0/future:39,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/shared_ptr.h:482:5: note: candidate: 'template<class _Tp> bool std::operator!=(std::nullptr_t, const std::shared_ptr<_Tp>&)'
  482 |     operator!=(nullptr_t, const shared_ptr<_Tp>& __a) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/shared_ptr.h:482:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::shared_ptr<_Tp>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/future:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/std_function.h:707:5: note: candidate: 'template<class _Res, class ... _Args> bool std::operator!=(const std::function<_Res(_ArgTypes ...)>&, std::nullptr_t)'
  707 |     operator!=(const function<_Res(_Args...)>& __f, nullptr_t) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/std_function.h:707:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::function<_Res(_ArgTypes ...)>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/future:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/std_function.h:713:5: note: candidate: 'template<class _Res, class ... _Args> bool std::operator!=(std::nullptr_t, const std::function<_Res(_ArgTypes ...)>&)'
  713 |     operator!=(nullptr_t, const function<_Res(_Args...)>& __f) noexcept
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/std_function.h:713:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::function<_Res(_ArgTypes ...)>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/list:63,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:21,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_list.h:2057:5: note: candidate: 'template<class _Tp, class _Alloc> bool std::operator!=(const std::__cxx11::list<_Tp, _Alloc>&, const std::__cxx11::list<_Tp, _Alloc>&)'
 2057 |     operator!=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_list.h:2057:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::__cxx11::list<_Tp, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/unordered_map:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:23,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unordered_map.h:2141:5: note: candidate: 'template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> bool std::operator!=(const std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>&, const std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>&)'
 2141 |     operator!=(const unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unordered_map.h:2141:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/unordered_map:47,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:23,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/unordered_map.h:2155:5: note: candidate: 'template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> bool std::operator!=(const std::unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>&, const std::unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>&)'
 2155 |     operator!=(const unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/unordered_map.h:2155:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/vector:67,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/internal_desc_types.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/c_types_map.hpp:23,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_vector.h:1937:5: note: candidate: 'template<class _Tp, class _Alloc> bool std::operator!=(const std::vector<_Tp, _Alloc>&, const std::vector<_Tp, _Alloc>&)'
 1937 |     operator!=(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y)
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_vector.h:1937:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::vector<_Tp, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/map:61,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_attr.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_hashing.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_map.h:1508:5: note: candidate: 'template<class _Key, class _Tp, class _Compare, class _Alloc> bool std::operator!=(const std::map<_Key, _Tp, _Compare, _Alloc>&, const std::map<_Key, _Tp, _Compare, _Alloc>&)'
 1508 |     operator!=(const map<_Key, _Tp, _Compare, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_map.h:1508:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::map<_Key, _Tp, _Compare, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /usr/include/c++/11.1.0/map:62,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_attr.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_hashing.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/bits/stl_multimap.h:1173:5: note: candidate: 'template<class _Key, class _Tp, class _Compare, class _Alloc> bool std::operator!=(const std::multimap<_Key, _Tp, _Compare, _Alloc>&, const std::multimap<_Key, _Tp, _Compare, _Alloc>&)'
 1173 |     operator!=(const multimap<_Key, _Tp, _Compare, _Alloc>& __x,
      |     ^~~~~~~~
/usr/include/c++/11.1.0/bits/stl_multimap.h:1173:5: note:   template argument deduction/substitution failed:
/me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:155:77: note:   'const std::thread::id' is not derived from 'const std::multimap<_Key, _Tp, _Compare, _Alloc>'
  155 |     if (it == cache_mapper_.end() || it->first.thread_id() != key.thread_id())
      |                                                                             ^
In file included from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_attr.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_hashing.hpp:25,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:27,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/me/incubator-mxnet/3rdparty/onednn/src/common/type_helpers.hpp:314:13: note: candidate: 'bool dnnl::impl::operator!=(const memory_desc_t&, const memory_desc_t&)'
  314 | inline bool operator!=(const memory_desc_t &lhs, const memory_desc_t &rhs) {
      |             ^~~~~~~~
/me/incubator-mxnet/3rdparty/onednn/src/common/type_helpers.hpp:314:45: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const memory_desc_t&' {aka 'const dnnl_memory_desc_t&'}
  314 | inline bool operator!=(const memory_desc_t &lhs, const memory_desc_t &rhs) {
      |                        ~~~~~~~~~~~~~~~~~~~~~^~~
In file included from /usr/include/c++/11.1.0/mutex:42,
                 from /usr/include/c++/11.1.0/future:38,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.hpp:20,
                 from /me/incubator-mxnet/3rdparty/onednn/src/common/primitive_cache.cpp:17:
/usr/include/c++/11.1.0/system_error:400:3: note: candidate: 'bool std::operator!=(const std::error_code&, const std::error_code&)'
  400 |   operator!=(const error_code& __lhs, const error_code& __rhs) noexcept
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:400:32: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_code&'
  400 |   operator!=(const error_code& __lhs, const error_code& __rhs) noexcept
      |              ~~~~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/11.1.0/system_error:406:3: note: candidate: 'bool std::operator!=(const std::error_code&, const std::error_condition&)'
  406 |   operator!=(const error_code& __lhs, const error_condition& __rhs) noexcept
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:406:32: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_code&'
  406 |   operator!=(const error_code& __lhs, const error_condition& __rhs) noexcept
      |              ~~~~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/11.1.0/system_error:412:3: note: candidate: 'bool std::operator!=(const std::error_condition&, const std::error_code&)'
  412 |   operator!=(const error_condition& __lhs, const error_code& __rhs) noexcept
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:412:37: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_condition&'
  412 |   operator!=(const error_condition& __lhs, const error_code& __rhs) noexcept
      |              ~~~~~~~~~~~~~~~~~~~~~~~^~~~~
/usr/include/c++/11.1.0/system_error:417:3: note: candidate: 'bool std::operator!=(const std::error_condition&, const std::error_condition&)'
  417 |   operator!=(const error_condition& __lhs,
      |   ^~~~~~~~
/usr/include/c++/11.1.0/system_error:417:37: note:   no known conversion for argument 1 from 'const std::thread::id' to 'const std::error_condition&'
  417 |   operator!=(const error_condition& __lhs,
      |              ~~~~~~~~~~~~~~~~~~~~~~~^~~~~
```
I don't know why clang-format so stupid that it changes nearly all of the code.
If you know the reason, tell me.
the previous version is from mxnet, which is quite old.
and I fixed the stupid op in this commit
@densamoilov
Copy link
Contributor

densamoilov commented Jun 14, 2021

Hi @Neutron3529 ,
It seems that, gcc11 do not support a != operator for std::thread::id - actually, this is not the reason for the error. The reason is that thread header file is not included in this file and this is fixed in 1fe0f25. More details in #1023.

@Neutron3529
Copy link
Author

Hi @Neutron3529 ,
It seems that, gcc11 do not support a != operator for std::thread::id - actually, this is not the reason for the error. The reason is that thread header file is not included in this file and this is fixed in 1fe0f25. More details in #1023.

you're right.

zimo-mo added a commit to zimo-mo/mindspore that referenced this pull request Dec 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants