Skip to content

TensorRT Edge-LLM 0.4.0 release - #3

Merged
nvluxiaoz merged 1 commit into
NVIDIA:mainfrom
nvluxiaoz:dev-release/0.4.0
Jan 5, 2026
Merged

nvluxiaoz merged 1 commit into
NVIDIA:mainfrom
nvluxiaoz:dev-release/0.4.0

Conversation

@nvluxiaoz

Copy link
Copy Markdown
Collaborator

No description provided.

@nvluxiaoz
nvluxiaoz merged commit 50a61d0 into NVIDIA:main Jan 5, 2026
@nvluxiaoz
nvluxiaoz deleted the dev-release/0.4.0 branch January 5, 2026 19:39
suharvest added a commit to suharvest/TensorRT-Edge-LLM that referenced this pull request May 22, 2026
Codex final audit (finding #1) identified that the slot pool ALREADY
allocates per-slot IExecutionContext pairs (cpp:1914-1915 CP,
:2952-2953 Talker), but the hot path in three call sites
unconditionally falls back to the engine-global mPrefillContext /
mDecodeContext whenever no explicit ctxOverride is passed:

  - CP generatePreparedInputs at cpp:1099-1100
  - Talker prefill at cpp:2339-2341
  - Talker decode at cpp:2508

Two concurrent handleAudioGeneration calls pass `slot != nullptr` but
not `ctxOverride`, so both threads enqueueV3 against the SAME IContext.
TRT IExecutionContext is not safe for concurrent enqueue — each call
mutates input shapes, tensor address bindings, and profile index.
That is the cumulative-state-corruption root cause behind the
cudaMemsetAsync(state.read.rawPointer(), ...) illegal-access errors
observed after 2-3 N=2 bursts under the prior C1+C2+C3+C5 config.

Fix: in each of the three sites, when slot is non-null and owns a
context, route through slot->prefillCtxOwned.get() /
decodeCtxOwned.get() — keeping ctxOverride priority for the legacy
captureDecodingCUDAGraph path. ~10-15 LOC.

Empirical post-fix (orin-nx, profile jetson-multilang-highperf-nx,
OVS_TTS_WORKER_CONCURRENCY=2, max_workers=2):
  - 30 sustained N=2 dual-client bursts: zero broken-state TTFAs
  - Mid-stress + post-stress N=1 audio MD5 = baseline
    f515a4376962cca876f21089130d7253 (byte-identical)
  - Audio quality preserved across the full gauntlet

Caveat: throughput is now lower than the C2-first-burst peak. slow-
client TTFA p50 ~4× single-client baseline, vs 1.4× pre-C6. That's
likely findings NVIDIA#2 (slot reused mid-request) + NVIDIA#3 (resetSampling
mutates all slots) from the audit — coming in follow-up commits.
This commit closes the CRASH path; the THROUGHPUT path needs the
remaining audit items addressed.

Signed-off-by: suharvest <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants