Skip to content

增加快速冒烟脚本#4

Open
ghangz wants to merge 1 commit into
MetaX-MACA:mainfrom
ghangz:mengz/add-quick-smoke-script
Open

增加快速冒烟脚本#4
ghangz wants to merge 1 commit into
MetaX-MACA:mainfrom
ghangz:mengz/add-quick-smoke-script

Conversation

@ghangz

@ghangz ghangz commented Jun 10, 2026

Copy link
Copy Markdown

这次改动补上了快速冒烟脚本,主要是为了解决集体通信测试与结果整理流程里相关信息不够集中、人工整理成本较高的问题,让日常排查、验证和结果归档更直接。

实现上补充了对应工具或脚本逻辑,同步更新了相关说明,同时尽量保持现有用法不变,避免影响已有流程。

这一分支已经在沐曦算力环境完成实际验证,相关检查均已通过,现提交合入。

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new quick_smoke.sh script to run a short single-node smoke test before longer performance runs, and updates the README.md with quick examples on how to use it. The review feedback highlights a security issue in quick_smoke.sh where an empty LD_LIBRARY_PATH results in a trailing colon, potentially leading to untrusted library loading from the current working directory. A code suggestion was provided to resolve this safely.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread quick_smoke.sh
WARMUP_ITERS="${WARMUP_ITERS:-1}"
DATATYPE="${DATATYPE:-bfloat16}"

export LD_LIBRARY_PATH="${MACA_PATH}/lib:${MACA_PATH}/ompi/lib:${LD_LIBRARY_PATH:-}"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

security-medium medium

LD_LIBRARY_PATH 为空或未设置时,${LD_LIBRARY_PATH:-} 会展开为空,导致最终的 LD_LIBRARY_PATH: 结尾。在 Linux 中,路径末尾或中间的空路径(如双冒号或末尾冒号)会被隐式解释为当前工作目录(.),这存在安全隐患(可能会加载当前目录下的恶意动态库),也可能导致非预期的库加载行为。建议使用 ${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}} 语法,仅在 LD_LIBRARY_PATH 非空时才追加冒号和原路径。

Suggested change
export LD_LIBRARY_PATH="${MACA_PATH}/lib:${MACA_PATH}/ompi/lib:${LD_LIBRARY_PATH:-}"
export LD_LIBRARY_PATH="${MACA_PATH}/lib:${MACA_PATH}/ompi/lib${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant