csullivan commented on code in PR #15137:
URL: https://github.com/apache/tvm/pull/15137#discussion_r1266998446


##########
src/target/target_kind.cc:
##########
@@ -365,6 +365,11 @@ TVM_REGISTER_TARGET_KIND("opencl", kDLOpenCL)
     .add_attr_option<Integer>("max_num_threads", Integer(256))
     .add_attr_option<Integer>("thread_warp_size", Integer(1))
     .add_attr_option<Integer>("texture_spatial_limit", Integer(16384))
+    // Faced that Qualcomm OpenCL runtime was crashed without any error 
message in
+    // case when the number of kernel arguments was pretty big. OpenCL doesn't
+    // specify any limitations on the number of kernel arguments. 
max_function_args
+    // equals to 128 looks like a reasonable number of kernel arguments.
+    .add_attr_option<Integer>("max_function_args", Integer(128))

Review Comment:
   We discussed offline considering making this only the case for Adreno 
instead of any opencl. The issue is there appears to be a limitation in FuseOps 
exposed by this PR where the remainder of ops (mod max_function_args) not fused 
do not fuse together and remain individual primfuncs. @echuraev will follow up 
with an issue to track this exposed limitation of FuseOps. 



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