[PATCH] D29220: [InstCombine] Re-enable guard canonicalization for AND and NOT OR
Artur Pilipenko via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 31 00:41:48 PST 2017
apilipenko added inline comments.
================
Comment at: lib/Transforms/InstCombine/InstCombineCalls.cpp:3272-3279
+ unsigned NumArgs = II->getNumArgOperands();
+ std::vector<Value*> Args;
+ Args.reserve(NumArgs);
+
+ // Prepare args for guard(a).
+ Args.push_back(A);
+ for (unsigned I = 1; I < NumArgs; ++I)
----------------
```
SmallVector<Value *, 4> Args(CI->arg_begin(), CI->arg_end());
Args[0] = A;
```
And the same below.
https://reviews.llvm.org/D29220
More information about the llvm-commits
mailing list