[PATCH] D156556: [AggressiveInstCombine] Fold strcmp eq, not eq operator improvements

Noah Goldstein via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 28 10:22:51 PDT 2023


goldstein.w.n added inline comments.


================
Comment at: llvm/lib/Transforms/AggressiveInstCombine/AggressiveInstCombine.cpp:1061
+      JoinPHIValue = CharacterSub;
+    }
+
----------------
Can you join the logic earlier? Imo Should be a forward declare value for the cmp result but the BR and BB propagation should be common codes.


================
Comment at: llvm/lib/Transforms/AggressiveInstCombine/AggressiveInstCombine.cpp:1090
+    for (User *U : CI->users()) {
+      U->replaceAllUsesWith(JoinPHI);
+    }
----------------
I don't really understand this, can you add a comment explaining this.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D156556



More information about the llvm-commits mailing list