[all-commits] [llvm/llvm-project] cf029a: [InstCombine] Add some more multi-use icmp gep fol...

Nikita Popov via All-commits all-commits at lists.llvm.org
Fri Dec 8 06:46:15 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: cf029a22bd0c87bb475ee0440e9085bb96c7e011
      https://github.com/llvm/llvm-project/commit/cf029a22bd0c87bb475ee0440e9085bb96c7e011
  Author: Nikita Popov <npopov at redhat.com>
  Date:   2023-12-08 (Fri, 08 Dec 2023)

  Changed paths:
    M llvm/test/Transforms/InstCombine/icmp-gep.ll

  Log Message:
  -----------
  [InstCombine] Add some more multi-use icmp gep folding tests (NFC)


  Commit: 4a2a6397f11da7c15a73d19fb1e6c9dcd1ceb5af
      https://github.com/llvm/llvm-project/commit/4a2a6397f11da7c15a73d19fb1e6c9dcd1ceb5af
  Author: Nikita Popov <npopov at redhat.com>
  Date:   2023-12-08 (Fri, 08 Dec 2023)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp
    M llvm/test/Transforms/InstCombine/icmp-gep.ll

  Log Message:
  -----------
  [InstCombine] Relax one-use check for icmp of gep fold

Instead of checking whether the GEP as a whole is constant, only
check whether it has constant incides. This matches what we do in
other places in this code.

This has little practical impact, because it is mostly already
handled through other cases anyway. We see a difference for
non-inbounds equality comparisons.


Compare: https://github.com/llvm/llvm-project/compare/8908296b62ee...4a2a6397f11d


More information about the All-commits mailing list