metal : faster argsort (#17315)

* metal : faster argsort

* cont : keep data in registers
This commit is contained in:
Georgi Gerganov
2025-11-17 11:51:48 +02:00
committed by GitHub
parent 1a139644a8
commit 3347e6d904
2 changed files with 87 additions and 41 deletions
-2
View File
@@ -3726,8 +3726,6 @@ int ggml_metal_op_argsort(ggml_metal_op_t ctx, int idx) {
ggml_metal_encoder_set_buffer (enc, bid_dst, 2);
ggml_metal_encoder_set_buffer (enc, bid_tmp, 3);
ggml_metal_encoder_set_threadgroup_memory_size(enc, 0, 0);
ggml_metal_encoder_dispatch_threadgroups(enc, nm*ne01, ne02, ne03, nth, 1, 1);
std::swap(bid_dst, bid_tmp);