jameysharp opened PR #5724 from opts-reuse-lhs
to main
:
We don't need to spend time going through the GVN map to dedup a newly-constructed
iconst 0
when we already matched that value on the left-hand side of these rules.Also, mark these rules as subsuming any others since we can't do better than reducing an expression to a constant.
jameysharp requested elliottt for a review on PR #5724.
alexcrichton submitted PR review.
alexcrichton created PR review comment:
Drive-by question not related to this actual PR, is this rule necessary given this rule that moves constants to the right?
jameysharp submitted PR review.
jameysharp created PR review comment:
Great question. I believe you're right that this rule is not necessary since we have that one. I'm not going to delete it right now though while we're still thinking through how best to express rules involving commutative operators. Chris, Nick, Trevor, and I had a long chat on the subject earlier today, but we don't have a complete plan yet.
elliottt submitted PR review.
jameysharp has enabled auto merge for PR #5724.
jameysharp has disabled auto merge for PR #5724.
jameysharp closed without merge PR #5724.
jameysharp reopened PR #5724 from opts-reuse-lhs
to main
.
jameysharp has enabled auto merge for PR #5724.
jameysharp merged PR #5724.
Last updated: Dec 23 2024 at 12:05 UTC