We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cfd9ad6 commit 90b93f5Copy full SHA for 90b93f5
arrayjit/lib/cuda_backend.cudajit.ml
@@ -162,7 +162,7 @@ let finalize ctx =
162
Map.iteri ctx.global_arrays ~f:(fun ~key ~data:ptr ->
163
if not @@ Option.exists ctx.parent ~f:(fun pc -> Map.mem pc.global_arrays key) then
164
Cudajit.mem_free ptr);
165
- Cudajit.stream_destroy ctx.device.stream)
+ if Option.is_none ctx.parent then Cudajit.stream_destroy ctx.device.stream)
166
167
let init device =
168
let ctx =
0 commit comments