[llvm] ValueTracking: simplify udiv/urem recurrences (PR #108973)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 7 11:28:19 PDT 2024
================
@@ -8997,12 +9012,14 @@ bool llvm::matchSimpleRecurrence(const PHINode *P, BinaryOperator *&BO,
switch (Opcode) {
default:
continue;
- // TODO: Expand list -- xor, div, gep, uaddo, etc..
+ // TODO: Expand list -- sdiv, srem, fadd etc.
----------------
goldsteinn wrote:
> * I can't think of a possible recurrence with xor.
>
Isn't that also true for `sdiv`/`srem`?
> * GEP isn't a BinaryOperator, is it? What possible recurrences are possible?
>
If it matches `ptradd` probably.
> * I can't find uaddo in the LangRef, and don't know what it is.
Probably uadd_sat.
https://github.com/llvm/llvm-project/pull/108973
More information about the llvm-commits
mailing list