[PATCH] D134183: [WIP][RegCoalescer][TwoAddrInst] Keep undef subreg copies that are used in early-clobber insts

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 19 07:45:00 PDT 2022


arsenm added a comment.

This should be two separate patches and needs MIR tests for each



================
Comment at: llvm/lib/CodeGen/RegisterCoalescer.cpp:1662
+  if (DstSubIdx) {
+    for (const MachineInstr &Use : MRI->use_nodbg_instructions(DstReg)) {
+      for (const MachineOperand &Def : Use.defs()) {
----------------
My initial thought is you shouldn't have to scan over all use instructions to avoid this and you can query the range and check for EC slots


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D134183/new/

https://reviews.llvm.org/D134183



More information about the llvm-commits mailing list