[llvm] [Offload] Don't create events for empty queues (PR #152304)

Callum Fare via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 6 06:16:00 PDT 2025


================
@@ -916,6 +916,11 @@ struct CUDADeviceTy : public GenericDeviceTy {
     return Plugin::check(Res, "error in cuStreamWaitEvent: %s");
   }
 
+  // TODO: This should be implementable on CUDA
+  Expected<bool> hasPendingWorkImpl(AsyncInfoWrapperTy &AsyncInfo) override {
+    return true;
----------------
callumfare wrote:

`cuStreamQuery` should do it, I can implement and test it in a follow up PR if you'd like

https://github.com/llvm/llvm-project/pull/152304


More information about the llvm-commits mailing list