[PATCH] D152502: [MCP] Do not remove redundant copy for COPY from undef

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 9 04:42:46 PDT 2023


arsenm added inline comments.


================
Comment at: llvm/lib/CodeGen/MachineCopyPropagation.cpp:466
+  if (PrevCopyOperands->Destination->isDead() ||
+      PrevCopyOperands->Source->isUndef())
     return false;
----------------
Instead of not doing the fold, can you just strip the undef from the first copy?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D152502



More information about the llvm-commits mailing list