[GH-ISSUE #3297] [Engine] gfx1201 (RX 9070, 16 GB): batched prompt read stalls when 7 tokens are left; 0.1.45 and 0.1.45.3 (follow-up to #579) #1338

Closed
opened 2026-11-04 01:50:27 +07:00 by bsakaguchi · 10 comments
Owner

Originally created by @JustPowell on GitHub (Oct 20, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/3297

Follow-up to #579 (closed in the stale sweep; it asked for a new issue if it still happens on 0.1.44 or later). The same stall still happens here on 0.1.45 and on 0.1.45.3, and there's a very regular trigger: every hang happens when the prompt's last batched step has 7 tokens left.

Pattern

The client is an automated loop. It sends short OpenAI-API requests: about 3-4K-token prompts, max_tokens 1500, reasoning_effort: "none", no conversation reuse. Each request either finishes or hangs on the last step of the batched prompt read:

prompt tokens progress line when it stopped tokens left
3,898 reading the prompt: 3,891 of 3,898 7 (hung)
4,012 4,005 of 4,012 7 (hung)
3,079 3,072 of 3,079 7 (hung)
3,127 3,126 of 3,127 1 (finished)
3,909 3,908 of 3,909 1 (finished)

Every hang where I could see the prompt length had 7 tokens left, and every request I saw finish had 1 left. Two more hangs stopped at token 4142 and token 2948, but I don't have their prompt lengths. After roughly 280 s the watchdog ends the engine (exit -6, no progress for 60 s ... reading the prompt (batched), done up to token N; once also -9 via engine_silence_s). The restarted engine then reads the same prompt fine.

What I ruled out

Each change below gave the same hang at a 7-token tail:

  • Strata v0.2.0-beta (engine 0.1.45.3) and v0.1.45 (engine 0.1.45), both built locally with setup

  • --spec 4 --spec-min-p 0.5 --mtp ... (the default) and --spec 2 --spec-min-p 0.5 without --mtp

  • --max-context 65536 (about 500-600 MiB VRAM free, LOW warning) and --max-context 16384 --vram-reserve-mib 3072 (about 2.9-3.0 GiB free when the request began)

  • STRATA_RESIDENT_HEADROOM_GIB=10; the PLE direct probe was fine (39-55K rows/s)

  • STRATA_PLE_BATCH=0 (the workaround from #541), set in the config's env: still hangs, at token 4393 of the batched prompt read on 0.1.45

Not tried yet: THP off and STRATA_ARENA_PIN_GIB=0 (the other asks from #579). As in #579, the GPU also drives the desktop (KDE Plasma, Wayland).

Environment

  • GPU: AMD Radeon RX 9070 series (gfx1201, 16 GB), the only GPU, also driving the desktop
  • ROCm 7.2.4, kernel 6.18.55-2-cachyos-lts (CachyOS), THP always
  • CPU: Ryzen 7 9800X3D, 32 GB RAM (30 GiB usable), swap on
  • Model: Coder IQ1_M (coder-iq1_m, native pack), --expert-cache auto --prefill auto --kv int8 --resident-experts

Stall report (0.1.45)

strata serve: no progress for 60 s during a request (reading the prompt (batched), done up to token 3891) - stopping the engine so the server starts it again (issue #29)
strata serve: stall report (engine 0.1.45): stage "reading the prompt (batched), done up to token 3891" for 62 s; 0 layers served since the last finished step (0 = stopped, more = slow)
  VRAM free when this request began: 2910 MiB
  expert pool: epoch 15024, batch epoch 15024: 24 of 24 jobs claimed, 24 done; 7 of 7 workers parked, 7 sleeping; mode 0
  expert pool threads: w0=sleeping w1=sleeping w2=sleeping w3=sleeping w4=sleeping w5=sleeping w6=sleeping; host idle for 89743 ms
  verify window (last window, not the current stage): 1 tokens at position 3183, host at layer step 48; the GPU rang 48; flags: served 48, plan (A) 48, copies (B) 48
  threads waiting on the disk (state D): 0 of 33
  memory: 9519 MiB resident, 8260 MiB in swap, 10605 MiB RAM available; 3341958 major page faults so far

Engine command line:

strata --serve --pack .../packs/coder-iq1_m --native .../Qwen3.8-Flash-Next-GSQ-RCO-IQ1_M-00001-of-00002.gguf --ple-gguf .../Qwen3.8-Flash-Next-GSQ-RCO-IQ1_M-00002-of-00002.gguf --expert-profile data/expert-profile-coder.bin --expert-cache auto --prefill auto --spec 2 --spec-min-p 0.5 --max-context 16384 --kv int8 --resident-experts --vram-reserve-mib 3072 --vision

The 0.1.45.3 stall reports look the same, with VRAM free when this request began: 2944 MiB. Happy to run THP off, STRATA_ARENA_PIN_GIB=0 or other diagnostics, and to attach the full engine log.

Originally created by @JustPowell on GitHub (Oct 20, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/3297 Follow-up to #579 (closed in the stale sweep; it asked for a new issue if it still happens on 0.1.44 or later). The same stall still happens here on 0.1.45 and on 0.1.45.3, and there's a very regular trigger: **every hang happens when the prompt's last batched step has 7 tokens left.** ## Pattern The client is an automated loop. It sends short OpenAI-API requests: about 3-4K-token prompts, `max_tokens` 1500, `reasoning_effort: "none"`, no conversation reuse. Each request either finishes or hangs on the last step of the batched prompt read: | prompt tokens | progress line when it stopped | tokens left | |---|---|---| | 3,898 | `reading the prompt: 3,891 of 3,898` | **7** (hung) | | 4,012 | `4,005 of 4,012` | **7** (hung) | | 3,079 | `3,072 of 3,079` | **7** (hung) | | 3,127 | `3,126 of 3,127` | 1 (finished) | | 3,909 | `3,908 of 3,909` | 1 (finished) | Every hang where I could see the prompt length had 7 tokens left, and every request I saw finish had 1 left. Two more hangs stopped at token 4142 and token 2948, but I don't have their prompt lengths. After roughly 280 s the watchdog ends the engine (exit -6, `no progress for 60 s ... reading the prompt (batched), done up to token N`; once also -9 via `engine_silence_s`). The restarted engine then reads the same prompt fine. ## What I ruled out Each change below gave the same hang at a 7-token tail: - Strata v0.2.0-beta (engine 0.1.45.3) and v0.1.45 (engine 0.1.45), both built locally with setup - `--spec 4 --spec-min-p 0.5 --mtp ...` (the default) and `--spec 2 --spec-min-p 0.5` without `--mtp` - `--max-context 65536` (about 500-600 MiB VRAM free, LOW warning) and `--max-context 16384 --vram-reserve-mib 3072` (about 2.9-3.0 GiB free when the request began) - `STRATA_RESIDENT_HEADROOM_GIB=10`; the PLE direct probe was fine (39-55K rows/s) - `STRATA_PLE_BATCH=0` (the workaround from #541), set in the config's `env`: still hangs, at token 4393 of the batched prompt read on 0.1.45 Not tried yet: THP off and `STRATA_ARENA_PIN_GIB=0` (the other asks from #579). As in #579, the GPU also drives the desktop (KDE Plasma, Wayland). ## Environment - GPU: AMD Radeon RX 9070 series (gfx1201, 16 GB), the only GPU, also driving the desktop - ROCm 7.2.4, kernel 6.18.55-2-cachyos-lts (CachyOS), THP `always` - CPU: Ryzen 7 9800X3D, 32 GB RAM (30 GiB usable), swap on - Model: Coder IQ1_M (`coder-iq1_m`, native pack), `--expert-cache auto --prefill auto --kv int8 --resident-experts` ## Stall report (0.1.45) ``` strata serve: no progress for 60 s during a request (reading the prompt (batched), done up to token 3891) - stopping the engine so the server starts it again (issue #29) strata serve: stall report (engine 0.1.45): stage "reading the prompt (batched), done up to token 3891" for 62 s; 0 layers served since the last finished step (0 = stopped, more = slow) VRAM free when this request began: 2910 MiB expert pool: epoch 15024, batch epoch 15024: 24 of 24 jobs claimed, 24 done; 7 of 7 workers parked, 7 sleeping; mode 0 expert pool threads: w0=sleeping w1=sleeping w2=sleeping w3=sleeping w4=sleeping w5=sleeping w6=sleeping; host idle for 89743 ms verify window (last window, not the current stage): 1 tokens at position 3183, host at layer step 48; the GPU rang 48; flags: served 48, plan (A) 48, copies (B) 48 threads waiting on the disk (state D): 0 of 33 memory: 9519 MiB resident, 8260 MiB in swap, 10605 MiB RAM available; 3341958 major page faults so far ``` Engine command line: ``` strata --serve --pack .../packs/coder-iq1_m --native .../Qwen3.8-Flash-Next-GSQ-RCO-IQ1_M-00001-of-00002.gguf --ple-gguf .../Qwen3.8-Flash-Next-GSQ-RCO-IQ1_M-00002-of-00002.gguf --expert-profile data/expert-profile-coder.bin --expert-cache auto --prefill auto --spec 2 --spec-min-p 0.5 --max-context 16384 --kv int8 --resident-experts --vram-reserve-mib 3072 --vision ``` The 0.1.45.3 stall reports look the same, with `VRAM free when this request began: 2944 MiB`. Happy to run THP off, `STRATA_ARENA_PIN_GIB=0` or other diagnostics, and to attach the full engine log.
Author
Owner

@github-actions[bot] commented on GitHub (Oct 20, 2026):

Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing:

  • Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other], then a short description. Example: "[Engine] decode stops after 2 minutes".

Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment /reopen.

Details: CONTRIBUTING.md

<!-- gh-comment-id:6280533667 --> @github-actions[bot] commented on GitHub (Oct 20, 2026): Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing: - [ ] Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other], then a short description. Example: "[Engine] decode stops after 2 minutes". Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment `/reopen`. Details: [CONTRIBUTING.md](https://github.com/Niko1221/Strata/blob/main/CONTRIBUTING.md)
Author
Owner

@github-actions[bot] commented on GitHub (Oct 20, 2026):

Thanks, this follows the format now.

<!-- gh-comment-id:6280572106 --> @github-actions[bot] commented on GitHub (Oct 20, 2026): Thanks, this follows the format now.
Author
Owner

@JustPowell commented on GitHub (Oct 20, 2026):

Tried the two remaining asks from #579 on 0.2.0-beta (engine 0.1.45.3): THP off (/sys/kernel/mm/transparent_hugepage/enabled = never) together with STRATA_ARENA_PIN_GIB=0 in the config's env (confirmed in the engine's environment). The same settings as above otherwise: --spec 2 --spec-min-p 0.5, no --mtp, --max-context 16384, --vram-reserve-mib 3072.

It still stalls in the same place, within about 10 requests:

strata serve: no progress for 60 s during a request (reading the prompt (batched), done up to token 3965) - stopping the engine so the server starts it again (issue #29)
  VRAM free when this request began: 2880 MiB

A correction to the list above: the STRATA_PLE_BATCH=0 run was on 0.1.45 (engine 0.1.45), not on 0.1.45.3. The final config (--spec 2, no --mtp, 16K context, 3 GB VRAM reserve) hung on both versions. The earlier variations (default --spec 4 --mtp, the 65536 context) were only run on 0.1.45.3.

<!-- gh-comment-id:6280740306 --> @JustPowell commented on GitHub (Oct 20, 2026): Tried the two remaining asks from #579 on **0.2.0-beta (engine 0.1.45.3)**: THP off (`/sys/kernel/mm/transparent_hugepage/enabled` = `never`) together with `STRATA_ARENA_PIN_GIB=0` in the config's `env` (confirmed in the engine's environment). The same settings as above otherwise: `--spec 2 --spec-min-p 0.5`, no `--mtp`, `--max-context 16384`, `--vram-reserve-mib 3072`. It still stalls in the same place, within about 10 requests: ``` strata serve: no progress for 60 s during a request (reading the prompt (batched), done up to token 3965) - stopping the engine so the server starts it again (issue #29) VRAM free when this request began: 2880 MiB ``` A correction to the list above: the `STRATA_PLE_BATCH=0` run was on 0.1.45 (engine 0.1.45), not on 0.1.45.3. The final config (`--spec 2`, no `--mtp`, 16K context, 3 GB VRAM reserve) hung on both versions. The earlier variations (default `--spec 4 --mtp`, the 65536 context) were only run on 0.1.45.3.
Author
Owner

@JustPowell commented on GitHub (Oct 20, 2026):

Good news: on 0.2.1.1 (engine 0.1.46.1) the stall is gone here. I updated the source install with ./update.sh and kept the same run config as in the last comment (--spec 2 --spec-min-p 0.5, no --mtp, --max-context 16384, --vram-reserve-mib 3072; THP back on, always).

The same automated client ran 184 requests in a row (3-4K-token prompts, max_tokens 1500, reasoning_effort: "none") with no no progress stall and no engine restart, against a stall within about 10 requests on 0.1.45 and 0.1.45.3. Decode averaged about 67 tok/s.

One change differs from the earlier runs: the monitor now runs on the integrated GPU, so the RX 9070 no longer drives the desktop. Probably not the cause (the 3 GB reserve already left plenty of VRAM free), but I mention it in case it matters. Feel free to close this; I'll reopen if it comes back.

<!-- gh-comment-id:6292269385 --> @JustPowell commented on GitHub (Oct 20, 2026): Good news: on **0.2.1.1 (engine 0.1.46.1)** the stall is gone here. I updated the source install with `./update.sh` and kept the same run config as in the last comment (`--spec 2 --spec-min-p 0.5`, no `--mtp`, `--max-context 16384`, `--vram-reserve-mib 3072`; THP back on, `always`). The same automated client ran 184 requests in a row (3-4K-token prompts, `max_tokens` 1500, `reasoning_effort: "none"`) with no `no progress` stall and no engine restart, against a stall within about 10 requests on 0.1.45 and 0.1.45.3. Decode averaged about 67 tok/s. One change differs from the earlier runs: the monitor now runs on the integrated GPU, so the RX 9070 no longer drives the desktop. Probably not the cause (the 3 GB reserve already left plenty of VRAM free), but I mention it in case it matters. Feel free to close this; I'll reopen if it comes back.
Author
Owner

@JustPowell commented on GitHub (Oct 20, 2026):

Correction to my last comment: the stall is not gone on 0.2.1.1 (engine 0.1.46.1). It only stayed away while the prompts were short. The 184 clean requests all had 3-4K-token prompts. With longer prompts it is back, at the same 7-token tail:

[strata] reading the prompt: 8,104 of 8,111 tokens, 302 s so far
[strata] the engine said nothing for 300 s during the request; the server ended the engine. ... (issue #481 ...)
[strata] done: 0 tokens in 312 s (0.0 tok/s) (error, cancel=False)

The same 8,111-token prompt, re-sent after the engine restart, failed differently:

[strata] reading the prompt: 8,104 of 8,111 tokens, 12 s so far
[strata] the engine stopped unexpectedly (exit code -15). Unrecoverable native verification failure: verify: timed out at layer 21; its GPU waits were released but the GPU did not finish within 5 s (#267)

The engine also dumped core twice while starting again after these. Same config as before (--spec 2 --spec-min-p 0.5, no --mtp, --max-context 16384, --kv int8, --vram-reserve-mib 3072, STRATA_RESIDENT_HEADROOM_GIB=10, STRATA_ARENA_PIN_GIB=0), THP always, the monitor on the iGPU. So short prompts are fine on 0.1.46.1, and prompts of about 8K tokens and up hit the 7-token tail. Leaving this open; happy to send the full engine log or test a build.

<!-- gh-comment-id:6293717703 --> @JustPowell commented on GitHub (Oct 20, 2026): Correction to my last comment: the stall is **not** gone on 0.2.1.1 (engine 0.1.46.1). It only stayed away while the prompts were short. The 184 clean requests all had 3-4K-token prompts. With longer prompts it is back, at the same 7-token tail: ``` [strata] reading the prompt: 8,104 of 8,111 tokens, 302 s so far [strata] the engine said nothing for 300 s during the request; the server ended the engine. ... (issue #481 ...) [strata] done: 0 tokens in 312 s (0.0 tok/s) (error, cancel=False) ``` The same 8,111-token prompt, re-sent after the engine restart, failed differently: ``` [strata] reading the prompt: 8,104 of 8,111 tokens, 12 s so far [strata] the engine stopped unexpectedly (exit code -15). Unrecoverable native verification failure: verify: timed out at layer 21; its GPU waits were released but the GPU did not finish within 5 s (#267) ``` The engine also dumped core twice while starting again after these. Same config as before (`--spec 2 --spec-min-p 0.5`, no `--mtp`, `--max-context 16384`, `--kv int8`, `--vram-reserve-mib 3072`, `STRATA_RESIDENT_HEADROOM_GIB=10`, `STRATA_ARENA_PIN_GIB=0`), THP `always`, the monitor on the iGPU. So short prompts are fine on 0.1.46.1, and prompts of about 8K tokens and up hit the 7-token tail. Leaving this open; happy to send the full engine log or test a build.
Author
Owner

@JustPowell commented on GitHub (Oct 20, 2026):

More data from today on 0.2.1.1 (engine 0.1.46.1), same config as above. Prompts of about 5.8K tokens hang too, so it isn't only the 8K+ ones.

Over about 33 minutes of the same automated client: 13 requests finished, 5 failed, 4 engine kills for silence (engine_silence_s 120), and the engine restarted 6 times. These are the stall reports in the engine log since the update:

stage when it stopped
reading the prompt (batched), done up to token 5771 prompt of 5,778 tokens: 7 left
reading the prompt (batched), done up to token 8104 (twice) prompt of 8,111 tokens: 7 left
reading the prompt (batched), done up to token 7296 / 8007 / 9651 prompt length not logged
reading the prompt (batched): layer 28 of the prompt chunk from token 0 at the start of a prompt
reading the prompt (verify windows), from token 8177
decode -1

Each one looks like the earlier reports: 0 layers served since the last finished step, expert pool: ... 24 of 24 jobs claimed, 24 done; 7 of 7 workers parked, 7 sleeping, threads waiting on the disk (state D): 0, about 2.9 GB VRAM free when the request began and about 9.6 GB RAM available. One retry of the 8,111-token prompt ended instead with verify: timed out at layer 21; its GPU waits were released but the GPU did not finish within 5 s (#267).

The engine also left 8 core dumps today (SIGABRT). They line up with the engine being stopped after these stalls, so they are probably the watchdog's stop rather than separate crashes. The binary is a local build without symbols, so the backtraces are empty.

For now I've moved this workload back to llama.cpp. I can still run a test build or a diagnostic run on request.

<!-- gh-comment-id:6294443552 --> @JustPowell commented on GitHub (Oct 20, 2026): More data from today on 0.2.1.1 (engine 0.1.46.1), same config as above. Prompts of about 5.8K tokens hang too, so it isn't only the 8K+ ones. Over about 33 minutes of the same automated client: 13 requests finished, 5 failed, 4 engine kills for silence (`engine_silence_s` 120), and the engine restarted 6 times. These are the stall reports in the engine log since the update: | stage when it stopped | | |---|---| | `reading the prompt (batched), done up to token 5771` | prompt of 5,778 tokens: 7 left | | `reading the prompt (batched), done up to token 8104` (twice) | prompt of 8,111 tokens: 7 left | | `reading the prompt (batched), done up to token 7296` / `8007` / `9651` | prompt length not logged | | `reading the prompt (batched): layer 28 of the prompt chunk from token 0` | at the start of a prompt | | `reading the prompt (verify windows), from token 8177` | | | `decode -1` | | Each one looks like the earlier reports: `0 layers served since the last finished step`, `expert pool: ... 24 of 24 jobs claimed, 24 done; 7 of 7 workers parked, 7 sleeping`, `threads waiting on the disk (state D): 0`, about 2.9 GB VRAM free when the request began and about 9.6 GB RAM available. One retry of the 8,111-token prompt ended instead with `verify: timed out at layer 21; its GPU waits were released but the GPU did not finish within 5 s (#267)`. The engine also left 8 core dumps today (SIGABRT). They line up with the engine being stopped after these stalls, so they are probably the watchdog's stop rather than separate crashes. The binary is a local build without symbols, so the backtraces are empty. For now I've moved this workload back to llama.cpp. I can still run a test build or a diagnostic run on request.
Author
Owner

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

Not reproduced here. This looks like the same class as #1705, #2049, #750 and #920: gfx1201 under host memory pressure (32 GB RAM, 8 GB already in swap, 3.3 million major page faults, THP always). In your stall report the engine is idle just after the batched part of the prompt, where the checkpoint is saved and the lent expert slots are refilled with async copies from host memory. Please send:

  • free -m and vmstat 1 during a stall
  • dmesg | grep -iE "kfd|amdgpu|oom|evict"
  • one run with STRATA_REFILL_BLOCKING=1 (each refill copy waits; if the stall goes, it is the queued refill copies)
  • one run with --short-read 0 (tail batched, no refill before the windows)
  • one run with HSA_USERPTR_FOR_PAGED_MEM=0, as in #1705
  • ulimit -l, and a run with --resident-experts against --mmap-experts
<!-- gh-comment-id:6308093442 --> @Niko1221 commented on GitHub (Oct 21, 2026): Not reproduced here. This looks like the same class as #1705, #2049, #750 and #920: gfx1201 under host memory pressure (32 GB RAM, 8 GB already in swap, 3.3 million major page faults, THP always). In your stall report the engine is idle just after the batched part of the prompt, where the checkpoint is saved and the lent expert slots are refilled with async copies from host memory. Please send: - `free -m` and `vmstat 1` during a stall - `dmesg | grep -iE "kfd|amdgpu|oom|evict"` - one run with `STRATA_REFILL_BLOCKING=1` (each refill copy waits; if the stall goes, it is the queued refill copies) - one run with `--short-read 0` (tail batched, no refill before the windows) - one run with `HSA_USERPTR_FOR_PAGED_MEM=0`, as in #1705 - `ulimit -l`, and a run with `--resident-experts` against `--mmap-experts`
Author
Owner

@JustPowell commented on GitHub (Oct 23, 2026):

Update on 0.2.2 (engine 0.1.47, local HIP build for gfx1201), with a second card. Your memory-pressure reading fits what I see: the stall is still there on 0.2.2 when the experts don't fit in VRAM, and gone when they do.

The machine now has a Radeon AI PRO R9700 (32 GB, also gfx1201) beside the RX 9070 XT (16 GB), still 32 GB of RAM, zram swap, THP always. Same model and settings as before (--spec 2 --spec-min-p 0.5, --resident-experts, --kv int8, --max-context 16384, --vram-reserve-mib 3072, STRATA_RESIDENT_HEADROOM_GIB=10, STRATA_ARENA_PIN_GIB=0, STRATA_RESIDENT_PIN=0, engine_silence_s 120). The test client sends one request at a time: prompts of 4.9K to 15.1K tokens, 200-token replies. I switched cards with gpu_roles.

cards experts in VRAM requests ok time per request decode lowest free RAM
R9700 alone 12,288 (23.4 GiB) 13 of 13 8-18 s ~73 tok/s 13.6 GB
R9700 Main + 9070 XT Helper expert cache 4,569 (8.2 GiB), plus the layers on the Main card 15 of 15 9-17 s 52-60 tok/s 13.0 GB
9070 XT alone 4,495 (8.6 GiB) 2 of 4, then I stopped it 29-36 s for the two that finished 0.4 GB, 17.8 GB in swap

The Main/Helper roles worked as described: card roles: Main GPU 1, Helper GPU 0, layer split across [0, 1].

On the 9070 XT alone, the first failure came back as a 503 after 301 s. The second ended after 176 s, when the server stopped the engine (exit code -9) after 120 s without output and started it again. The engine log has the same stall as before, now 5 tokens from the end of the prompt:

strata serve: stall report (engine 0.1.47): stage "reading the prompt (batched), done up to token 10455" for 61 s; 0 layers served since the last finished step (0 = stopped, more = slow)
  expert pool: epoch 9982, batch epoch 9982: 24 of 24 jobs claimed, 24 done; 7 of 7 workers parked, 7 sleeping; mode 0
  threads waiting on the disk (state D): 0 of 40

(prompt of 10,460 tokens). strata-host also dumped core once, when it was restarted.

The diagnostics you asked for, from that run:

  • free -m during the stall: 31,190 total, 21,809 used, 447 free, 9,381 available; swap 17,833 of 31,189 used.
  • vmstat 1 was running throughout (I have the full log if you want it).
  • No kfd or amdgpu lines in the kernel log. There were page allocation failure: order:0 warnings (warn_alloc, from kswapd0 and from other processes) but no OOM kill.
  • ulimit -l: 8192.

I stopped that run early because the desktop was close to running out of memory. I haven't done the flag runs yet (STRATA_REFILL_BLOCKING=1, --short-read 0, HSA_USERPTR_FOR_PAGED_MEM=0, --mmap-experts against --resident-experts). I can do them on the 9070 XT alone if they would still help, but I'd want to cap the engine's memory for those first. For my own use I'll keep the R9700 as Main, where this doesn't happen.

<!-- gh-comment-id:6355386362 --> @JustPowell commented on GitHub (Oct 23, 2026): Update on 0.2.2 (engine 0.1.47, local HIP build for gfx1201), with a second card. Your memory-pressure reading fits what I see: the stall is still there on 0.2.2 when the experts don't fit in VRAM, and gone when they do. The machine now has a Radeon AI PRO R9700 (32 GB, also gfx1201) beside the RX 9070 XT (16 GB), still 32 GB of RAM, zram swap, THP `always`. Same model and settings as before (`--spec 2 --spec-min-p 0.5`, `--resident-experts`, `--kv int8`, `--max-context 16384`, `--vram-reserve-mib 3072`, `STRATA_RESIDENT_HEADROOM_GIB=10`, `STRATA_ARENA_PIN_GIB=0`, `STRATA_RESIDENT_PIN=0`, `engine_silence_s` 120). The test client sends one request at a time: prompts of 4.9K to 15.1K tokens, 200-token replies. I switched cards with `gpu_roles`. | cards | experts in VRAM | requests ok | time per request | decode | lowest free RAM | |---|---|---|---|---|---| | R9700 alone | 12,288 (23.4 GiB) | 13 of 13 | 8-18 s | ~73 tok/s | 13.6 GB | | R9700 Main + 9070 XT Helper | expert cache 4,569 (8.2 GiB), plus the layers on the Main card | 15 of 15 | 9-17 s | 52-60 tok/s | 13.0 GB | | 9070 XT alone | 4,495 (8.6 GiB) | 2 of 4, then I stopped it | 29-36 s for the two that finished | | 0.4 GB, 17.8 GB in swap | The Main/Helper roles worked as described: `card roles: Main GPU 1, Helper GPU 0`, layer split across [0, 1]. On the 9070 XT alone, the first failure came back as a 503 after 301 s. The second ended after 176 s, when the server stopped the engine (exit code -9) after 120 s without output and started it again. The engine log has the same stall as before, now 5 tokens from the end of the prompt: ``` strata serve: stall report (engine 0.1.47): stage "reading the prompt (batched), done up to token 10455" for 61 s; 0 layers served since the last finished step (0 = stopped, more = slow) expert pool: epoch 9982, batch epoch 9982: 24 of 24 jobs claimed, 24 done; 7 of 7 workers parked, 7 sleeping; mode 0 threads waiting on the disk (state D): 0 of 40 ``` (prompt of 10,460 tokens). `strata-host` also dumped core once, when it was restarted. The diagnostics you asked for, from that run: - `free -m` during the stall: 31,190 total, 21,809 used, 447 free, 9,381 available; swap 17,833 of 31,189 used. - `vmstat 1` was running throughout (I have the full log if you want it). - No `kfd` or `amdgpu` lines in the kernel log. There were `page allocation failure: order:0` warnings (`warn_alloc`, from kswapd0 and from other processes) but no OOM kill. - `ulimit -l`: 8192. I stopped that run early because the desktop was close to running out of memory. I haven't done the flag runs yet (`STRATA_REFILL_BLOCKING=1`, `--short-read 0`, `HSA_USERPTR_FOR_PAGED_MEM=0`, `--mmap-experts` against `--resident-experts`). I can do them on the 9070 XT alone if they would still help, but I'd want to cap the engine's memory for those first. For my own use I'll keep the R9700 as Main, where this doesn't happen.
Author
Owner

@manakjiri commented on GitHub (Oct 23, 2026):

Another data point on gfx1100, with a clean A/B: on our setup the stall only happens while the adaptive tier swaps experts, and --adapt-every 100000 (swaps effectively off) makes it go away.

Setup: Strata 0.1.44.1, local HIP build for gfx1100 (engine src 7dfd34378bd2d32a). Single RX 7900 XT (20 GB) passed through to a Proxmox VM, no display attached. ROCm 7.2.4, kernel 7.2.9-arch1-1, 48 GiB RAM, no swap, THP always, ulimit -l 8192. Qwen3.8-Flash-Next IQ3_S native pack, --expert-cache auto --prefill auto --spec 4 --spec-min-p 0.5 --mtp ... --max-context 131072 --kv int8 --resident-experts --kv-resident 32768 --vision --vram-reserve-mib 700, env STRATA_RESIDENT_PIN=0 STRATA_RESIDENT_HEADROOM_GIB=6 HSA_USERPTR_FOR_PAGED_MEM=0. The client is a pi harness, one request at a time, prompts mostly 15K-105K tokens with conversation reuse.

A/B, same config and traffic, only --adapt-every changed:

--adapt-every period requests stalls
100000 2026-10-14 to 10-22 (8 days) 17,600 0
default 2026-10-23, 5.5 h 569 10

The ten stalls, from the engine's stall reports, all with "0 layers served since the last finished step":

  • reading the prompt (batched), done up to token N for N = 15588, 20441, 25527 (prompt of 25,534: 7 left), 30417, 31978, 35925, 104677
  • reading the prompt (batched): layer 26 of the prompt chunk from token 25020 and layer 15 ... from token 21604
  • once verify window: waiting for the GPU to finish the window (flags A/B/M raised) 6

The server ended them as no progress for 60 s (exit -6), engine said nothing for 300 s, or "frozen" (no CPU or disk for 180 s). VRAM free when each stalled request began was 485 MiB. The kernel log has no kfd/amdgpu/OOM/evict lines in that window, and the VM had about 5.5 GiB of RAM available with no swap, so this is not host swapping.

We saw the same split earlier on 0.1.40.1 with kernel 6.19.8 and ROCm 7.2.0: 17 stalls in 1,900 requests with the adaptive tier at its defaults, 0 in 2,845 with --adapt-every 100000. Both arms there also had HSA_ENABLE_SDMA=0 and HSA_USERPTR_FOR_PAGED_MEM=0 (#1705), so neither prevents it on its own.

We are behind the current release. If it helps, I can update to 0.2.3 and run the adaptive tier at its defaults with STRATA_REFILL_BLOCKING=1, then with --short-read 0.

<!-- gh-comment-id:6366264520 --> @manakjiri commented on GitHub (Oct 23, 2026): Another data point on gfx1100, with a clean A/B: on our setup the stall only happens while the adaptive tier swaps experts, and `--adapt-every 100000` (swaps effectively off) makes it go away. **Setup:** Strata 0.1.44.1, local HIP build for gfx1100 (engine `src` 7dfd34378bd2d32a). Single RX 7900 XT (20 GB) passed through to a Proxmox VM, no display attached. ROCm 7.2.4, kernel 7.2.9-arch1-1, 48 GiB RAM, no swap, THP `always`, `ulimit -l` 8192. Qwen3.8-Flash-Next IQ3_S native pack, `--expert-cache auto --prefill auto --spec 4 --spec-min-p 0.5 --mtp ... --max-context 131072 --kv int8 --resident-experts --kv-resident 32768 --vision --vram-reserve-mib 700`, env `STRATA_RESIDENT_PIN=0 STRATA_RESIDENT_HEADROOM_GIB=6 HSA_USERPTR_FOR_PAGED_MEM=0`. The client is a pi harness, one request at a time, prompts mostly 15K-105K tokens with conversation reuse. **A/B, same config and traffic, only `--adapt-every` changed:** | `--adapt-every` | period | requests | stalls | | --- | --- | ---: | ---: | | 100000 | 2026-10-14 to 10-22 (8 days) | 17,600 | 0 | | default | 2026-10-23, 5.5 h | 569 | 10 | The ten stalls, from the engine's stall reports, all with "0 layers served since the last finished step": - `reading the prompt (batched), done up to token N` for N = 15588, 20441, 25527 (prompt of 25,534: 7 left), 30417, 31978, 35925, 104677 - `reading the prompt (batched): layer 26 of the prompt chunk from token 25020` and `layer 15 ... from token 21604` - once `verify window: waiting for the GPU to finish the window (flags A/B/M raised) 6` The server ended them as `no progress for 60 s` (exit -6), `engine said nothing for 300 s`, or "frozen" (no CPU or disk for 180 s). VRAM free when each stalled request began was 485 MiB. The kernel log has no kfd/amdgpu/OOM/evict lines in that window, and the VM had about 5.5 GiB of RAM available with no swap, so this is not host swapping. We saw the same split earlier on 0.1.40.1 with kernel 6.19.8 and ROCm 7.2.0: 17 stalls in 1,900 requests with the adaptive tier at its defaults, 0 in 2,845 with `--adapt-every 100000`. Both arms there also had `HSA_ENABLE_SDMA=0` and `HSA_USERPTR_FOR_PAGED_MEM=0` (#1705), so neither prevents it on its own. We are behind the current release. If it helps, I can update to 0.2.3 and run the adaptive tier at its defaults with `STRATA_REFILL_BLOCKING=1`, then with `--short-read 0`.
Author
Owner

@Niko1221 commented on GitHub (Nov 5, 2026):

Thanks for taking the time to report this.

Strata has changed a lot since this was opened, and 0.2.11 is out now, so many older reports no longer apply. We're closing issues older than a week that have had no new reports in the last week. Closed here does not mean rejected.

To reopen it takes about two minutes:

  1. Re-test on 0.2.11. It may already be fixed. Write down what you see.
  2. Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other].
  3. Fill in the parts of the issue form: what happened, the Strata version, your graphics card, memory and system.
  4. Comment /reopen. A check runs and either reopens the issue or lists what is still missing.

The rules are in CONTRIBUTING.md.

<!-- gh-comment-id:6659446377 --> @Niko1221 commented on GitHub (Nov 5, 2026): Thanks for taking the time to report this. Strata has changed a lot since this was opened, and 0.2.11 is out now, so many older reports no longer apply. We're closing issues older than a week that have had no new reports in the last week. Closed here does not mean rejected. To reopen it takes about two minutes: 1. Re-test on 0.2.11. It may already be fixed. Write down what you see. 2. Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other]. 3. Fill in the parts of the issue form: what happened, the Strata version, your graphics card, memory and system. 4. Comment `/reopen`. A check runs and either reopens the issue or lists what is still missing. The rules are in [CONTRIBUTING.md](https://github.com/Niko1221/Strata/blob/main/CONTRIBUTING.md).
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#1338
No description provided.