Metal build fails: unused const kGdnLayers in test_qwen27n_fp8_tower_paged_engine.cpp
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 423
- Forks
- 53
- Avg merge
- 20h 26m
- Merged PRs (30d)
- 310
Description
tests/parity/test_qwen27n_fp8_tower_paged_engine.cpp:95 declares constexpr uint64_t kGdnLayers = 48; unconditionally, but its only uses (lines 281, 282, 329) sit inside #ifdef VLLM_CPP_CUDA.
On a non-CUDA build (cmake -DVLLM_CPP_MLX=ON Metal configure on macOS) this trips -Werror,-Wunused-const-variable and breaks the build at 100%:
tests/parity/test_qwen27n_fp8_tower_paged_engine.cpp:95:20: error: unused variable 'kGdnLayers' [-Werror,-Wunused-const-variable]
Fix: move the constant (and its comment) inside the same #ifdef VLLM_CPP_CUDA guard as its uses.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Open tests/parity/test_qwen27n_fp8_tower_paged_engine.cpp and inspect the kGdnLayers declaration at line 95 alongside its CUDA-only uses around lines 281, 282, and 329. Move the constant and its comment under the VLLM_CPP_CUDA guard, then configure with cmake -DVLLM_CPP_MLX=ON to confirm the non-CUDA Metal build completes without the unused-variable error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 92/100