You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/05/23 13:24:55 UTC

[GitHub] [tvm] tqchen commented on a diff in pull request #11323: [Arith][BoundDeducer] Forbid non-supported expr type in bound deducer

tqchen commented on code in PR #11323:
URL: https://github.com/apache/tvm/pull/11323#discussion_r879453446


##########
src/arith/bound_deducer.cc:
##########
@@ -85,21 +85,24 @@ class BoundDeducer : public ExprVisitor {
   void VisitExpr(const PrimExpr& e) final {
     if (!success_) return;
     if (iter_ < path_.size() && e.get() == path_[iter_++]) {
-      ExprVisitor::VisitExpr(e);
+      if (const AddNode* op = e.as<AddNode>()) {

Review Comment:
   Manually expansion here is not as effective as number of Expr grows. I know that it is a bit hard to hit to default case. Another way would be to simply use ExprFunctor(which defaults to failure) then dispatch again.



-- 
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