[DAGCombiner] Use getAnyExtOrTrunc instead of getSExtOrTrunc in the zext(setcc) combine.
authorCraig Topper <craig.topper@gmail.com>
Mon, 6 Apr 2020 05:35:01 +0000 (22:35 -0700)
committerCraig Topper <craig.topper@gmail.com>
Mon, 6 Apr 2020 05:44:45 +0000 (22:44 -0700)
commit97e57f3b24509efcadf83eb7436c044a2becd973
treedb9d0b2eba591f4ce3252bccc88719a8e6ef4c91
parent931c0cd713ee9b082389727bed1b518c6a44344f
[DAGCombiner] Use getAnyExtOrTrunc instead of getSExtOrTrunc in the zext(setcc) combine.

We're ANDing with 1 right after which will cause the SIGN_EXTEND to
be combined to ANY_EXTEND later. Might as well just start with an
ANY_EXTEND.

While there replace create the AND using the getZeroExtendInReg
helper to remove the need to explicitly create the VecOnes constant.
llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp