Skip to content

test(qdc): run llama_cpp LLM + VLM QDC matrix on cpu/gpu/npu - #1308

Draft
Mengsheng Wu (mengshengwu) wants to merge 2 commits into
mainfrom
chore/qdc-llama-cpp-gpu-matrix
Draft

test(qdc): run llama_cpp LLM + VLM QDC matrix on cpu/gpu/npu#1308
Mengsheng Wu (mengshengwu) wants to merge 2 commits into
mainfrom
chore/qdc-llama-cpp-gpu-matrix

Conversation

@mengshengwu

Copy link
Copy Markdown
Contributor

Summary

The QDC device matrix for the llama_cpp plugin previously exercised only cpu + npu, and test_vlm_multi_turn was hard-coded to cpu. This extends both the LLM and VLM cells to also cover the OpenCL gpu backend so a regression on the llama.cpp GPU path shows up on QDC just like the NPU path does.

Concretely:

  • tests/test_llama_cpp.py_LLM_BACKENDS / _VLM_BACKENDS are now ['cpu', 'gpu', 'npu']; test_vlm_multi_turn is parametrised on device_map instead of pinning 'cpu'.
  • tests/conftest.pydevice_map='gpu' now auto-tags device_gpu + snapdragon, so non-Snapdragon hosts skip the GPU cells the same way they already skip NPU.
  • tests/pytest.ini — register the new device_gpu marker (--strict-markers).
  • tests/README.md — reflect the new backend row.

qairt is unchanged (still npu-only by design — see sdk/src/device.cpp, which coerces cpu/gpu to NPU with a warning).

Test plan

  • pytest tests --collect-only -m "llama_cpp" picks up the new [gpu] cells (20 items collected on this host, 22 deselected).
  • pytest tests --collect-only -m "api or (llama_cpp and device_cpu)" still selects only the cpu subset — the model-free + cpu shard on GitHub runners is unaffected.
  • pytest tests --collect-only -m device_gpu yields exactly the 6 new gpu cells.
  • pending — QDC _qdc-test.yml on workflow_dispatch to confirm the new [gpu] cells run green on real QCS9075M / SC8480XP hardware.

Previously the QDC llama_cpp cells only exercised cpu + npu, and
test_vlm_multi_turn hard-coded cpu. Extend the backend lists to
cover the OpenCL GPU path too, parametrise test_vlm_multi_turn,
register the new device_gpu marker and gate it behind snapdragon
so non-Snapdragon hosts still skip cleanly.

Signed-off-by: Mengsheng Wu <mengshengwu@outlook.com>
The QDC harness zips the whole tests/ tree onto the device, so
tests/test_*.py and tests/conftest.py changes actually affect the
on-device run — but the change-gate only matched tests/qdc/**, so
any pure test-code change skipped both QDC legs and shipped
unverified. Widen the include to tests/.

Signed-off-by: Mengsheng Wu <mengshengwu@outlook.com>
@mengshengwu
Mengsheng Wu (mengshengwu) marked this pull request as draft August 7, 2026 15:17
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