Get up and running with Kimi, GLM, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models.
mlx: fix patch for recent mlx update (#18812)
Daniel Hiltgen8a971df3bace
diff --git a/mlx/compat/mlx/0001-metal-residency-refresh.patch b/mlx/compat/mlx/0001-metal-residency-refresh.patchindex 31e45b388..42ce52999 100644--- a/mlx/compat/mlx/0001-metal-residency-refresh.patch+++ b/mlx/compat/mlx/0001-metal-residency-refresh.patch@@ -11,7 +11,7 @@ diff --git a/mlx/backend/metal/resident.cpp b/mlx/backend/metal/resident.cpp#include <cstdio>#include <sstream>#include <stdexcept>-@@ -42,10 +43,38 @@+@@ -43,10 +44,38 @@}throw std::runtime_error(msg.str());}@@ -52,12 +52,12 @@ diff --git a/mlx/backend/metal/resident.cpp b/mlx/backend/metal/resident.cpp+ }+}- bool ResidencySets::add_set_locked(NS::Error** error_out) {+ bool ResidencySets::add_set_locked(std::string* error_out) {NS::SharedPtr<MTL::ResidencySet> set;diff --git a/mlx/backend/metal/resident.h b/mlx/backend/metal/resident.h--- a/mlx/backend/metal/resident.h+++ b/mlx/backend/metal/resident.h-@@ -1,10 +1,12 @@+@@ -1,11 +1,13 @@-// Copyright © 2024 Apple Inc.+// Copyright © 2024-2026 Apple Inc.@@ -67,11 +67,12 @@ diff --git a/mlx/backend/metal/resident.h b/mlx/backend/metal/resident.h+#include <condition_variable>#include <cstdint>#include <mutex>+ #include <string>+#include <thread>#include <unordered_map>#include <vector>-@@ -118,6 +120,9 @@+@@ -119,6 +121,9 @@// taking the lock.std::atomic<uint64_t> num_sets_{0};mutable std::mutex mtx_;