You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
InstCombine optimizes one of them very well. The other one not so much. Unfortunately I don't have the terminology to describe what's going on better than pointing to that link. Maybe someone else could help me out.
The text was updated successfully, but these errors were encountered:
cc @rotateright Looks like another issue with missing trunc vs and canonicalization for icmps?
Yes, I think the fold itself is easy: https://alive2.llvm.org/ce/z/umK_t-
...but it can interfere with other pattern-matching, and we likely have conflicting folds (infinite loop potential) buried in there, so we probably have to untangle some other transforms.
I looked at this, and it's probably better to try the reverse of what I posted above: https://alive2.llvm.org/ce/z/ZQZ9zb
(create a mask op instead of truncating)
...because we already do that for equality predicates, and that works for unsigned preds too.
But then we hit another problem because we chop off the low bit of the mask in the example shown here:
Two nearly identical functions
InstCombine
optimizes one of them very well. The other one not so much. Unfortunately I don't have the terminology to describe what's going on better than pointing to that link. Maybe someone else could help me out.The text was updated successfully, but these errors were encountered: