masahi commented on code in PR #11478:
URL: https://github.com/apache/tvm/pull/11478#discussion_r883108535
##########
src/runtime/cuda/cuda_module.cc:
##########
@@ -164,11 +164,18 @@ class CUDAWrappedFunc {
void operator()(TVMArgs args, TVMRetValue* rv, void** void_args) const {
int device_id;
CUDA_CALL(cudaGetDevice(&device_id));
+ ThreadWorkLoad wl = launch_param_config_.Extract(args);
+
if (fcache_[device_id] == nullptr) {
fcache_[device_id] = m_->GetFunc(device_id, func_name_);
+ if (wl.dyn_shmem_size >= (48 << 10)) {
Review Comment:
Haven't tested but yeah, it seems `VerifyGPUCode` checks the static alloc
size against `max_shared_memory_per_block`, which would fail if `dyn_shmem_size
>= (48 << 10)`
https://github.com/apache/tvm/blob/534205baba2a3e71bc0613824e62cb625677f3e0/src/tir/analysis/verify_gpu_code.cc#L70-L71
--
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]