Skip to content

Commit 12f3bb0

Browse files
authored
[Contrib] Update RandomFill to use StreamSync for CUDA synchronization (#18469)
1 parent 6dc71f3 commit 12f3bb0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/runtime/contrib/curand/curand.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ void RandomFill(DLTensor* tensor) {
110110
} else {
111111
LOG(FATAL) << "ValueError: Unsupported dtype: " << tensor->dtype;
112112
}
113-
TVMSynchronize(tensor->device.device_type, tensor->device.device_type, nullptr);
113+
cuda_api->StreamSync(tensor->device, nullptr);
114114
}
115115

116116
TVM_FFI_STATIC_INIT_BLOCK() {

0 commit comments

Comments
 (0)