[PR #6] [MERGED] Rope update #80

Closed
opened 2026-10-26 22:20:10 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Comfy-Org/comfy-kitchen/pull/6
Author: @contentis
Created: 1/6/2026
Status: ✅ Merged
Merged: 1/6/2026
Merged by: @comfyanonymous

Base: main ← Head: rope_update


📝 Commits (2)

📊 Changes

9 files changed (+511 additions, -435 deletions)

View changed files

📝 comfy_kitchen/backends/cuda/__init__.py (+24 -4)
📝 comfy_kitchen/backends/cuda/dlpack_bindings.cpp (+92 -46)
📝 comfy_kitchen/backends/cuda/dtype_dispatch.cuh (+10 -0)
📝 comfy_kitchen/backends/cuda/ops/apply_rope.cu (+250 -220)
📝 comfy_kitchen/backends/eager/__init__.py (+2 -2)
📝 comfy_kitchen/backends/triton/__init__.py (+5 -20)
📝 comfy_kitchen/backends/triton/rope.py (+45 -44)
📝 tests/conftest.py (+10 -1)
📝 tests/test_rope.py (+73 -98)

📄 Description

Changes made:

  • Modify tirton and cuda kernel to allow for torch-like broadcasting, thereby support bothe BHND and BNHD (ZImage)
  • Extended testing to include both layouts
  • Optional input in cuda kernel for fused q,k instead of two kernel launches
  • Performance optimiations to support broader load+stores.
  • Extended input dtype to allow for f16/bf16 freq_cis

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Comfy-Org/comfy-kitchen/pull/6 **Author:** [@contentis](https://github.com/contentis) **Created:** 1/6/2026 **Status:** ✅ Merged **Merged:** 1/6/2026 **Merged by:** [@comfyanonymous](https://github.com/comfyanonymous) **Base:** `main` ← **Head:** `rope_update` --- ### 📝 Commits (2) - [`3bc00dd`](https://github.com/Comfy-Org/comfy-kitchen/commit/3bc00ddcd520073056d3cfc6e3a8368bb0eda858) improved rope function - [`142d357`](https://github.com/Comfy-Org/comfy-kitchen/commit/142d357aa062b5ac092ab3fbfedddf82a4d1227f) allow for f16 freq ### 📊 Changes **9 files changed** (+511 additions, -435 deletions) <details> <summary>View changed files</summary> 📝 `comfy_kitchen/backends/cuda/__init__.py` (+24 -4) 📝 `comfy_kitchen/backends/cuda/dlpack_bindings.cpp` (+92 -46) 📝 `comfy_kitchen/backends/cuda/dtype_dispatch.cuh` (+10 -0) 📝 `comfy_kitchen/backends/cuda/ops/apply_rope.cu` (+250 -220) 📝 `comfy_kitchen/backends/eager/__init__.py` (+2 -2) 📝 `comfy_kitchen/backends/triton/__init__.py` (+5 -20) 📝 `comfy_kitchen/backends/triton/rope.py` (+45 -44) 📝 `tests/conftest.py` (+10 -1) 📝 `tests/test_rope.py` (+73 -98) </details> ### 📄 Description Changes made: - Modify tirton and cuda kernel to allow for torch-like broadcasting, thereby support bothe BHND and BNHD (ZImage) - Extended testing to include both layouts - Optional input in cuda kernel for fused q,k instead of two kernel launches - Performance optimiations to support broader load+stores. - Extended input dtype to allow for f16/bf16 freq_cis --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-26 22:20:10 +00:00
Sign in to join this conversation.
No labels
pull-request
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
Comfy-Org/comfy-kitchen#80
No description provided.