[all-commits] [llvm/llvm-project] 036a13: [GlobalISel] Combine (X op Y) == X --> Y == 0
Jessica Paquette via All-commits
all-commits at lists.llvm.org
Tue Oct 11 09:53:18 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 036a13065b7a744efcc48cdc0bca3b878ed906fd
https://github.com/llvm/llvm-project/commit/036a13065b7a744efcc48cdc0bca3b878ed906fd
Author: Jessica Paquette <jpaquette at apple.com>
Date: 2022-10-11 (Tue, 11 Oct 2022)
Changed paths:
M llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h
M llvm/include/llvm/Target/GlobalISel/Combine.td
M llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
A llvm/test/CodeGen/AArch64/GlobalISel/combine-icmp-of-binop-to-icmp-of-0.mir
Log Message:
-----------
[GlobalISel] Combine (X op Y) == X --> Y == 0
This matches patterns of the form
```
(X op Y) == X
```
And transforms them to
```
Y == 0
```
where appropriate.
Example: https://godbolt.org/z/hfW811c7W
Differential Revision: https://reviews.llvm.org/D135380
More information about the All-commits
mailing list