[llvm] [DAGCombiner] Attempt to fold 'add' nodes to funnel-shift or rotate (PR #125612)

Craig Topper via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 18 11:53:45 PST 2025


topperc wrote:

Can we update comments to show the `add` cases too? For example,

```
  // fold (or (shl x, (*ext y)),                                                 
  //          (srl x, (*ext (sub 32, y)))) ->                                    
  //   (rotl x, y) or (rotr x, (sub 32, y))
```

https://github.com/llvm/llvm-project/pull/125612


More information about the llvm-commits mailing list