Przeglądaj źródła

Merge pull request #9824 from ollama/mxyng/sched

conditionally enable parallel pipelines
Michael Yang 1 miesiąc temu
rodzic
commit
021dcf089d
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      ml/backend/ggml/ggml.go

+ 1 - 1
ml/backend/ggml/ggml.go

@@ -373,7 +373,7 @@ func New(r *os.File, params ml.BackendParams) (ml.Backend, error) {
 			(*C.ggml_backend_buffer_type_t)(unsafe.Pointer(&schedBufts[0])),
 			C.int(len(schedBackends)),
 			C.size_t(maxGraphNodes),
-			true,
+			C._Bool(len(gpus) > 1 && slices.Contains(gpus, output.d)),
 		),
 		input:  deviceBufferTypes[input.d],
 		output: deviceBufferTypes[output.d],