Skip to content

ggml.c: error: 'SYS_getcpu' undeclared did you mean 'SYS_get_cpu' #1894

@themanyone

Description

@themanyone

On both projects, whisper.cpp, and llama.cpp, we get this compilation error with latest git when compiling with CUBLAS.

WHISPER_CUBLAS=1 make -j

ggml.c: In function 'ggml_numa_init':
ggml.c:2088:26: error: 'SYS_getcpu' undeclared (first use in this function); did you mean 'SYS_get_cpu'?
 2088 |     getcpu_ret = syscall(SYS_getcpu,&current_cpu,&g_state.numa.current_node);
      |                          ^~~~~~~~~~
      |                          SYS_get_cpu
ggml.c:2088:26: note: each undeclared identifier is reported only once for each function it appears in
make: *** [Makefile:317: ggml.o] Error 1

The fix is very straightforward. We simply drop in SYS_get_cpu.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions