Also do its counterpart C - ctlz(X) => cttz(X) if C is bitwidth .
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Unit Tests
Event Timeline
Comment Actions
This is missing alive2 proofs.
Are there any tests where C is not the bit width? I didn't spot them.
Comment Actions
That, and it's off by one (the constant needs to be bitwidth-1, not bitwidth). The right transform would be this: https://alive2.llvm.org/ce/z/v588Fk
Comment Actions
Ok, it turns out I'm an idiot and the correct transformation is already done. Sorry everybody.