"vscode:/vscode.git/clone" did not exist on "9d4183dd2e751e94442d7f02966d33cc085de708"
Unverified Commit 3322e264 authored by Li, Jiang's avatar Li, Jiang Committed by GitHub
Browse files

[Bugfix] Avoid more OpenMP thread reallocation in CPU torch compile (#37538)


Signed-off-by: default avatarjiang1.li <jiang1.li@intel.com>
parent 765e4610
...@@ -281,6 +281,9 @@ class CpuPlatform(Platform): ...@@ -281,6 +281,9 @@ class CpuPlatform(Platform):
# Disable multi-stream for shared experts as no Stream on CPU # Disable multi-stream for shared experts as no Stream on CPU
os.environ["VLLM_DISABLE_SHARED_EXPERTS_STREAM"] = "1" os.environ["VLLM_DISABLE_SHARED_EXPERTS_STREAM"] = "1"
# Avoid inductor generates num_thread() and breaks the thread binding
os.environ["TORCHINDUCTOR_CPP_DYNAMIC_THREADS"] = "1"
# Intel OpenMP setting # Intel OpenMP setting
ld_preload_str = os.getenv("LD_PRELOAD", "") ld_preload_str = os.getenv("LD_PRELOAD", "")
if "libiomp5.so" in ld_preload_str: if "libiomp5.so" in ld_preload_str:
......
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