[x86] limit extractelement of setcc to pre-legalization
authorSanjay Patel <spatel@rotateright.com>
Wed, 13 Mar 2019 14:49:52 +0000 (14:49 +0000)
committerSanjay Patel <spatel@rotateright.com>
Wed, 13 Mar 2019 14:49:52 +0000 (14:49 +0000)
commit0a251e4076ac0c095435e4c2f7dcecbfa2e0bc5c
tree68f71ca5221f9c207c8b34b1ed444d56bfe6cc29
parent9bfd140ddb82331dafddf14f09c2e4ab0217addf
[x86] limit extractelement of setcc to pre-legalization

A fuzzer found the crasher:
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=13700

The bug was introduced recently here:
rL355741

This is the quick fix. If we need to do this transform
later, then we'd have to extend/truncate the vector setcc
element type to the scalar setcc type (i8).

llvm-svn: 356053
llvm/lib/Target/X86/X86ISelLowering.cpp
llvm/test/CodeGen/X86/extractelement-fp.ll