[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: Linux-->
# :penguin: Linux x64 Test Results

* 164514 tests passed
* 2529 tests skipped

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

<details>
<summary>tools/mlir/test/lib/IR/CMakeFiles/MLIRTestIR.dir/TestVisitors.cpp.o</summary>

```
FAILED: tools/mlir/test/lib/IR/CMakeFiles/MLIRTestIR.dir/TestVisitors.cpp.o
sccache /opt/llvm/bin/clang++ -DMLIR_INCLUDE_TESTS -D_DEBUG -D_GLIBCXX_ASSERTIONS -D_GLIBCXX_USE_CXX11_ABI=1 -D_GNU_SOURCE -D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_EXTENSIVE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/mlir/test/lib/IR -I/home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/mlir/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/../Dialect/Test -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/tools/mlir/test/lib/IR/../Dialect/Test -gmlt -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -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 -fdiagnostics-color -ffunction-sections -fdata-sections -Wundef -Werror=mismatched-tags -O3 -DNDEBUG -std=c++17 -UNDEBUG -fno-exceptions -funwind-tables -fno-rtti -MD -MT tools/mlir/test/lib/IR/CMakeFiles/MLIRTestIR.dir/TestVisitors.cpp.o -MF tools/mlir/test/lib/IR/CMakeFiles/MLIRTestIR.dir/TestVisitors.cpp.o.d -o tools/mlir/test/lib/IR/CMakeFiles/MLIRTestIR.dir/TestVisitors.cpp.o -c /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/TestVisitors.cpp
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/TestVisitors.cpp:9:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/BuiltinOps.h:16:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/Bytecode/BytecodeImplementation.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/Attributes.h:12:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/AttributeSupport.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/StorageUniquerSupport.h:16:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/AttrTypeSubElements.h:18:
/home/gha/actions-runner/_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)) {
|                        ^~~~~~~~~~~~~~~~~~~~~~
/home/gha/actions-runner/_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);
|                  ^
/home/gha/actions-runner/_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 /home/gha/actions-runner/_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));
|                    ^
/home/gha/actions-runner/_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 /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/TestVisitors.cpp:34:17) &, void>' requested here
99 |     funcOp->walk<WalkOrder::PostOrder,
|             ^
/home/gha/actions-runner/_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) {
|                         ^            ~~~~~~~~~~~~
/home/gha/actions-runner/_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 /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/TestVisitors.cpp:9:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/BuiltinOps.h:16:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/Bytecode/BytecodeImplementation.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/Attributes.h:12:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/AttributeSupport.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/StorageUniquerSupport.h:16:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/AttrTypeSubElements.h:18:
/home/gha/actions-runner/_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))) {
|                                     ^~~~~~~~~~~~~~~~~~~~~~
/home/gha/actions-runner/_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);
|                  ^
/home/gha/actions-runner/_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 /home/gha/actions-runner/_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));
|                    ^
/home/gha/actions-runner/_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 /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/TestVisitors.cpp:39:20) &, void>' requested here
103 |     funcOp->walk<WalkOrder::PostOrder,
|             ^
/home/gha/actions-runner/_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) {
|                         ^            ~~~~~~~~~~~~
/home/gha/actions-runner/_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 /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/TestVisitors.cpp:9:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/BuiltinOps.h:16:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/Bytecode/BytecodeOpInterface.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/Bytecode/BytecodeImplementation.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/Attributes.h:12:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/AttributeSupport.h:17:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/StorageUniquerSupport.h:16:
In file included from /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/include/mlir/IR/AttrTypeSubElements.h:18:
/home/gha/actions-runner/_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)) {
|                        ^~~~~~~~~~~~~~~~~~~~~~
/home/gha/actions-runner/_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);
|                  ^
/home/gha/actions-runner/_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 /home/gha/actions-runner/_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));
|                    ^
/home/gha/actions-runner/_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 /home/gha/actions-runner/_work/llvm-project/llvm-project/mlir/test/lib/IR/TestVisitors.cpp:44:21) &, void>' requested here
107 |     funcOp->walk<WalkOrder::PostOrder,
|             ^
/home/gha/actions-runner/_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) {
|                         ^            ~~~~~~~~~~~~
/home/gha/actions-runner/_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) {
|                         ^            ~~~~~~~~~~~~~~~~
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