Skip to content

Commit f4a712f

Browse files
committed
ggml-virtgpu: make the remote calls thread-safe
1 parent 50df100 commit f4a712f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ggml/src/ggml-virtgpu/virtgpu.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -340,9 +340,9 @@ apir_encoder * remote_call_prepare(virtgpu * gpu, ApirCommandType apir_cmd_type,
340340
* Prepare the command encoder and its buffer
341341
*/
342342

343-
static char encoder_buffer[4096];
343+
thread_local char encoder_buffer[4096];
344344

345-
static apir_encoder enc;
345+
thread_local apir_encoder enc;
346346
enc = {
347347
.cur = encoder_buffer,
348348
.start = encoder_buffer,

0 commit comments

Comments
 (0)