[all-commits] [llvm/llvm-project] 7d850a: [InstCombine] Make indexed compare fold opaque ptr...

Nikita Popov via All-commits all-commits at lists.llvm.org
Tue Dec 28 02:47:36 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7d850a0c4d26591fadb26d82a8ffac530c217e9c
      https://github.com/llvm/llvm-project/commit/7d850a0c4d26591fadb26d82a8ffac530c217e9c
  Author: Nikita Popov <nikita.ppv at gmail.com>
  Date:   2021-12-28 (Tue, 28 Dec 2021)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp
    M llvm/test/Transforms/InstCombine/indexed-gep-compares.ll
    M llvm/test/Transforms/InstCombine/opaque-ptr.ll

  Log Message:
  -----------
  [InstCombine] Make indexed compare fold opaque ptr compatible

We need to make sure that the GEP source element types match.

A caveat here is that the used GEP source element type can be
arbitrary if no offset is stripped from the original GEP -- the
transform is somewhat inconsistent in that it always starts from
a GEP, but might not actually look through it if it has multiple
indices.




More information about the All-commits mailing list