On Ubuntu 12.10 x64 (a fairly recent version), after installing libnuma-dev, I am getting this error building Crafty 23.5 using the linux-amd64 target:
main.c:4027:5: error: too many arguments to function ‘numa_node_to_cpus’
The man page for numa_node_to_cpus says it is declared like this:
int numa_node_to_cpus(int node, struct bitmask *mask);
but this does not match the signature in the code.
--Jon
Crafty 23.5 NUMA compile issue
Moderators: hgm, Dann Corbit, Harvey Williamson
-
jdart
- Posts: 4361
- Joined: Fri Mar 10, 2006 5:23 am
- Location: http://www.arasanchess.org
-
Sven
- Posts: 4052
- Joined: Thu May 15, 2008 9:57 pm
- Location: Berlin, Germany
- Full name: Sven Schüle
Re: Crafty 23.5 NUMA compile issue
There are different NUMA API versions around. Crafty supports v1 while recent installations implement v2. I don't know whether it is possible to determine the correct API version at runtime, maybe with dlopen()/dlsym()? For v2, in order to determine the number of CPUs of a node you need to allocate a bitmask structure first, then call the function above, then query the CPU count from the bitmask struct, and finally free the structure if it was allocated on the heap.jdart wrote:On Ubuntu 12.10 x64 (a fairly recent version), after installing libnuma-dev, I am getting this error building Crafty 23.5 using the linux-amd64 target:
main.c:4027:5: error: too many arguments to function ‘numa_node_to_cpus’
The man page for numa_node_to_cpus says it is declared like this:
int numa_node_to_cpus(int node, struct bitmask *mask);
but this does not match the signature in the code.
--Jon
Sven
-
bob
- Posts: 20943
- Joined: Mon Feb 27, 2006 7:30 pm
- Location: Birmingham, AL
Re: Crafty 23.5 NUMA compile issue
I'll take a look. I've not compiled and run on a NUMA box recently, it is possible/likely that the library has changed a bit...jdart wrote:On Ubuntu 12.10 x64 (a fairly recent version), after installing libnuma-dev, I am getting this error building Crafty 23.5 using the linux-amd64 target:
main.c:4027:5: error: too many arguments to function ‘numa_node_to_cpus’
The man page for numa_node_to_cpus says it is declared like this:
int numa_node_to_cpus(int node, struct bitmask *mask);
but this does not match the signature in the code.
--Jon