…te) + release-check row chat-npu-concurrent (engine#3318) (#3381)
* release-check: chat-npu-concurrent row, and the plain-queue arm accepts a concurrent answer (engine#3318)
- chat-npu-concurrent: four streamed known-answer chats sent together to the NPU entry; every one must end
in [DONE], carry no error and contain its own answer (a slot mix-up hands one user another's text). A
one-at-a-time route passes too (the others queue); the row prints the wall time. Pure verdict
concurrent_verdict, driven by --self-test (7 cases).
- chat-npu-queue-plain: a 200 for the non-streamed chat is a PASS when it says 1BIT OK and came back while
the long chat was still running (the route served both at once); a 200 after the long chat ended is still
the old FAIL (a silently parked request). 6 new self-test cases.
--self-test PASS under bash and busybox sh (194 ok).
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* pins: npu-kernels 10e73744 -> e61baa3b, several requests at once on the dx route (engine#3318)
npu-dx tip e61baa3b6 carries npu-kernels#121 (several users at once on one dx session: decoder slots, the route's
users= option, default 4) and #122 (fg_gemv_c34 sets its rounding mode at kernel start). #3327 already merged the
engine half (PrivateSession::max_concurrent).
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* release-check: chat-npu-concurrent asks questions Qwen3-0.6B answers reliably (engine#3318)
Measured on strixhalo 23 Nov (installed v2026.48): the row FAILed on chat 4 of 4, "largest planet" -> "Earth": the
0.6B model's answer, not the route (the same question fails serially). It is now "3 times 3" -> 9, which the model
answers in every run of npu-kernels' concurrent-check; the four answers stay distinct, so a slot mix-up still shows.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
---------
Co-authored-by: bong-water-water-bong <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
Part of #3318 (item 1: several users of one model on
1bit serve --device npu, the route Lemonade uses).What
PrivateSession::max_concurrent()(default 1): how many requests a private route can take at once.app/npu_queue.h:DeviceSlots, a counting timed lock (set_capacity,try_lock_for,unlock).wait_for_deviceis now a template over any timed lockable.app/unified.cpp: the engine's device lock is aDeviceSlots, sized from the private session'smax_concurrent()once it opens. With capacity 1 (every route today) behaviour is unchanged: one request at a time, the rest wait, and a timeout gives the same busy reply. The busy message names the count when it is above 1.tests/npu_queue_test.cpp: fourDeviceSlotsarms (capacity 1 = a mutex, capacity N lets N in and blocks the next,try_lock_fortimes out then succeeds after an unlock, raising the capacity wakes a waiter).No behaviour change until the private route reports more than 1. That route change is in the private add-on and reaches main with a later pin bump.
Checks
bash scripts/pre-pr-checks.sh --base origin/main: 18 green, 2 skipped (no gpu-kernels tree).npu_queue_test: ok (ryzen, g++-16).Measured with the private half (strixhalo)
An engine package built from this branch plus the private route change, under
box-hold npu, amdxdna F87D0BDF248067862F83BA3, 0 amdxdna faults before and after. Qwen3-0.6B, 2 rounds per row, temperature 0:lemondwith this build as itsonebitbackend,Qwen3-0.6B-NPU-1bit, N=1/2/4/8).Not run: models other than Qwen3-0.6B with U>1.
🤖 Generated with Claude Code