[llvm] [AArch64][MachineCombiner] Reassociate long chains of accumulation instructions into a tree to increase ILP (PR #126060)

LLVM Continuous Integration via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 23 04:45:26 PDT 2025


llvm-ci wrote:

LLVM Buildbot has detected a new failure on builder `clang-ppc64le-linux-test-suite` running on `ppc64le-clang-test-suite` while building `llvm` at step 5 "build-unified-tree".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/95/builds/11120

<details>
<summary>Here is the relevant piece of the build log for the reference</summary>

```
Step 5 (build-unified-tree) failure: build (failure)
...
30.171 [103/631/182] Building CXX object lib/Target/Sparc/CMakeFiles/LLVMSparcCodeGen.dir/SparcRegisterInfo.cpp.o
30.235 [103/630/183] Building CXX object lib/Target/AVR/CMakeFiles/LLVMAVRCodeGen.dir/AVRInstrInfo.cpp.o
30.237 [103/629/184] Building CXX object lib/Target/BPF/CMakeFiles/LLVMBPFCodeGen.dir/BPFMIChecking.cpp.o
30.250 [103/628/185] Building CXX object lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/MachineOperand.cpp.o
30.285 [103/627/186] Building CXX object lib/Target/BPF/CMakeFiles/LLVMBPFCodeGen.dir/BPFInstrInfo.cpp.o
30.303 [103/626/187] Linking CXX executable bin/verify-uselistorder
30.339 [103/625/188] Building CXX object lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/MachineFunctionSplitter.cpp.o
30.382 [103/624/189] Building CXX object lib/Target/LoongArch/CMakeFiles/LLVMLoongArchCodeGen.dir/LoongArchFrameLowering.cpp.o
30.391 [103/623/190] Building CXX object lib/Target/NVPTX/CMakeFiles/LLVMNVPTXCodeGen.dir/NVPTXReplaceImageHandles.cpp.o
30.421 [103/622/191] Building CXX object lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetInstrInfo.cpp.o
FAILED: lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetInstrInfo.cpp.o 
ccache /usr/lib64/ccache/c++ -DGTEST_HAS_RTTI=0 -D_DEBUG -D_GLIBCXX_ASSERTIONS -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/build/lib/CodeGen -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/build/include -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/include -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wno-uninitialized -Wno-nonnull -Wno-class-memaccess -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -Wno-misleading-indentation -fdiagnostics-color -ffunction-sections -fdata-sections -O3 -DNDEBUG -std=c++17  -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -MD -MT lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetInstrInfo.cpp.o -MF lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetInstrInfo.cpp.o.d -o lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetInstrInfo.cpp.o -c /home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen/TargetInstrInfo.cpp
In file included from /usr/include/c++/8/cassert:44,
                 from /home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/include/llvm/ADT/IntrusiveRefCntPtr.h:64,
                 from /home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/include/llvm/Support/PGOOptions.h:17,
                 from /home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/include/llvm/Target/TargetMachine.h:24,
                 from /home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen/TargetInstrInfo.cpp:38:
/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen/TargetInstrInfo.cpp: In member function ‘virtual void llvm::TargetInstrInfo::genAlternativeCodeSequence(llvm::MachineInstr&, unsigned int, llvm::SmallVectorImpl<llvm::MachineInstr*>&, llvm::SmallVectorImpl<llvm::MachineInstr*>&, llvm::DenseMap<llvm::Register, unsigned int>&) const’:
/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen/TargetInstrInfo.cpp:1487:46: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
         assert(IndexedReg.index() - MaxWidth >= 0);
                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen/TargetInstrInfo.cpp:1514:75: error: no matching function for call to ‘llvm::TargetInstrInfo::reduceAccumulatorTree(llvm::SmallVector<llvm::Register, 8>&, llvm::SmallVectorImpl<llvm::MachineInstr*>&, llvm::MachineFunction&, llvm::MachineInstr&, llvm::MachineRegisterInfo&, llvm::DenseMap<llvm::Register, unsigned int>&, llvm::Register) const’
                             InstIdxForVirtReg, Root.getOperand(0).getReg());
                                                                           ^
/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen/TargetInstrInfo.cpp:1017:6: note: candidate: ‘void llvm::TargetInstrInfo::reduceAccumulatorTree(llvm::SmallVectorImpl<llvm::Register>&, llvm::SmallVectorImpl<llvm::MachineInstr*>&, llvm::MachineFunction&, llvm::MachineInstr&, llvm::MachineRegisterInfo&, llvm::DenseMap<unsigned int, unsigned int>&, llvm::Register) const’
 void TargetInstrInfo::reduceAccumulatorTree(
      ^~~~~~~~~~~~~~~
/home/buildbots/llvm-external-buildbots/workers/ppc64le-clang-test-suite/clang-ppc64le-test-suite/llvm-project/llvm/lib/CodeGen/TargetInstrInfo.cpp:1017:6: note:   no known conversion for argument 6 from ‘llvm::DenseMap<llvm::Register, unsigned int>’ to ‘llvm::DenseMap<unsigned int, unsigned int>&’
30.443 [103/621/192] Building CXX object lib/Target/AVR/CMakeFiles/LLVMAVRCodeGen.dir/AVRSubtarget.cpp.o
30.480 [103/620/193] Building CXX object lib/Target/SystemZ/CMakeFiles/LLVMSystemZCodeGen.dir/SystemZSubtarget.cpp.o
30.535 [103/619/194] Building CXX object lib/Target/Sparc/CMakeFiles/LLVMSparcCodeGen.dir/SparcTargetMachine.cpp.o
30.621 [103/618/195] Building CXX object lib/Target/AMDGPU/CMakeFiles/LLVMAMDGPUCodeGen.dir/R600FrameLowering.cpp.o
30.669 [103/617/196] Building CXX object lib/Target/Sparc/CMakeFiles/LLVMSparcCodeGen.dir/SparcSubtarget.cpp.o
30.706 [103/616/197] Building CXX object lib/Target/AMDGPU/CMakeFiles/LLVMAMDGPUCodeGen.dir/R600ClauseMergePass.cpp.o
30.728 [103/615/198] Building CXX object lib/Target/AMDGPU/CMakeFiles/LLVMAMDGPUCodeGen.dir/R600EmitClauseMarkers.cpp.o
30.744 [103/614/199] Building CXX object lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/EarlyIfConversion.cpp.o
30.760 [103/613/200] Building CXX object lib/Target/Hexagon/CMakeFiles/LLVMHexagonCodeGen.dir/HexagonPeephole.cpp.o
30.817 [103/612/201] Building CXX object lib/Target/AVR/CMakeFiles/LLVMAVRCodeGen.dir/AVRExpandPseudoInsts.cpp.o
30.882 [103/611/202] Building CXX object lib/Target/Hexagon/CMakeFiles/LLVMHexagonCodeGen.dir/HexagonFixupHwLoops.cpp.o
30.929 [103/610/203] Building CXX object lib/Target/AVR/CMakeFiles/LLVMAVRCodeGen.dir/AVRTargetMachine.cpp.o
30.935 [103/609/204] Building CXX object lib/Target/AVR/CMakeFiles/LLVMAVRCodeGen.dir/AVRISelDAGToDAG.cpp.o
30.964 [103/608/205] Building CXX object lib/Target/WebAssembly/CMakeFiles/LLVMWebAssemblyCodeGen.dir/WebAssemblyFixBrTableDefaults.cpp.o
31.020 [103/607/206] Building CXX object lib/Target/Hexagon/CMakeFiles/LLVMHexagonCodeGen.dir/HexagonGenMux.cpp.o
31.024 [103/606/207] Building CXX object lib/Target/WebAssembly/CMakeFiles/LLVMWebAssemblyCodeGen.dir/WebAssemblyExplicitLocals.cpp.o
31.039 [103/605/208] Building CXX object lib/Target/Mips/CMakeFiles/LLVMMipsCodeGen.dir/MipsPreLegalizerCombiner.cpp.o
31.061 [103/604/209] Building CXX object lib/Target/ARM/CMakeFiles/LLVMARMCodeGen.dir/ARMBranchTargets.cpp.o
31.080 [103/603/210] Building CXX object lib/Target/WebAssembly/CMakeFiles/LLVMWebAssemblyCodeGen.dir/WebAssemblySelectionDAGInfo.cpp.o
31.106 [103/602/211] Building CXX object lib/Target/MSP430/CMakeFiles/LLVMMSP430CodeGen.dir/MSP430ISelDAGToDAG.cpp.o
31.111 [103/601/212] Building CXX object lib/Target/Sparc/CMakeFiles/LLVMSparcCodeGen.dir/DelaySlotFiller.cpp.o

```

</details>

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


More information about the llvm-commits mailing list