[llvm] [GlobalIsel] Visit ICmp (PR #105991)
Thorsten Schütt via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 10 09:16:42 PDT 2024
tschuett wrote:
I may be blind, but I couldn't find any requests for known bits in visitICmp. matchCmpOfZero has requests for known bits. It is the icmp x, 0 C++ part.
In the AMDGPU tests, there are many hits of the icmp x, 0 combine. In many case, I could find something like, e.g.,
`v_cmp_eq_u32_e64 s[4:5], 0, v5` . To me it reads like an icmp with a zero on the left hand side.
If you ask me to split the canonicalization of constants on icmps to the right and the icmp x, 0 combine into two PRs, then both PRs are not profitable.
There is exactly one combine, which relies on known bits. The icmp x, 0 combine, which has a precise MIR pattern.
https://github.com/llvm/llvm-project/pull/105991
More information about the llvm-commits
mailing list