Skip to content

[ComfyUI v0.23.0] Sampling hangs at 0/N, GPU pinned 100%, with PromptRelay (LTX-2.3, Windows) — works fine on v0.22.0 #18

Open

Description

@Airsiren

Summary

After upgrading ComfyUI v0.22.0 → v0.23.0, my LTX-2.3 image-to-video workflow that uses PromptRelay hangs during sampling:
SamplerCustomAdvanced stays at 0/8, GPU at 100%, and never advances. The exact same workflow completes in ~500s on ComfyUI
v0.22.0
. Reverting ComfyUI to v0.22.0 fixes it completely.

Environment

  • ComfyUI: 0.23.0 (with the deps it requires: comfy-aimdo 0.4.7, comfy-kitchen 0.2.10, frontend 1.44.19)
  • PromptRelay: latest main (commit ca5d4e3, 2026-05-20)
  • OS: Windows 11
  • GPU: RTX 5090 32GB (Blackwell), driver 595.79
  • Python 3.11.8, PyTorch 2.10.0+cu128, CUDA 12.8
  • Attention: SageAttention 2.2.0.post4, launched with --use-sage-attention --disable-dynamic-vram
  • Model: LTX-2.3 (LTXAV) I2V, 1920x1088, 511 pixel frames (64 latent frames), 8 steps

Symptom (log)

Models load fine, then:
[PromptRelay] Built penalty matrix (scaled): Lq=34170, Lk=1024, nonzero=13041243/34990080
[PromptRelay] Built penalty matrix (scaled): Lq=426, Lk=1024, nonzero=162567/436224
0%| | 0/8 [00:00<?, ?it/s]
…then it sits at 0/8 indefinitely with GPU at 100% (not a deadlock — it's computing something but never advancing). Model loaded
partially: loaded partially; 23237 MB loaded, 799 MB offloaded, lowvram patches: 103.

Expected

Sampling progresses and the video generates, as on v0.22.0 (~500s).

What I've already ruled out

  • Not #14250 / pinned memory: models load completely (no HostBuffer.read_file_slice error); adding --disable-pinned-memory
    does not help.
  • Not the new SDPA backend: v0.23.0 added a Windows cuDNN-first SDPA priority in comfy/ops.py, and attention_pytorch now
    routes through comfy.ops.scaled_dot_product_attention. I monkey-patched comfy.ops.scaled_dot_product_attention back to plain
    torch.nn.functional.scaled_dot_product_attention (bypassing the cuDNN-first priority) — still hangs. So the cuDNN backend is
    not the cause.

Suspected area (for your investigation)

The hang is in PromptRelay's masked cross-attention path. For LTX, apply_patches() wraps each block's attn2.forward via
add_object_patch, then _make_ltx_mask_wrapper injects the penalty matrix as an additive mask and forces attention_pytorch
via optimized_attention_override. On v0.23.0 this large masked cross-attn (Lq≈34170, Lk≈1024) never completes. v0.23.0 made large
changes to comfy/model_patcher.py (add_object_patch / get_model_object), comfy/ops.py, and comfy/model_management.py
(loader/offload) — any of which could be interacting badly with the patch + additive-mask path.

I have not isolated a minimal repro without PromptRelay (a stock LTX-2.3 workflow), so I can't yet confirm whether this is
PromptRelay-specific or a broader v0.23.0 + LTX masked-attention regression.

Notes

Happy to provide the full workflow JSON, full startup log, or test any patch you suggest.

Activity

  1. Airsiren commented on Jun 6, 2026

    @Airsiren
    Author

    Closing the loop: after isolating this, it's not a PromptRelay bug. Root cause is a ComfyUI core regression in the v0.23.0
    async weight offloader
    (av_model.py AdaLN weight streaming), not the mask/attention path. A same-offload-volume A/B test shows
    an 8.6× slowdown purely from the async offloader; --disable-async-offload restores normal speed. Full details at
    Comfy-Org/ComfyUI#14253. Feel free to close this as upstream-core.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions