refactor: simplify xllm_ops pre-build checks and marker-based rebuild logic.#1111
refactor: simplify xllm_ops pre-build checks and marker-based rebuild logic.#1111LMX-xin wants to merge 1 commit intojd-opensource:mainfrom
Conversation
There was a problem hiding this comment.
Code Review
This pull request refactors the pre-compilation logic for xllm_ops in CMakeLists.txt and utils.py. The changes introduce a new mechanism using a .xllm_ops_git_head marker file to track the third_party/xllm_ops git HEAD, replacing the previous CMake cache variable approach. This ensures xllm_ops is rebuilt only when its source code changes or the marker is missing. Additionally, the Python script now includes robust error handling for git operations and enforces a CANN version 8.5 requirement for compilation. The review comments point out a potential inconsistency in both CMakeLists.txt and utils.py regarding the precedence of ASCEND_HOME_PATH and ASCEND_OPP_PATH when determining the opp root, suggesting that ASCEND_OPP_PATH might be expected to have higher priority.
Summary