Commit e0ca7ff3 authored by Simon Marlow's avatar Simon Marlow

Fix numa001 failure with "too many NUMA nodes"

It seems that recent versions of the Linux kernel are using larger NUMA
bitmasks; I see 1024 on my laptop running a 4.6.5 kernel.  This causes
the NUMA tests to fail.  I'm fixing it to only fail if we have that many
actual *nodes*, rather than failing if the size of the mask is too big.
parent 034e01e4
......@@ -585,8 +585,8 @@ StgWord osNumaMask(void)
struct bitmask *mask;
mask = numa_get_mems_allowed();
if (mask->size > sizeof(StgWord)*8) {
barf("Too many NUMA nodes");
if (osNumaNodes() > sizeof(StgWord)*8) {
barf("osNumaMask: too many NUMA nodes (%d)", osNumaNodes());
return mask->maskp[0];
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment