[all-commits] [llvm/llvm-project] e6cd15: [InstCombine] add tests for logical select; NFC

RotateRight via All-commits all-commits at lists.llvm.org
Tue Nov 23 07:05:10 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e6cd157407a24f7be1c15dbf949bac98400ff96d
      https://github.com/llvm/llvm-project/commit/e6cd157407a24f7be1c15dbf949bac98400ff96d
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2021-11-23 (Tue, 23 Nov 2021)

  Changed paths:
    M llvm/test/Transforms/InstCombine/logical-select.ll

  Log Message:
  -----------
  [InstCombine] add tests for logical select; NFC


  Commit: 430ad9697d143b4c408acf0d0d01c17830ac2bb3
      https://github.com/llvm/llvm-project/commit/430ad9697d143b4c408acf0d0d01c17830ac2bb3
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2021-11-23 (Tue, 23 Nov 2021)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
    M llvm/test/Transforms/InstCombine/logical-select.ll

  Log Message:
  -----------
  [InstCombine] enhance bitwise select matching

I noticed that adding a seemingly unrelated fold for xor caused
regressions on similar patterns, and this is one of the
underlying causes.

This could also be a variation for code as seen in:
https://llvm.org/PR34047
...although that exact example should be fixed after:
D113035 / c36b7e21bd8f

The vector test shows that we are actually missing a potential
canonicalization for bitcast-of-sext-of-not or the inverse.
The scalar test shows that even if we had that canonicalization,
it would still be possible to see this pattern due to extra uses.

https://alive2.llvm.org/ce/z/y2BAgi


Compare: https://github.com/llvm/llvm-project/compare/13fa4fcfe70e...430ad9697d14


More information about the All-commits mailing list