Commit 9ce3ba68 authored by Ben Gamari's avatar Ben Gamari 🐢 Committed by Marge Bot

rts: Fix --debug-numa mode under Docker

As noted in #17606, Docker disallows the get_mempolicy syscall by
default. This caused numerous tests to fail under CI in the `debug_numa`
way. Avoid this by disabling the NUMA probing logic when --debug-numa is
in use, instead setting n_numa_nodes in RtsFlags.c.

Fixes #17606.
parent fdeffa5e
Pipeline #14098 failed with stages
in 563 minutes and 39 seconds
......@@ -350,6 +350,8 @@ void initCapabilities (void)
for (i = 0; i < MAX_NUMA_NODES; i++) {
numa_map[i] = 0;
}
} else if (RtsFlags.DebugFlags.numa) {
// n_numa_nodes was set by RtsFlags.c
} else {
uint32_t nNodes = osNumaNodes();
if (nNodes > MAX_NUMA_NODES) {
......
......@@ -990,6 +990,7 @@ error = true;
RtsFlags.GcFlags.numa = true;
RtsFlags.DebugFlags.numa = true;
RtsFlags.GcFlags.numaMask = (1<<nNodes) - 1;
n_numa_nodes = nNodes;
}
}
#endif
......
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