[PR #32] [CLOSED] add README for AMD ROCm #73

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

📋 Pull Request Information

Original PR: https://github.com/Comfy-Org/comfy-aimdo/pull/32
Author: @Apophis3158
Created: 4/12/2026
Status: ❌ Closed

Base: master ← Head: dev/rocm


📝 Commits (1)

📊 Changes

1 file changed (+12 additions, -3 deletions)

View changed files

📝 README.md (+12 -3)

📄 Description

DEPRECATED

Motivation

I noticed that 8 out of 16 forks of this repository attempt to add AMD ROCm support. After analyzing their changes, I confirmed that porting aimdo to ROCm primarily requires mapping CUDA driver APIs to their HIP equivalents. However, none of the existing forks support both Linux and Windows simultaneously.

This PR consolidates those community efforts and provides a unified, cross-platform implementation with full CI support for both Linux and Windows ROCm builds.

Changes

  • Add ROCm/HIP backend via CUDA-to-HIP macro mappings in src/plat_hip.h
  • Add CI workflow for building aimdo-rocm.so(dll)
  • Rename aimdo.so(dll) to aimdo-cuda.so(dll) for distinction
  • Implement automatic backend detection based on torch.version.hip
  • Update README with Experimental ROCm support matrix and Windows setup recommendations
  • Add local build scripts build-linux-docker-rocm and build-win-rocm.ps1 for devs
  • Enable INFO logging for examples/example.py

Impact on ComfyUI

None, I think. This change is fully backward compatible:

  • On AMD platforms, comfy_aimdo.control.init() will load the ROCm backend library, but aimdo will not be actively used unless explicitly enabled via --enable-dynamic-vram
  • Existing NVIDIA CUDA functionality remains unchanged
  • No changes to ComfyUI core or user-facing APIs

Additional requirements

ROCm build on Windows require clang.exe in SDK so I followed your approach made this https://github.com/Apophis3158/comfy-aimdo/releases/tag/v0.0.0
You can copy the necessary components from the ROCm SDK rocm_sdk_core-7.2.1-py3-none-win_amd64.whl yourself:

win-rocm-raw/
├── include/
│   ├── amd_comgr/
│   ├── CL/
│   └── hip/
└── lib/
    ├── amdhip64.lib
    └── llvm/
        ├── bin/
        │   ├── clang.exe
        │   └── lld-link.exe
        └── lib/
        └── clang/
             └── 22/
                  └── lib/
                       └── windows/
                            └── clang_rt.builtins-x86_64.lib

Experimental AMD ROCm support and CI has been achieved by a linkless way, but there are still some things left in the original PR to discuss.


🔄 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-aimdo/pull/32 **Author:** [@Apophis3158](https://github.com/Apophis3158) **Created:** 4/12/2026 **Status:** ❌ Closed **Base:** `master` ← **Head:** `dev/rocm` --- ### 📝 Commits (1) - [`19eec06`](https://github.com/Comfy-Org/comfy-aimdo/commit/19eec063483410c48548fff1b4da6b81b0c8244f) update README for AMD ### 📊 Changes **1 file changed** (+12 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+12 -3) </details> ### 📄 Description <details><summary>DEPRECATED</summary> ## Motivation I noticed that 8 out of 16 forks of this repository attempt to add AMD ROCm support. After analyzing their changes, I confirmed that porting aimdo to ROCm primarily requires mapping CUDA driver APIs to their HIP equivalents. However, none of the existing forks support both Linux and Windows simultaneously. This PR consolidates those community efforts and provides a unified, cross-platform implementation with full CI support for both Linux and Windows ROCm builds. ## Changes - Add ROCm/HIP backend via CUDA-to-HIP macro mappings in `src/plat_hip.h` - Add CI workflow for building `aimdo-rocm.so(dll)` - Rename `aimdo.so(dll)` to `aimdo-cuda.so(dll)` for distinction - Implement automatic backend detection based on `torch.version.hip` - Update README with Experimental ROCm support matrix and Windows setup recommendations - Add local build scripts `build-linux-docker-rocm` and `build-win-rocm.ps1` for devs - Enable INFO logging for `examples/example.py` ## Impact on ComfyUI None, I think. This change is fully backward compatible: - On AMD platforms, `comfy_aimdo.control.init()` will load the ROCm backend library, but aimdo will not be actively used unless explicitly enabled via `--enable-dynamic-vram` - Existing NVIDIA CUDA functionality remains unchanged - No changes to ComfyUI core or user-facing APIs ## Additional requirements ROCm build on Windows require `clang.exe` in SDK so I followed your approach made this https://github.com/Apophis3158/comfy-aimdo/releases/tag/v0.0.0 You can copy the necessary components from the ROCm SDK [rocm_sdk_core-7.2.1-py3-none-win_amd64.whl](https://repo.radeon.com/rocm/windows/rocm-rel-7.2.1) yourself: ``` win-rocm-raw/ ├── include/ │ ├── amd_comgr/ │ ├── CL/ │ └── hip/ └── lib/ ├── amdhip64.lib └── llvm/ ├── bin/ │ ├── clang.exe │ └── lld-link.exe └── lib/ └── clang/ └── 22/ └── lib/ └── windows/ └── clang_rt.builtins-x86_64.lib ``` </details> Experimental AMD ROCm support and CI has been achieved by a linkless way, but there are still some things left in the original PR to discuss. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-26 22:24:19 +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-aimdo#73
No description provided.