[GH-ISSUE #929] --batch with --layer-split exits ("verify batch: layer 34 never rang") with a 3070 first and a P40 second; works with the P40 first (CUDA, v0.1.39) #404

Closed
opened 2026-11-04 01:42:44 +07:00 by bsakaguchi · 4 comments
Owner

Originally created by @paulhothersall on GitHub (Oct 5, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/929

On v0.1.39 (CUDA 12.9), --layer-split 34 --batch 4 --batch-groups 1 on an RTX 3070 (GPU 0, layers 0-33) + Tesla P40 (GPU 1, layers 34-47) exits when a second request arrives: verify batch: layer 34 never rang (graph finished), exit code 1. With the cards in the other order (P40 first) the same command works. The batch-groups flag, the slot count, the weight carve and the context size do not change it.

Setup: v0.1.39 (6f32ec0) built from source, CUDA 12.9, -DCMAKE_CUDA_ARCHITECTURES="61;86", RTX 3070 8 GB (cc 8.6) + Tesla P40 24 GB (cc 6.1), PCIe 3.0 x8 each, no P2P, 64 GB RAM, Qwen3.8-Flash-Next IQ3_XXS, --spec 4 --mtp, --expert-cache auto --prefill auto, served through serve/server.py.

Repro: start the server with --layer-split 34 --batch 4 --batch-groups 1 and send two chat requests at once (about 600-token prompts, 200 new tokens). The first request gets 2 tokens, then the engine reports verify batch: layer 34 never rang (graph finished) and exits (code 1). Last engine log line before the exit: strata verify: captured the batch window over slots 0.

change result
3070 first, --batch 4 --batch-groups 1, context 36,864, STRATA_STAGE_TRIM=1 crashes
same, context 8,192, no carve crashes
same, --batch 4 without --batch-groups crashes
same, --batch 2 --batch-groups 1 crashes
P40 first (P40 as GPU 0, 3070 as GPU 1), --layer-split 34 --batch 4 --batch-groups 1, context 8,192 works: 2 streams, 386 chunks in 17.1 s (20.0 / 14.5 chunks/s per stream)
P40 alone, --batch 4 works

Related: #890 (HIP, 2x R9700, parallel: 2 + --layer-split) ends at the same point (captured the batch window over slots 0,1, exit code 1, no error text) and reports the same setup works on 3x RTX 5070 Ti with CUDA. #867 has the same message text on a SYCL port, where the issue traces it to a cudaStreamQuery mapping; I am not claiming the same cause. My reading, not checked in the code: the stage on the Pascal card does not complete its part of the batch window when it is the second stage.

Not tested: --spec 0 (my attempt failed to load), other card pairs, P2P, vision on. I can send the engine logs or run a debug build.

Originally created by @paulhothersall on GitHub (Oct 5, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/929 **On v0.1.39 (CUDA 12.9), `--layer-split 34 --batch 4 --batch-groups 1` on an RTX 3070 (GPU 0, layers 0-33) + Tesla P40 (GPU 1, layers 34-47) exits when a second request arrives: `verify batch: layer 34 never rang (graph finished)`, exit code 1. With the cards in the other order (P40 first) the same command works. The batch-groups flag, the slot count, the weight carve and the context size do not change it.** Setup: v0.1.39 (6f32ec0) built from source, CUDA 12.9, `-DCMAKE_CUDA_ARCHITECTURES="61;86"`, RTX 3070 8 GB (cc 8.6) + Tesla P40 24 GB (cc 6.1), PCIe 3.0 x8 each, no P2P, 64 GB RAM, Qwen3.8-Flash-Next IQ3_XXS, `--spec 4 --mtp`, `--expert-cache auto --prefill auto`, served through `serve/server.py`. Repro: start the server with `--layer-split 34 --batch 4 --batch-groups 1` and send two chat requests at once (about 600-token prompts, 200 new tokens). The first request gets 2 tokens, then the engine reports `verify batch: layer 34 never rang (graph finished)` and exits (code 1). Last engine log line before the exit: `strata verify: captured the batch window over slots 0`. | change | result | |---|---| | 3070 first, `--batch 4 --batch-groups 1`, context 36,864, `STRATA_STAGE_TRIM=1` | crashes | | same, context 8,192, no carve | crashes | | same, `--batch 4` without `--batch-groups` | crashes | | same, `--batch 2 --batch-groups 1` | crashes | | **P40 first (P40 as GPU 0, 3070 as GPU 1), `--layer-split 34 --batch 4 --batch-groups 1`, context 8,192** | **works**: 2 streams, 386 chunks in 17.1 s (20.0 / 14.5 chunks/s per stream) | | P40 alone, `--batch 4` | works | Related: #890 (HIP, 2x R9700, `parallel: 2` + `--layer-split`) ends at the same point (`captured the batch window over slots 0,1`, exit code 1, no error text) and reports the same setup works on 3x RTX 5070 Ti with CUDA. #867 has the same message text on a SYCL port, where the issue traces it to a `cudaStreamQuery` mapping; I am not claiming the same cause. My reading, not checked in the code: the stage on the Pascal card does not complete its part of the batch window when it is the second stage. Not tested: `--spec 0` (my attempt failed to load), other card pairs, P2P, vision on. I can send the engine logs or run a debug build.
Author
Owner

@paulhothersall commented on GitHub (Oct 6, 2026):

On v0.1.40 (1735d64) the exit in this issue did not reproduce in my run: RTX 3070 first, P40 second, --layer-split 34 --batch 4 --batch-groups 1, two concurrent requests, both streams finished (382 chunks in 18.0 s, 21.2 chunks/s aggregate). Limit: one launch of one row of the table above (context 8,192, IQ3_XXS); I did not bisect which change fixed it.

With --batch-mtp added on the same split the engine prints WARNING: --batch-mtp is off: it is for one GPU (no layer split or helper) for now and also finished (379 chunks in 17.3 s, 22.0 chunks/s). The same pair on v0.1.39 exited with "layer 34 never rang" every time in the 3070-first order.
Not tested: the other rows of the table (context 36,864 with the carve, --batch 2, no --batch-groups), more than two concurrent requests.

<!-- gh-comment-id:6023473608 --> @paulhothersall commented on GitHub (Oct 6, 2026): **On v0.1.40 (1735d64) the exit in this issue did not reproduce in my run: RTX 3070 first, P40 second, `--layer-split 34 --batch 4 --batch-groups 1`, two concurrent requests, both streams finished (382 chunks in 18.0 s, 21.2 chunks/s aggregate).** Limit: one launch of one row of the table above (context 8,192, IQ3_XXS); I did not bisect which change fixed it. With `--batch-mtp` added on the same split the engine prints `WARNING: --batch-mtp is off: it is for one GPU (no layer split or helper) for now` and also finished (379 chunks in 17.3 s, 22.0 chunks/s). The same pair on v0.1.39 exited with "layer 34 never rang" every time in the 3070-first order. Not tested: the other rows of the table (context 36,864 with the carve, `--batch 2`, no `--batch-groups`), more than two concurrent requests.
Author
Owner

@Niko1221 commented on GitHub (Oct 7, 2026):

This looks like the case 0.1.40 fixed (36d28148): stage 1 held every expert, so the batch window saw no work. Please retest --batch 4 with --layer-split 34 on 0.1.40.1; it now also prints the ERR line if a batch window fails. Same family as #890.

<!-- gh-comment-id:6037885865 --> @Niko1221 commented on GitHub (Oct 7, 2026): This looks like the case 0.1.40 fixed (36d28148): stage 1 held every expert, so the batch window saw no work. Please retest --batch 4 with --layer-split 34 on 0.1.40.1; it now also prints the ERR line if a batch window fails. Same family as #890.
Author
Owner

@paulhothersall commented on GitHub (Oct 7, 2026):

**Retested on v0.1.40.2: --layer-split 34 --batch 4 --batch-groups 1 with two concurrent requests works in both card orders on my P40 + RTX 3070 (no exit):

3070 first 385 chunks in 21.5 s (17.9 chunks/s),
P40 first 385 chunks in 23.5 s (16.4 chunks/s),

ctx 8,192, IQ3_XXS, one launch each.

** The 3070-first order is the one that exited on 0.1.39; on 0.1.40 it ran at 21.2 chunks/s (one launch), so 0.1.40.2 is slower here, the same direction as the decode difference I mention on #1238 (cause not found yet). Not tested: more than two requests, --batch-mtp with the split (it prints that it is off for a split).

<!-- gh-comment-id:6045398022 --> @paulhothersall commented on GitHub (Oct 7, 2026): **Retested on v0.1.40.2: `--layer-split 34 --batch 4 --batch-groups 1` with two concurrent requests works in both card orders on my P40 + RTX 3070 (no exit): 3070 first 385 chunks in 21.5 s (17.9 chunks/s), P40 first 385 chunks in 23.5 s (16.4 chunks/s), ctx 8,192, IQ3_XXS, one launch each. ** The 3070-first order is the one that exited on 0.1.39; on 0.1.40 it ran at 21.2 chunks/s (one launch), so 0.1.40.2 is slower here, the same direction as the decode difference I mention on #1238 (cause not found yet). Not tested: more than two requests, `--batch-mtp` with the split (it prints that it is off for a split).
Author
Owner

@Niko1221 commented on GitHub (Oct 13, 2026):

Thanks for the report. To keep the tracker current we are closing issues older than three days: 0.1.44 is out with a long list of fixes, and many older reports are covered by it or by 0.1.43.1.

If this still happens on 0.1.44, please leave a comment here with your engine log (and the version line it prints), and we will reopen it. A new issue that links this one works too.

<!-- gh-comment-id:6155989517 --> @Niko1221 commented on GitHub (Oct 13, 2026): Thanks for the report. To keep the tracker current we are closing issues older than three days: [0.1.44](https://github.com/Niko1221/Strata/releases/tag/v0.1.44) is out with a long list of fixes, and many older reports are covered by it or by 0.1.43.1. If this still happens on 0.1.44, please leave a comment here with your engine log (and the version line it prints), and we will reopen it. A new issue that links this one works too.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#404
No description provided.