mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #29] Critical bug + Performance report RTX 4090 #15
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#15
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Lufen34 on GitHub (Sep 27, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/29
Hello ! Thank you for your work. I am really impressed by the result so far 💪
Here is my system :
OS : Cachyos (linux)
Hardware : RTX 4090 + 192 GB of RAM + AMD R9 7950X3D
version running : 0.1.9
command I run :
Performance start at 75 token/s degrades slowly around 55 tok/s when it reaches a big amount of token generation which is expected and very impressive.
I do get a bug tho, everytime It reaches a certain amount of token, my cpu suddenly stop working and my gpu stays indefinitively running/processing at 100% but no more token is generated as show here :
The prompt I used to make him spill a lot of tokens :
prompt.md
Edit : just for clarity I still have enough VRAM room and plenty of RAM left
@Lufen34 commented on GitHub (Sep 27, 2026):
this might have been fixed and the Strata v0.1.10 so I give it a try again
@Lufen34 commented on GitHub (Sep 27, 2026):
Issue still present, this time way earlier :(
[strata] thinking: 6767 of max 128000 tokens, 71.7 tok/s, 113 s
[strata] thinking: 6819 of max 128000 tokens, 71.5 tok/s, 114 s
[strata] thinking: 6879 of max 128000 tokens, 71.4 tok/s, 115 s
[strata] thinking: 6961 of max 128000 tokens, 71.5 tok/s, 116 s
[strata] thinking: 7014 of max 128000 tokens, 71.3 tok/s, 117 s
[strata] thinking: 7081 of max 128000 tokens, 71.2 tok/s, 118 s
[strata] thinking: 7162 of max 128000 tokens, 71.3 tok/s, 119 s
[strata] thinking: 7220 of max 128000 tokens, 71.2 tok/s, 120 s
[strata] thinking: 7268 of max 128000 tokens, 70.9 tok/s, 121 s
[strata] thinking: 7329 of max 128000 tokens, 70.8 tok/s, 122 s
[strata] thinking: 7417 of max 128000 tokens, 71.0 tok/s, 123 s
[strata] thinking: 7487 of max 128000 tokens, 71.0 tok/s, 124 s
[strata] thinking: 7556 of max 128000 tokens, 71.0 tok/s, 125 s
[strata] thinking: 7624 of max 128000 tokens, 70.9 tok/s, 126 s
[strata] thinking: 7687 of max 128000 tokens, 65.0 tok/s, 137 s
[strata] thinking: 7687 of max 128000 tokens, 59.9 tok/s, 147 s
[strata] thinking: 7687 of max 128000 tokens, 55.6 tok/s, 157 s
[strata] thinking: 7687 of max 128000 tokens, 51.8 tok/s, 167 s
[strata] thinking: 7687 of max 128000 tokens, 48.6 tok/s, 177 s
[strata] thinking: 7687 of max 128000 tokens, 45.7 tok/s, 187 s
, [strata] thinking: 7687 of max 128000 tokens, 43.1 tok/s, 197 s
@Niko1221 commented on GitHub (Sep 27, 2026):
I know the reason, will be patched withing 1-2hrs from now!
@Niko1221 commented on GitHub (Sep 27, 2026):
Could you please change kv-cache by not using int? Tell me if it works.
@Lufen34 commented on GitHub (Sep 27, 2026):
Testing now :)
@Lufen34 commented on GitHub (Sep 27, 2026):
Same issue with Q4_0 :
[strata] thinking: 8611 of max 128000 tokens, 69.7 tok/s, 142 s
[strata] thinking: 8675 of max 128000 tokens, 69.6 tok/s, 143 s
[strata] thinking: 8741 of max 128000 tokens, 69.5 tok/s, 144 s
[strata] thinking: 8799 of max 128000 tokens, 69.5 tok/s, 145 s
[strata] thinking: 8859 of max 128000 tokens, 69.4 tok/s, 146 s
[strata] thinking: 8926 of max 128000 tokens, 69.4 tok/s, 147 s
[strata] thinking: 8993 of max 128000 tokens, 69.3 tok/s, 148 s
[strata] thinking: 9068 of max 128000 tokens, 69.4 tok/s, 149 s
[strata] thinking: 9132 of max 128000 tokens, 64.5 tok/s, 160 s
[strata] thinking: 9132 of max 128000 tokens, 60.2 tok/s, 170 s
[strata] thinking: 9132 of max 128000 tokens, 56.5 tok/s, 180 s
[strata] thinking: 9132 of max 128000 tokens, 53.2 tok/s, 190 s
@Niko1221 commented on GitHub (Sep 27, 2026):
Thanks a lot for the detailed report and the screenshots. The GPU at 100% but only 91 W, with exactly one CPU core busy, pinned it down: the GPU and the engine's host thread were each waiting for the other.
What we found: a race in the CPU expert pool.
Fixed in v0.1.12:
I couldn't make it hang on my 12 GB card, even with a stress build that makes the workers sleep constantly: 37K tokens on the old engine, and 25K on the new one at 262K with KV streaming, with no stall. So your run is the real test. Please update (
git pull, then run setup again to get engine 0.1.12) and try your prompt. If it ever stops again, the log will containno progress for 120 s ... (issue #29)with the stage; please reopen this and paste that line. Closing for now.@Lufen34 commented on GitHub (Sep 27, 2026):
Haha I just tested but this time Instead of hanging it just stop abruptly.
CPU and gpu are not stuck or processing anymore however I still get the issue at the same range the following issue :
Also My peak token generation increased drastically, which is good news haha.
If I can help in anyway please, let me know :)
@Lufen34 commented on GitHub (Sep 27, 2026):
"please reopen this and paste that line. Closing for now."
@Niko1221 Sorry I don't have the permission to reopen it :)
edit: Good news is that now performance isn't droping over time, I am under constant 70tok/s 🥳
I am trying to generate multiple time see if this bug happens a lot or not
@Lufen34 commented on GitHub (Sep 27, 2026):
It's okay problem is solved, got just an unlucky run I guess. Thank you for your work 💪
@Lufen34 commented on GitHub (Sep 27, 2026):
@Niko1221 Sorry to ping you, just wanted to let you know the same issue is back again :
took me a while tho this time
@Niko1221 commented on GitHub (Sep 27, 2026):
Did you update the engine when commited for #31 or is this on one prior?
@Lufen34 commented on GitHub (Sep 27, 2026):
This was on version 0.1.12 😁
@marcosandresacevedo commented on GitHub (Sep 28, 2026):
Ran in to this as well.
Windows 10.
4080 Super 16GB VRAM.
64GB System RAM DDR4 3600.
11700K CPU.
Using Swift-Qwen3.8-Flash-Next-GSQ-RCO-IQ2_XS.
strata serve: no progress for 120 s during a request (verify window: the CPU experts of layer 7) - stopping the engine so the server starts it again (issue #29)Command used to run it:
.\START-HERE.bat --setup --family swift --model IQ2_XS --context 262144 --kv int8 --vision cpu --host 0.0.0.0Context fill was at 99k / 256K.
@Niko1221 commented on GitHub (Sep 28, 2026):
Thanks, and no need to apologise for the ping. Please keep them coming.
Your screenshots show the old signature exactly: the counter frozen at 3,987, the GPU at 100% but 83 W, the CPU idle. But one thing is missing. Engine 0.1.12 ends a request that stops moving after 120 s and writes
no progress for 120 sto the log, and yours stayed frozen for over three minutes. So the engine that ran was most likely older than 0.1.12.On Linux,
git pull+./setup.shdid not recompile an engine you had compiled before (issue #31, fixed since). So the update may never have reached the engine.Please:
git pull, then./setup.sh. It now sees that the source changed and recompiles (a few minutes).session is up (engine 0.1.13).v0.1.13 also stops a stuck request after 60 s and prints a stall report under the
no progressline. If it happens again, please paste that whole block here. I've reopened the issue until we know.For the reasoning loops (
q=?? q=??), set a presence penalty, as in #31: per request"presence_penalty": 1.0, or for every client"sampling": {"presence_penalty": 1.0}in yourstrata-*.json. Qwen recommends 0-2 against endless repetition, and Strata applies it at any temperature.@Lufen34 commented on GitHub (Sep 28, 2026):
Alright ! I'll give it a try this afternoon again 😁
@Lufen34 commented on GitHub (Sep 28, 2026):
Trying now, I upgraded to version 0.1.13 :) rebuild with cmake locally but I had an error with this version :
So I temporarly fixed it locally so I could test by doing :
Keep you in touch !
Edit: I saw you are already aware of this issue in https://github.com/Niko1221/Strata/issues/49#issue-5611974257
@Lufen34 commented on GitHub (Sep 28, 2026):
I’m starting to wonder whether what I’m seeing might actually be normal behavior rather than the bug still occurring.
In this screenshot, I noticed symptoms similar to what I previously interpreted as the stall: while Strata is "reading the prompt" or "writing tools", GPU usage stays at 100%, while CPU usage can be very low and sometimes appears to involve only a single core.
However, unlike the actual stalls I saw before, it eventually continues by itself. This makes me wonder whether I may have been misinterpreting normal processing as the bug.
For example, I see output like:
At the same time, Task Manager/system monitoring may show roughly:
One thing I may have misunderstood: what exactly does
210194 tokensrepresent here?Does it mean Strata still has to process all 210,194 tokens before generation can begin, or is that simply the total prompt/context size for the current request, while some portion of it may already be reused from the conversation cache?
If it is the latter, that would probably explain much of my confusion.
So far on 0.1.13 I haven’t seen it remain completely stuck for ~15 minutes like the original issue. The apparent "stalls" I have seen eventually recovered on their own, so it’s possible I was mistaking normal prompt/tool processing for the original deadlock.
@marcosandresacevedo Could you tell me what version were you running when that issue occured ?
@Niko1221 commented on GitHub (Sep 28, 2026):
@Lufen34 yes, what you see there is normal:
210194 tokenswas the whole prompt's size, including the part reused from the conversation cache, and reading a long prompt is GPU work (100% GPU, one CPU core feeding it). 0.1.14 prints how far it is (reading the prompt: 196,608 of 210,194 tokens). A real stall is different: nothing moves for 60 s and the engine stops itself with a report (since 0.1.12), it never sits for 15 minutes any more.@marcosandresacevedo your stall ("verify window: the CPU experts of layer 7", IQ2_XS) has the same signature as #31's, which now has thread dumps: the host was stuck in the driver while issuing the DMA copies of a native pack inside a verify window. 0.1.14 uses the copy kernel instead (no host CUDA call there, ~1% slower). (On 0.1.13,
--pcie-mode kernelin the config's args does the same.) @Lufen34 the same applies to your IQ3_S run on Linux; and on Linux, 0.1.13 needed a fix to compile at all (#include <cmath>, #49) - 0.1.14 has it.Closing this with 0.1.14. If a request stops again on 0.1.14, please reopen it with the stall report from the log.
@marcosandresacevedo commented on GitHub (Sep 28, 2026):
@Niko1221 I was using version 0.1.12 when it happened (
github.com/Niko1221/Strata@481e0cd508). One thing I tried to do recently was to let it redownload and rebuild the model (rather than copying the model from the models it downloaded in previous versions). Have not experienced this issue after that with Kilo Code in 0.1.12. I occasionally hook OpenWebUI and Cherry Studio and using those clients is where the issue manifested in 0.1.12 and prior versions.I'll pull the latest commit today, let it fully download, let it build the models and report back if this shows up again.
@Lufen34 commented on GitHub (Sep 28, 2026):
For me it's just working now, no more pinning 😁
@qianchong666 commented on GitHub (Sep 30, 2026):
Follow-up from a Windows box, on 0.1.27 -- same stall family as @marcosandresacevedo's report above, but here it reproduces on the very first request, every time.Box: Windows 10, 2x RTX 3090 (24 GB, sm_86), 128 GB RAM, driver 610.62, i5-14600K (AVX2 only).Model: Qwen3.8-Flash-Next-GSQ-RCO-IQ3_XXS (2 shards, 85.2 GB), official installer, engine 0.1.27.The stall report the README asks for, verbatim every time:
strata serve: no progress for 60 s during a request (reading the prompt, from token 0) - stopping the engine so the server starts it again (issue #29)strata serve: stall report (engine 0.1.27): stage "reading the prompt, from token 0" for 60 s; 0 layers served since the last finished step (0 = stopped, more = slow) expert pool: epoch 0, batch epoch 0: 0 of 0 jobs claimed, 0 done; 13 of 13 workers parked, 13 sleeping; mode 0 expert pool threads: w0=sleeping w1=sleeping ... w12=sleeping; host idle for 100469 ms verify window: 6 tokens at position 0, host at layer step 1; the GPU rang 1; flags: served 0, plan (A) 0, copies (B) 0 memory: 2312 MiB resident, 68256 MiB committed, 65940 MiB RAM available; 1869811 page faults so far wrote the thread stacks to E:\Strata-main\strata-stall-142088.dmp (attach it to the issue)Two things I read out of it:- the pool never receives work: 13 of 13 parked, 0 of 0 jobs claimed, host idle for 100 s;- the GPU rang once and the host side never answered: served 0, plan (A) 0, copies (B) 0.So the host is stuck on its own side of the verify handshake, before any expert copy is issued. That is #31's neighbourhood, but 0.1.27 is well past the 0.1.14 kernel-copy fix -- and--pcie-modeis not in the 0.1.27 help, so is the DMA path gone for good or renamed?The host arena is also degraded on this box, but it is not what decides the stall:- default:cudaHostRegister of the whole arena FAILED (out of memory)-> 48 slices pinned (39 GiB);- with the 8 GiB cap engaged (--expert-cache-device1 5000plus a card that runs no stage):cudaHostRegister limited to 8 GiB for CUDA1, 10 slices pinned (7 GiB) -> still stalls identically.18 configurations tested, each changing one thing:--no-host-worker,--sync-every-layer,--no-hit-poke,--kv q4_0,--prefill 64,--ple-inflight 1,--ple-io mmap|pread,--mmap-experts(canonical--experts-binpack),--spec 1,--no-capture,--no-pool,--expert-cache-remote-placement layer, single card, swapped card order, and SeLockMemoryPrivilege granted (VirtualLock locked 2 MiFollow-up from a Windows box, on **0.1.27** -- same stall family as @marcosandresacevedo's report above, but here it reproduces on the **very first request**, every time.Box: Windows 10, 2x RTX 3090 (24 GB, sm_86), 128 GB RAM, driver 610.62, i5-14600K (AVX2 only).Model: Qwen3.8-Flash-Next-GSQ-RCO-IQ3_XXS (2 shards, 85.2 GB), official installer, engine 0.1.27.The stall report the README asks for, verbatim every time:```strata serve: no progress for 60 s during a request (reading the prompt, from token 0) - stopping the engine so the server starts it again (issue #29)strata serve: stall report (engine 0.1.27): stage "reading the prompt, from token 0" for 60 s; 0 layers served since the last finished step (0 = stopped, more = slow) expert pool: epoch 0, batch epoch 0: 0 of 0 jobs claimed, 0 done; 13 of 13 workers parked, 13 sleeping; mode 0 expert pool threads: w0=sleeping w1=sleeping ... w12=sleeping; host idle for 100469 ms verify window: 6 tokens at position 0, host at layer step 1; the GPU rang 1; flags: served 0, plan (A) 0, copies (B) 0 memory: 2312 MiB resident, 68256 MiB committed, 65940 MiB RAM available; 1869811 page faults so far wrote the thread stacks to E:\Strata-main\strata-stall-142088.dmp (attach it to the issue)```Two things I read out of it:- the pool never receives work: 13 of 13 parked, **0 of 0 jobs claimed**, host idle for 100 s;- the GPU rang once and the host side never answered: **served 0, plan (A) 0, copies (B) 0**.So the host is stuck on its own side of the verify handshake, before any expert copy is issued. That is #31's neighbourhood, but 0.1.27 is well past the 0.1.14 kernel-copy fix -- and--pcie-modeis not in the 0.1.27 help, so is the DMA path gone for good or renamed?The host arena is also degraded on this box, but it is not what decides the stall:- default:cudaHostRegister of the whole arena FAILED (out of memory)-> 48 slices pinned (39 GiB);- with the 8 GiB cap engaged (--expert-cache-device1 5000plus a card that runs no stage):cudaHostRegister limited to 8 GiB for CUDA1, 10 slices pinned (7 GiB) -> **still stalls identically**.18 configurations tested, each changing one thing:--no-host-worker,--sync-every-layer,--no-hit-poke,--kv q4_0,--prefill 64,--ple-inflight 1,--ple-io mmap|pread,--mmap-experts(canonical--experts-binpack),--spec 1,--no-capture,--no-pool,--expert-cache-remote-placement layer, single card, swapped card order, and SeLockMemoryPrivilege granted (VirtualLock locked 2 MiB in 4.0 ms). All 18 stop with 0 tokens.Environment against your own checks (setup.py): driver 610.62 (>= MIN_DRIVER 580), compute capability 8.6, 24 GB VRAM, 127.7 GB RAM, ~195 GB page file, AVX2 present. The engine itself printsthis CPU has no AVX-512: the expert kernels run on AVX-2-- that is the only difference I can see against your reference boxes.16 thread-stack dumps from these runs are ready (~200 KB each, 3.3 MB zipped). Say the word and I attach them.Happy to run any build you point me at -- the box is idle and both cards are free.Follow-up from a Windows box, on **0.1.27** -- same stall family as @marcosandresacevedo's report above, but here it reproduces on the **very first request**, every time.Box: Windows 10, 2x RTX 3090 (24 GB, sm_86), 128 GB RAM, driver 610.62, i5-14600K (AVX2 only).Model: Qwen3.8-Flash-Next-GSQ-RCO-IQ3_XXS (2 shards, 85.2 GB), official installer, engine 0.1.27.The stall report the README asks for, verbatim every time:```strata serve: no progress for 60 s during a request (reading the prompt, from token 0) - stopping the engine so the server starts it again (issue #29)strata serve: stall report (engine 0.1.27): stage "reading the prompt, from token 0" for 60 s; 0 layers served since the last finished step (0 = stopped, more = slow) expert pool: epoch 0, batch epoch 0: 0 of 0 jobs claimed, 0 done; 13 of 13 workers parked, 13 sleeping; mode 0 expert pool threads: w0=sleeping w1=sleeping ... w12=sleeping; host idle for 100469 ms verify window: 6 tokens at position 0, host at layer step 1; the GPU rang 1; flags: served 0, plan (A) 0, copies (B) 0 memory: 2312 MiB resident, 68256 MiB committed, 65940 MiB RAM available; 1869811 page faults so far wrote the thread stacks to E:\Strata-main\strata-stall-142088.dmp (attach it to the issue)```Two things I read out of it:- the pool never receives work: 13 of 13 parked, **0 of 0 jobs claimed**, host idle for 100 s;- the GPU rang once and the host side never answered: **served 0, plan (A) 0, copies (B) 0**.So the host is stuck on its own side of the verify handshake, before any expert copy is issued. That is #31's neighbourhood, but 0.1.27 is well past the 0.1.14 kernel-copy fix -- and--pcie-modeis not in the 0.1.27 help, so is the DMA path gone for good or renamed?The host arena is also degraded on this box, but it is not what decides the stall:- default:cudaHostRegister of the whole arena FAILED (out of memory)-> 48 slices pinned (39 GiB);- with the 8 GiB cap engaged (--expert-cache-device1 5000plus a card that runs no stage):cudaHostRegister limited to 8 GiB for CUDA1, 10 slices pinned (7 GiB) -> **still stalls identically**.18 configurations tested, each changing one thing:--no-host-worker,--sync-every-layer,--no-hit-poke,--kv q4_0,--prefill 64,--ple-inflight 1,--ple-io mmap|pread,--mmap-experts(canonical--experts-binpack),--spec 1,--no-capture,--no-pool,--expert-cache-remote-placement layer, single card, swapped card order, and SeLockMemoryPrivilege granted (VirtualLock locked 2 MiB in 4.0 ms). All 18 stop with 0 tokens.Environment against your own checks (setup.py): driver 610.62 (>= MIN_DRIVER 580), compute capability 8.6, 24 GB VRAM, 127.7 GB RAM, ~195 GB page file, AVX2 present. The engine itself printsthis CPU has no AVX-512: the expert kernels run on AVX-2` -- that is the only difference I can see against your reference boxes.16 thread-stack dumps from these runs are ready (~200 KB each, 3.3 MB zipped). Say the word and I attach them.Happy to run any build you point me at -- the box is idle and both cards are free.B in 4.0 ms
). All 18 stop with 0 tokens.Environment against your own checks (setup.py): driver 610.62 (>= MIN_DRIVER 580), compute capability 8.6, 24 GB VRAM, 127.7 GB RAM, ~195 GB page file, AVX2 present. The engine itself printsthis CPU has no AVX-512: the expert kernels run on AVX-2` -- that is the only difference I can see against your reference boxes.16 thread-stack dumps from these runs are ready (~200 KB each, 3.3 MB zipped). Say the word and I attach them.Happy to run any build you point me at -- the box is idle and both cards are free.@shaoyanji commented on GitHub (Nov 4, 2026):
Same guard, different stage than the decode stall that closed this: filed as #5229.
On a gfx1010 HIP build (0.1.46.2, binary 2026-10-21) the engine stops itself during a prefill, reproducibly:
Three agent-suite runs, three stall sites: 9076, 9121, 9063 — same pack, same layer, on every quantisation level (IQ1_M, IQ2_XS, IQ3_XXS). 4K prompts never stall, ~9k turns never stall, and it is not memory or VRAM (
oom_kill0, 636 MiB of VRAM free at load on the run that stalled). Numbers, repro and the questions I have are in #5229.