[InstCombine] Support vectors in icmp of GEP fold
authorNikita Popov <npopov@redhat.com>
Mon, 2 Jan 2023 14:28:10 +0000 (15:28 +0100)
committerNikita Popov <npopov@redhat.com>
Mon, 2 Jan 2023 14:29:13 +0000 (15:29 +0100)
commit81ac46445b640ad48158ab84065858c873bc5b74
treec673e438dbc5984ede09f89f5493b43df06c1a93
parenta21458c7b0b9b51cd37bd87d083c7f239544304c
[InstCombine] Support vectors in icmp of GEP fold

EmitGEPOffset() supports vector GEPs nowadays, so we don't need
any further code changes.

compare_gep_with_base_vector1 shows a weakness in folding the
resulting comparison if an index splat has to be performed.
llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp
llvm/test/Transforms/InstCombine/opaque-ptr.ll