Skip to content

fix(cuda-graphs): preserve nested static input buffers - #5931

Draft
FDecaYed wants to merge 1 commit into
NVIDIA:mainfrom
FDecaYed:codex/full-cudagraph-nested-static-buffers
Draft

fix(cuda-graphs): preserve nested static input buffers#5931
FDecaYed wants to merge 1 commit into
NVIDIA:mainfrom
FDecaYed:codex/full-cudagraph-nested-static-buffers

Conversation

@FDecaYed

@FDecaYed FDecaYed commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

What

Make full-CUDA-graph input refresh recursively reuse compatible static tensors inside tuples, lists, and dictionaries. Scalars and incompatible entries are replaced, while reusable tensors keep their object identity and storage.

This helper fix is self-contained and is intentionally detached from the DSv4 feature merge.

Relationship to #5795

Provenance

Testing

  • uv run isort --check-only on both changed Python files
  • uv run ruff check on both changed Python files
  • uv run python -m compileall -q on both changed Python files
  • Added a CPU-only nested tuple/list/dict regression test; full execution is left to CI because the local workspace lacks PyTorch.

Recursively reuse compatible tensors inside tuple, list, and dict inputs while replacing scalars or incompatible container entries.

Signed-off-by: Deyu Fu <Deyu.Foo@gmail.com>
@copy-pr-bot

copy-pr-bot Bot commented Jul 21, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@FDecaYed

Copy link
Copy Markdown
Contributor Author

/ok to test f2475b1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant