[SDAG] allow cast folding for vector sext-of-setcc with signed compare
authorSanjay Patel <spatel@rotateright.com>
Wed, 2 Jun 2021 19:01:04 +0000 (15:01 -0400)
committerSanjay Patel <spatel@rotateright.com>
Wed, 2 Jun 2021 19:05:02 +0000 (15:05 -0400)
commit0718ac706d4df719a0f019d1c0c3050c96ac2b8b
treeab947fb0884f91e553966e4a9a25df68a29e6fac
parent595b1683b79be089c3f72e7b3dcee4d1a9f6327b
[SDAG] allow cast folding for vector sext-of-setcc with signed compare

This extends 434c8e013a2c and ede3982792df to handle signed
predicates by sign-extending the setcc operands.

This is not shown directly in https://llvm.org/PR50055 ,
but the pattern is visible by changing the unsigned convert
to signed in the source code.
llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
llvm/test/CodeGen/X86/sext-vsetcc.ll