[PATCH] D47423: Simplify recursive launder.invariant.group and strip

Krzysztof Pszeniczny via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun May 27 09:40:23 PDT 2018


amharc added a comment.

Otherwise looks good to me. Obviously, you should wait for someone more competent than me to approve it ;)



================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp:1212
+    II.getArgOperand(0)->stripPointerCastsAndInvariantGroups();
+  auto *StrippedArg = II.getOperand(0)->stripPointerCasts();
+  if (StrippedInvariantGroupsArg == StrippedArg)
----------------
nit: you use `II.getArgOperand(0)` in the line above and `II.getOperand(0)` here. Those are obviously equivalent, but maybe stick to one of those (possibly extracting it into `auto *Arg = II.getArgOperand(0);`)?


Repository:
  rL LLVM

https://reviews.llvm.org/D47423





More information about the llvm-commits mailing list