[DAGCombiner] clean up visitEXTRACT_VECTOR_ELT
authorSanjay Patel <spatel@rotateright.com>
Fri, 14 Dec 2018 00:09:08 +0000 (00:09 +0000)
committerSanjay Patel <spatel@rotateright.com>
Fri, 14 Dec 2018 00:09:08 +0000 (00:09 +0000)
commit093ab45d4c8adff54a27ead5871f8a54706a3e08
treead520a6009243456d7faea643f9f20c396957e7f
parent178abc59acd1eef9b0a14462da99ca4595241945
[DAGCombiner] clean up visitEXTRACT_VECTOR_ELT

This isn't quite NFC, but I don't know how to expose
any outward diffs from these changes. Mostly, this
was confusing because it used 'VT' to refer to the
operand type rather the usual type of the input node.

There's also a large block at the end that is dedicated
solely to matching loads, but that wasn't obvious. This
could probably be split up into separate functions to
make it easier to see.

It's still not clear to me when we make certain transforms
because the legality and constant conditions are
intertwined in a way that might be improved.

llvm-svn: 349095
llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp