MasterJH5574 opened a new pull request #10498:
URL: https://github.com/apache/tvm/pull/10498


   This PR fixes the way of comparison in which the tensorization IR-comparator 
deals with annotations.
   
   Prior to this PR, the comparator requires the annotation values from LHS and 
RHS to be exactly the same, which is, in fact, never possible. And this PR 
removes this comparison requirement (with a regression unit test).
   
   ```c++
   bool TensorizeComparator::CompareAnnotation(const std::pair<String, 
ObjectRef>& lhs,
                                               const std::pair<String, 
ObjectRef>& rhs) {
     if (lhs.first != rhs.first) return false;
     if (!lhs.second.same_as(rhs.second)) return false;  // <== The values 
would never be the same.
                                                         //     Thus this line 
should be removed.
     return VisitExpr(Downcast<PrimExpr>(lhs.second), 
Downcast<PrimExpr>(rhs.second));
   }
   ```
   
   cc @spectrometerHBH @vinx13 


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