Lower icmp operations between vector values.
SSE2 only has signed integer comparison. Unsigned compares are
implemented by inverting the sign bits of the operands and doing a
signed compare.
A common pattern in clang generated IR is a vector compare which
generates an i1 vector followed by a sign extension of the result of the
compare. The x86 comparison instructions already generate sign extended
values, so we can eliminate unnecessary sext operations that follow
compares in the IR.
BUG=none
R=jvoung@chromium.org, stichnot@chromium.org
Review URL: https://codereview.chromium.org/412593002
Showing
crosstest/test_icmp_i1vec.ll
0 → 100644
tests_lit/llvm2ice_tests/vector-icmp.ll
0 → 100644
This diff is collapsed.
Click to expand it.
Please
register
or
sign in
to comment