test_cpu_threadpool: the 100x dispatch ratio is calibrated on 20 cores and flakes on 4-vCPU CI runners
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 58/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- cpp
- Ambito
- testing-qa
Direzione di ricerca
Inizia in tests/vt/test_cpu_threadpool.cpp, nel caso oversubscribed dispatch does not cost a scheduler timeslice, e leggi il commento sulla calibrazione accanto a Threadpool::Run. Riproduci il rapporto di dispatch su un runner con 4 vCPU, quindi scegli e convalida una modifica alla calibrazione che rimanga sensibile al difetto di timeslice dello scheduler rilevato. Esegui il job di test della CPU e conferma che il caso passi su runner piccoli senza mascherare tale difetto.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Row: QUANT-GGUF-CPU-THREADPOOL
tests/vt/test_cpu_threadpool.cpp, case oversubscribed dispatch does not cost a scheduler timeslice, asserts ratio < 100.0 on ratio = median_dispatch_us(cores + 1) / median_dispatch_us(cores / 2).
Observed on CI (4-vCPU hosted runner)
build-test-cpu job 102683560829 (PR #3095, run 34416865779), tests/vt/test_cpu_threadpool.cpp:610:
MESSAGE: empty-op dispatch: 2 threads 0.421 us, 5 threads 42.75 us, ratio 101.544
ERROR: CHECK( ratio < 100.0 ) is NOT correct!
The arms are 2 and 5 threads, which proves the runner reported hardware_concurrency() == 4.
Why this reads as a calibration gap rather than a detected defect
- The recorded defect signature in this test's own comment is an over arm of 2999-5996 us at 21 threads against 18-20 us fixed. Here the over arm is 42.75 us, roughly 70x below that signature, so the waiter was not spinning through a scheduler timeslice.
- The comment's calibration ("Verified both ways on 20 cores") and its margin ("~30x below the defect and ~28x above the fixed behaviour") come from a 20-core box with arms 10 and 21. On a 4-vCPU runner the arms are 2 and 5 and the denominator measured 0.421 us, about 4x below the 1.68 us the same comment calibrates against, so the ratio is dominated by denominator noise.
std::thread::hardware_concurrency()is not reduced by CPU affinity on this glibc:taskset -c 0-3 <binary>still selects 24/49-thread arms, so the 4-vCPU geometry cannot be reproduced locally by pinning cores.main's ownbuild-test-cpujob103074166342passes the same test on the same runner class, so the check is marginal there rather than deterministically red.
Suggested fix (owner's call; changing an assertion needs its own spec)
Floor the denominator, for example over_us < std::max(100.0 * fits_us, <absolute floor>), or scale the threshold with cores, or skip the case below 8 cores. Any of these must keep the case able to fail for the defect it was written for.
Found while triaging an unrelated red check on PR #3095: that diff changes attention and embedding gating in src/vt/ops.cpp and never calls the measured path, which is Threadpool::Run with an empty body.
- Lingua principale
- C++
- Stelle
- 423
- Fork
- 53
- Merge medio
- 1g 5h
- PR unite (30g)
- 376
Preparare l'ambiente
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di mudler/vllm.cpp
-
[Windows] full build fails in tools/bench/conv1d_scaling_probe.cpp (POSIX-only sys/resource.h)Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di mudler/vllm.cpp
Issue simili
-
`enzymexla.linalg.lu` lowering fails for a tall matrix: the permutation is built with the pivot typeAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
EnzymeAD/Enzyme-JAX#3286 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
apache/iceberg-cpp#973 ·
I maintainer di solito rispondono entro 1 giorno
-
Add c++23 mapping to nvccApertafeature request
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 86/100
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno