mit-han-lab / torchsparse

[MICRO'23, MLSys'22] TorchSparse: Efficient Training and Inference Framework for Sparse Convolution on GPUs.
https://torchsparse.mit.edu
MIT License
1.22k stars 143 forks source link

fix illegal memory access error #312

Open dingfengshi opened 4 months ago

dingfengshi commented 4 months ago

In some cases (such as when there are a large number of points), executing convolution operations can result in illegal memory access errors. The reason is that the kernel responsible for computing the kmap has not completed execution before launching the next operation, leading to unpredictable memory access. To address this issue, an additional synchronization step is added to wait for the previous kernel to finish. This ensures that the next operation does not start until the preceding kernel has completed.