Lunderberg commented on code in PR #13936:
URL: https://github.com/apache/tvm/pull/13936#discussion_r1124977881


##########
src/arith/rewrite_simplify.cc:
##########
@@ -454,6 +460,14 @@ PrimExpr RewriteSimplifier::Impl::VisitExpr_(const 
SubNode* op) {
     TVM_TRY_REWRITE_IF(floordiv(x - y, c1) * c1 - x, 0 - floormod(x - y, c1) - 
y,
                        c1.Eval()->value != 0);
 
+    TVM_TRY_RECURSIVE_REWRITE(
+        floordiv(x + c1, 2) - floordiv(x + c2, 2),
+        floormod(x, 2) * (floormod(c1, 2) - floormod(c2, 2)) + floordiv(c1, 2) 
- floordiv(c2, 2));

Review Comment:
   Can do, and thank you for the catch!



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to