[PATCH] D29926: [SelectionDAGBuilder] Simplify creation of shufflevector DAG nodes where inputs are larger than the mask

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 13 22:08:19 PST 2017


craig.topper created this revision.

The current code loops over all elements to calculate a used range. Then a second short loop looks at the ranges and determines if they can be used in a extract and creates a properly aligned start index for the extract.

This range finding is unnecessary, we can just calculate a properly aligned start index for an extract for each input during the first loop. If we don't find the same start index for each indice we can't use an extract.


https://reviews.llvm.org/D29926

Files:
  lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D29926.88306.patch
Type: text/x-patch
Size: 4278 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170214/73eaeb6b/attachment.bin>


More information about the llvm-commits mailing list