You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by "Lunderberg (via GitHub)" <gi...@apache.org> on 2023/03/03 20:43:06 UTC

[GitHub] [tvm] Lunderberg commented on pull request #13936: [Arith] Simplifications for floormod(x, 2)

Lunderberg commented on PR #13936:
URL: https://github.com/apache/tvm/pull/13936#issuecomment-1454103099

   Thank you for the review, @wrongtest-intellif , and everything should be updated now.
   
   Regarding cases where it can fail to cancel, that definitely can occur.  I have some work on a local branch where I've been trying to make the rewrite rules more general (and to reduce duplication as a benefit), but at the moment it slows down the RewriteSimplifier by about 10x.
   
   One thing that I think could help would be to enforce an ordering between terms for any commutative and associative operator.  For example, right now `(x + y)//4 - (y + x)//4` doesn't cancel out, because the numerators are different.  Sorting by the variable(s) used by each term would at least move related terms together, making it more likely that they'd cancel out.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org