[PATCH] D105098: [DSE][NFC] Introduce "doesn't overwrite" return code for isOverwrite

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 6 03:56:17 PDT 2021


fhahn added a comment.

Looks good in general, but I couldn't find a use in the linked patches. Could you update the description with more details about the motivation, when/how this will be used.



================
Comment at: llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp:1457
                               DepWriteOffset, InstWriteOffset);
         // If Current does not write to the same object as KillingDef, check
         // the next candidate.
----------------
The comment here seems slightly inaccurate and I think it is more obvious after this change; we skip if we can't prove that there is a (partial) overwrite. Might be good to adjust the comment.


================
Comment at: llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp:1468
             WalkerStepLimit -= 1;
+            LLVM_DEBUG(dbgs() << "   ... reached partial limit ... continue with next access\n");
             continue;
----------------
This seems unrelated to the patch?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105098



More information about the llvm-commits mailing list