-
Notifications
You must be signed in to change notification settings - Fork 49
Open
Description
There is a known upstream llvm bug where clang>17 using libstdc++12 will result in many deprecated function warnings in relation to stable_sort
. For rocm7.0 builds, we use clang20, and default libstdc++11, but another package for rocm7.0 installs stdc++12, which then causes all future uses of clang to use that version.
The request here is to get rid of or suppress the warning.
Ex.
[3413/3519] Building CXX object mlir/lib/Dialect/MIGraphX/CMakeFiles/obj.MLIRMIGraphXDialect.dir/IR/MIGraphX.cpp.o
In file included from /src/rocMLIR/mlir/lib/Dialect/MIGraphX/IR/MIGraphX.cpp:10:
In file included from /src/rocMLIR/mlir/include/mlir/Dialect/MIGraphX/IR/MIGraphX.h:16:
In file included from /src/rocMLIR/external/llvm-project/mlir/include/mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from /src/rocMLIR/external/llvm-project/mlir/include/mlir/Bytecode/BytecodeImplementation.h:17:
In file included from /src/rocMLIR/external/llvm-project/mlir/include/mlir/IR/Attributes.h:12:
In file included from /src/rocMLIR/external/llvm-project/mlir/include/mlir/IR/AttributeSupport.h:16:
In file included from /src/rocMLIR/external/llvm-project/mlir/include/mlir/IR/MLIRContext.h:12:
In file included from /src/rocMLIR/external/llvm-project/mlir/include/mlir/Support/LLVM.h:23:
In file included from /src/rocMLIR/external/llvm-project/llvm/include/llvm/Support/Casting.h:20:
In file included from /usr/lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/memory:66:
/usr/lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/stl_tempbuf.h:263:8: warning: 'get_temporary_buffer<long>' is deprecated [-Wdeprecated-declarations]
263 | std::get_temporary_buffer<value_type>(_M_original_len));
| ^
/usr/lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/stl_algo.h:4996:15: note: in instantiation of member function 'std::_Temporary_buffer<long *, long>::_Temporary_buffer' requested here
4996 | _TmpBuf __buf(__first, (__last - __first + 1) / 2);
| ^
/usr/lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/stl_algo.h:5070:23: note: in instantiation of function template specialization 'std::__stable_sort<long *, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at /src/rocMLIR/mlir/lib/Dialect/MIGraphX/IR/MIGraphX.cpp:272:26)>>' requested here
5070 | _GLIBCXX_STD_A::__stable_sort(__first, __last,
| ^
/src/rocMLIR/external/llvm-project/llvm/include/llvm/ADT/STLExtras.h:2077:8: note: in instantiation of function template specialization 'std::stable_sort<long *, (lambda at /src/rocMLIR/mlir/lib/Dialect/MIGraphX/IR/MIGraphX.cpp:272:26)>' requested here
2077 | std::stable_sort(adl_begin(Range), adl_end(Range), C);
| ^
/src/rocMLIR/mlir/lib/Dialect/MIGraphX/IR/MIGraphX.cpp:272:9: note: in instantiation of function template specialization 'llvm::stable_sort<llvm::SmallVectorImpl<long> &, (lambda at /src/rocMLIR/mlir/lib/Dialect/MIGraphX/IR/MIGraphX.cpp:272:26)>' requested here
272 | llvm::stable_sort(ret, [&](auto a, auto b) {
| ^
/usr/lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/stl_tempbuf.h:99:5: note: 'get_temporary_buffer<long>' has been explicitly marked deprecated here
99 | _GLIBCXX17_DEPRECATED
| ^
/usr/lib/gcc/x86_64-linux-gnu/12/../../../../include/x86_64-linux-gnu/c++/12/bits/c++config.h:119:34: note: expanded from macro '_GLIBCXX17_DEPRECATED'
119 | # define _GLIBCXX17_DEPRECATED [[__deprecated__]]
| ^
1 warning generated.
Metadata
Metadata
Assignees
Labels
No labels