[Bugfix] Fix CPU OMP autobind assertion to use local_world_size (#35815)
Signed-off-by: liweiguang <codingpunk@gmail.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com> Co-authored-by: Li, Jiang <jiang1.li@intel.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
Li, Jiang <jiang1.li@intel.com>
parent
384425f84e
commit
43aa389231
@@ -144,12 +144,10 @@ class CPUWorker(Worker):
|
|||||||
allowed_numa_nodes, logical_cpu_list = (
|
allowed_numa_nodes, logical_cpu_list = (
|
||||||
CpuPlatform.get_allowed_cpu_core_node_list()
|
CpuPlatform.get_allowed_cpu_core_node_list()
|
||||||
)
|
)
|
||||||
assert (
|
local_world_size = self.parallel_config.local_world_size
|
||||||
len(allowed_numa_nodes) >= self.parallel_config.world_size
|
assert len(allowed_numa_nodes) >= local_world_size or sim_multi_numa_nodes, (
|
||||||
or sim_multi_numa_nodes
|
|
||||||
), (
|
|
||||||
f"Not enough allowed NUMA nodes to bind threads of "
|
f"Not enough allowed NUMA nodes to bind threads of "
|
||||||
f"{self.parallel_config.world_size} CPUWorkers. "
|
f"{local_world_size} local CPUWorkers. "
|
||||||
f"Allowed NUMA nodes are {allowed_numa_nodes}. "
|
f"Allowed NUMA nodes are {allowed_numa_nodes}. "
|
||||||
"Please try to bind threads manually."
|
"Please try to bind threads manually."
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user