mirror of
https://github.com/ml-explore/mlx.git
synced 2025-10-22 19:28:14 +08:00
Fix leak with multi-output primitives (#1274)
* fix leak with multi-output primitives * hopefully an actual fix
This commit is contained in:
@@ -75,6 +75,9 @@ std::function<void()> make_task(array arr, bool signal) {
|
||||
if (!arr.is_tracer()) {
|
||||
arr.detach();
|
||||
}
|
||||
for (auto& out : outputs) {
|
||||
out.set_status(array::Status::available);
|
||||
}
|
||||
|
||||
if (signal || d.get_command_buffer_ops(s.index) >= MAX_OPS_PER_BUFFER) {
|
||||
d.end_encoding(s.index);
|
||||
|
Reference in New Issue
Block a user