[PATCH] D62546: [FPEnv] Added a special UnrollVectorOp method to deal with the chain on StrictFP opcodes
Andrew J Wock via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu May 30 06:17:31 PDT 2019
ajwock added inline comments.
================
Comment at: lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp:1341
+ unsigned i;
+ for (i= 0; i != NE; ++i) {
+ Operands[0] = Chain;
----------------
cameron.mcinally wrote:
> Missing a space in `i = 0`.
Updating the diff to include the space.
================
Comment at: lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp:1343
+ Operands[0] = Chain;
+ for (unsigned j = 1, e = N->getNumOperands(); j != e; ++j) {
+ SDValue Operand = N->getOperand(j);
----------------
cameron.mcinally wrote:
> What's the purpose of `e` here? Why not:
>
> `for (unsigned j = 1, j != N->getNumOperands(); ++j) {`
>
> Is it just saving an accessor call?
Yes, this is just some strength reduction. The looping structure was borrowed from SelectionDAG::UnrollVectorOp.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D62546/new/
https://reviews.llvm.org/D62546
More information about the llvm-commits
mailing list