llama.cpp/tests/fusion
Pascal 7365e4793c
tests : take the test-fusion moe flag from the fixture name (#33104)
* tests : take the test-fusion moe flag from the fixture name

The moe flag came from the arch name, so the dense and MoE fixtures
of an arch shared a baseline key, and MoE-only archs were keyed as
dense. Read it from the -dense/-moe suffix written by
test-llama-archs and regenerate the Metal baseline. Only the moe
column changes, no count moves.

* Apply suggestion from ggerganov

Co-authored-by: Georgi Gerganov <ggerganov@gmail.com>

---------

Co-authored-by: Georgi Gerganov <ggerganov@gmail.com>
2026-11-26 14:44:02 +02:00
..
MTL.csv tests : take the test-fusion moe flag from the fixture name (#33104) 2026-11-26 14:44:02 +02:00
README.md tests : catch vanished rows in the fusion baseline (#30618) 2026-10-16 09:35:19 +03:00

Fusion baselines

Per-device baselines for test-fusion, one CSV per backend (e.g. MTL.csv). Rows are arch,moe,mode,label,count. Regenerate a CSV whenever fusion patterns change.

Update a baseline

cmake -B build -DCMAKE_BUILD_TYPE=Release -DGGML_METAL=ON   # enable the target backend
cmake --build build --config Release --target test-llama-archs --target test-fusion -j

rm -rf build-ci-models && mkdir -p build-ci-models
./build/bin/test-llama-archs -o build-ci-models

./build/bin/test-fusion --models build-ci-models --device MTL0 --record MTL.csv

Validate

./build/bin/test-fusion --models build-ci-models --device MTL0 --check MTL.csv

Non-zero exit means a row differs from the baseline. Use --model FILE to run a single architecture. --check also reports baseline rows that the run no longer produces, so a fusion that stops matching fails the run instead of silently dropping out of the CSV.