giuseros commented on a change in pull request #7132:
URL: https://github.com/apache/tvm/pull/7132#discussion_r546591992



##########
File path: python/tvm/topi/nn/conv2d.py
##########
@@ -382,7 +382,15 @@ def conv2d_nhwc(
     if auto_scheduler_rewritten_layout:
         # Infer shape for the rewritten layout
         # todo(merrymercy): wrap this with a more general interface.
-        if len(Filter.shape) >= 10:
+        if len(Filter.shape) == 17:

Review comment:
       Could you maybe add some comments about the constants?

##########
File path: python/tvm/topi/mali/conv2d.py
##########
@@ -545,6 +577,19 @@ def _alter_conv2d_layout(attrs, inputs, tinfos, out_type):
         return None
 
 
+@conv2d_winograd_nhwc.register(["mali"])
+def conv2d_winograd_nhwc_cuda(

Review comment:
       Should this be called `conv2d_winograd_nhwc_mali`?

##########
File path: src/auto_scheduler/search_task.cc
##########
@@ -90,6 +90,22 @@ HardwareParams 
HardwareParamsNode::GetDefaultHardwareParams(const Target& target
     int max_vthread_extent = warp_size / 4;
     return HardwareParams(-1, 16, 64, max_shared_memory_per_block, 
max_local_memory_per_block,
                           max_threads_per_block, max_vthread_extent, 
warp_size);
+  } else if (target->kind->device_type == kDLOpenCL) {
+    if (target->GetAttr<String>("device", "") == "mali") {
+      // We can not use device api to get attr like CUDA
+      // because like Mali target is normally on the remote machine
+      int max_shared_memory_per_block = 32768;
+      int max_local_memory_per_block = INT32_MAX;  // skip the check on local 
memory
+      int max_threads_per_block = 256;
+      int warp_size = 1;
+      int max_vthread_extent = 1;
+      return HardwareParams(-1, 16, 64, max_shared_memory_per_block, 
max_local_memory_per_block,
+                            max_threads_per_block, max_vthread_extent, 
warp_size);

Review comment:
       Is this referring to a specific target? Either way, could add a bit more 
explanation about the constants? 




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