tkonolige commented on a change in pull request #7148:
URL: https://github.com/apache/tvm/pull/7148#discussion_r547395050



##########
File path: python/tvm/topi/cuda/sparse.py
##########
@@ -311,6 +339,8 @@ def sparse_dense_padded(data, weight_data, weight_indices, 
weight_indptr):
     output : tvm.te.Tensor
         2-D with shape [M, N]
     """
+    # TODO(ANSHUMAN87): Handle for sparse_lhs case too
+    assert not sparse_lhs

Review comment:
       Can you add a message to this one.

##########
File path: python/tvm/topi/x86/sparse.py
##########
@@ -28,15 +28,17 @@ def schedule_sparse_dense(outs):
 
     def _callback(op):
         simd_width = get_fp32_len()
-        if op.tag == "sparse_dense_csrmm" and op != outs[0].op:
-            (_, v_i) = s[op].op.axis
-            s[op].vectorize(v_i)
-            (y_o, y_i) = s[outs[0].op].split(s[outs[0].op].op.axis[1], 2 * 
simd_width)
-            s[op].compute_at(s[outs[0]], y_o)
-            s[outs[0].op].vectorize(y_i)
-        if op.tag == "sparse_dense_bsrmm":
+        if op.tag == "sparse_dense_csrmm_v2" or op.tag == 
"sparse_dense_csrmm_v1":
+            (y_o, y_i) = s[op].split(s[op].op.axis[1], 2)
+            fused = s[op].fuse(s[op].op.axis[0], y_o)
+            s[op].parallel(fused)
+            s[op].vectorize(y_i)
+        elif op.tag == "sparse_dense_bsrmm_v2" or op.tag == 
"sparse_dense_bsrmm_v1":

Review comment:
       What is the difference between v1 and v2? Can we consolidate tags? If 
not, maybe we should rename them to be more clear about what they are doing.




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

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


Reply via email to