[Mlir-commits] [llvm] [mlir] [WIP] Refactor post order traversal (PR #191047)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Wed Apr 8 13:47:06 PDT 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results

* 129585 tests passed
* 2659 tests skipped

All executed tests passed, but another part of the build **failed**. Click on a failure below to see the details.

<details>
<summary>[code=1] tools/mlir/test/lib/IR/CMakeFiles/MLIRTestIR.dir/TestVisitors.cpp.obj</summary>

```
FAILED: [code=1] tools/mlir/test/lib/IR/CMakeFiles/MLIRTestIR.dir/TestVisitors.cpp.obj
sccache C:\clang\clang-msvc\bin\clang-cl.exe  /nologo -TP -DMLIR_INCLUDE_TESTS -DUNICODE -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS -D_GLIBCXX_ASSERTIONS -D_HAS_EXCEPTIONS=0 -D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_EXTENSIVE -D_SCL_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -D_UNICODE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -IC:\_work\llvm-project\llvm-project\build\tools\mlir\test\lib\IR -IC:\_work\llvm-project\llvm-project\mlir\test\lib\IR -IC:\_work\llvm-project\llvm-project\build\tools\mlir\include -IC:\_work\llvm-project\llvm-project\mlir\include -IC:\_work\llvm-project\llvm-project\build\include -IC:\_work\llvm-project\llvm-project\llvm\include -IC:\_work\llvm-project\llvm-project\mlir\test\lib\IR\..\Dialect\Test -IC:\_work\llvm-project\llvm-project\build\tools\mlir\test\lib\IR\..\Dialect\Test /DWIN32 /D_WINDOWS   /Zc:inline /Zc:__cplusplus /Oi /Brepro /bigobj /permissive- -Werror=unguarded-availability-new /W4  -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wno-pass-failed -Wmisleading-indentation -Wctad-maybe-unsupported /Gw -Wundef -Werror=mismatched-tags /O2 /Ob2  -std:c++17 -MD -UNDEBUG /EHs-c- /GR- /showIncludes /Fotools\mlir\test\lib\IR\CMakeFiles\MLIRTestIR.dir\TestVisitors.cpp.obj /Fdtools\mlir\test\lib\IR\CMakeFiles\MLIRTestIR.dir\MLIRTestIR.pdb -c -- C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp
In file included from C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:9:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/BuiltinOps.h:16:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeImplementation.h:19:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Dialect.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/OperationSupport.h:19:
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/BuiltinAttributes.h(346,14): warning: 'complex' is deprecated: warning STL4037: The effect of instantiating the template std::complex for any type other than float, double, or long double is unspecified. You can define _SILENCE_NONFLOATING_COMPLEX_DEPRECATION_WARNING to suppress this warning. [-Wdeprecated-declarations]
346 |       return {APFloat(*smt, value.real()), APFloat(*smt, value.imag())};
|              ^
C:\BuildTools\VC\Tools\MSVC\14.44.35207\include\complex(1333,5): note: 'complex' has been explicitly marked deprecated here
1333 |     _DEPRECATE_NONFLOATING_COMPLEX
|     ^
C:\BuildTools\VC\Tools\MSVC\14.44.35207\include\yvals_core.h(1413,7): note: expanded from macro '_DEPRECATE_NONFLOATING_COMPLEX'
1413 |     [[deprecated("warning STL4037: "                                                   \
|       ^
In file included from C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:9:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/BuiltinOps.h:16:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeImplementation.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Attributes.h:12:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/AttributeSupport.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/StorageUniquerSupport.h:16:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/AttrTypeSubElements.h:18:
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Visitors.h(143,24): error: no matching function for call to 'makeIterable'
143 |     for (auto &block : Iterator::makeIterable(region)) {
|                        ^~~~~~~~~~~~~~~~~~~~~~
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Visitors.h(278,18): note: in instantiation of function template specialization 'mlir::detail::walk<mlir::ReverseDominanceIterator<true>>' requested here
278 |   return detail::walk<Iterator>(op, function_ref<RetT(ArgT)>(callback), Order);
|                  ^
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Operation.h(824,20): note: in instantiation of function template specialization 'mlir::detail::walk<mlir::WalkOrder::PostOrder, mlir::ReverseDominanceIterator<true>, (lambda at C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:34:17) &, mlir::Operation *, void>' requested here
824 |     return detail::walk<Order, Iterator>(this, std::forward<FnT>(callback));
|                    ^
C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp(99,13): note: in instantiation of function template specialization 'mlir::Operation::walk<mlir::WalkOrder::PostOrder, mlir::ReverseDominanceIterator<true>, (lambda at C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:34:17) &, void>' requested here
99 |     funcOp->walk<WalkOrder::PostOrder,
|             ^
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Iterators.h(96,25): note: candidate function not viable: no known conversion from 'mlir::Region' to 'Block &' for 1st argument
96 |   static constexpr auto makeIterable(Block &range) {
|                         ^            ~~~~~~~~~~~~
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Iterators.h(100,25): note: candidate function not viable: no known conversion from 'mlir::Region' to 'Operation &' for 1st argument
100 |   static constexpr auto makeIterable(Operation &range) {
|                         ^            ~~~~~~~~~~~~~~~~
In file included from C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:9:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/BuiltinOps.h:16:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeImplementation.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Attributes.h:12:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/AttributeSupport.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/StorageUniquerSupport.h:16:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/AttrTypeSubElements.h:18:
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Visitors.h(124,37): error: no matching function for call to 'makeIterable'
124 |          llvm::make_early_inc_range(Iterator::makeIterable(region))) {
|                                     ^~~~~~~~~~~~~~~~~~~~~~
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Visitors.h(278,18): note: in instantiation of function template specialization 'mlir::detail::walk<mlir::ReverseDominanceIterator<true>>' requested here
278 |   return detail::walk<Iterator>(op, function_ref<RetT(ArgT)>(callback), Order);
|                  ^
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Operation.h(824,20): note: in instantiation of function template specialization 'mlir::detail::walk<mlir::WalkOrder::PostOrder, mlir::ReverseDominanceIterator<true>, (lambda at C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:39:20) &, mlir::Block *, void>' requested here
824 |     return detail::walk<Order, Iterator>(this, std::forward<FnT>(callback));
|                    ^
C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp(103,13): note: in instantiation of function template specialization 'mlir::Operation::walk<mlir::WalkOrder::PostOrder, mlir::ReverseDominanceIterator<true>, (lambda at C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:39:20) &, void>' requested here
103 |     funcOp->walk<WalkOrder::PostOrder,
|             ^
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Iterators.h(96,25): note: candidate function not viable: no known conversion from 'mlir::Region' to 'Block &' for 1st argument
96 |   static constexpr auto makeIterable(Block &range) {
|                         ^            ~~~~~~~~~~~~
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Iterators.h(100,25): note: candidate function not viable: no known conversion from 'mlir::Region' to 'Operation &' for 1st argument
100 |   static constexpr auto makeIterable(Operation &range) {
|                         ^            ~~~~~~~~~~~~~~~~
In file included from C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:9:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/BuiltinOps.h:16:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/Bytecode/BytecodeImplementation.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Attributes.h:12:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/AttributeSupport.h:17:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/StorageUniquerSupport.h:16:
In file included from C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/AttrTypeSubElements.h:18:
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Visitors.h(109,24): error: no matching function for call to 'makeIterable'
109 |     for (auto &block : Iterator::makeIterable(region)) {
|                        ^~~~~~~~~~~~~~~~~~~~~~
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Visitors.h(278,18): note: in instantiation of function template specialization 'mlir::detail::walk<mlir::ReverseDominanceIterator<true>>' requested here
278 |   return detail::walk<Iterator>(op, function_ref<RetT(ArgT)>(callback), Order);
|                  ^
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Operation.h(824,20): note: in instantiation of function template specialization 'mlir::detail::walk<mlir::WalkOrder::PostOrder, mlir::ReverseDominanceIterator<true>, (lambda at C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:44:21) &, mlir::Region *, void>' requested here
824 |     return detail::walk<Order, Iterator>(this, std::forward<FnT>(callback));
|                    ^
C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp(107,13): note: in instantiation of function template specialization 'mlir::Operation::walk<mlir::WalkOrder::PostOrder, mlir::ReverseDominanceIterator<true>, (lambda at C:\_work\llvm-project\llvm-project\mlir\test\lib\IR\TestVisitors.cpp:44:21) &, void>' requested here
107 |     funcOp->walk<WalkOrder::PostOrder,
|             ^
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Iterators.h(96,25): note: candidate function not viable: no known conversion from 'mlir::Region' to 'Block &' for 1st argument
96 |   static constexpr auto makeIterable(Block &range) {
|                         ^            ~~~~~~~~~~~~
C:\_work\llvm-project\llvm-project\mlir\include\mlir/IR/Iterators.h(100,25): note: candidate function not viable: no known conversion from 'mlir::Region' to 'Operation &' for 1st argument
100 |   static constexpr auto makeIterable(Operation &range) {
|                         ^            ~~~~~~~~~~~~~~~~
1 warning and 3 errors generated.
```
</details>

If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.

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


More information about the Mlir-commits mailing list