{{ message }}
Repository navigation
Commit 7c3c688
[Experimental] Add ROCm/HIP support (100% vibe‑coded, for testing purposes) (0xShug0#48)
* Add ROCm/HIP backend support
Enable ENGINE_ENABLE_HIP=ON to build with HIP/ROCm for AMD GPUs.
- New BackendType::Hip in module.h
- init_backend, backend_type, release_backend_graph_resources, query_backend_memory all support HIP
- Reuses GGML's existing ggml-hip with vendor header mapping CUDA→HIP APIs
- GGML_USE_CUDA is still defined for HIP (zero new kernel code needed)
- Runtime distinguishes HIP devices via 'ROCm' name prefix
- Skip audio.cpp's own .cu files (ISTFT, TorchRandom) on HIP builds
- --backend hip in CLI help and server config
* Add HIP/ROCm backend implementation document
* Complete HIP backend: hipBLASLt GEMM, Windows support, gfx1103
- ggml-hip: route all cuBLAS-equivalent GEMM through hipBLASLt
(new GGML_HIP_HIPBLASLT option, default ON, falls back to hipBLAS
when the package is missing). hipBLASLt ships kernels for arches
rocBLAS lacks on Windows (notably gfx1103 / Radeon 780M). Handles
legacy hipblasDatatype_t vs hipDataType numbering on ROCm < 6.5,
6.x and 7.x. Pointer-array batched GEMM is emulated per batch
element. Verified against CPU reference on gfx1103/ROCm 6.4.
- Forward ENGINE_ENABLE_CUDA_GRAPHS to GGML_HIP_GRAPHS so graphs can
be disabled on memory-constrained iGPUs (per-graph VRAM reserves
caused OOM on the second request).
- Add scripts/build_windows_hip.ps1: one-shot Windows HIP build
(auto-detects ROCm, GPU targets, cmake, ninja; graphs OFF and
NO_VMM ON by default).
- Add Hip case to ace_step planner backend switch.
- Update docs/HIP.md: hipBLASLt path, support matrix, Windows build
instructions, verification checklist.
* Document HIP build options for discrete GPUs (Windows and Linux)
* Accept rocm as an alias for the hip backend
* fix(hip): fix build for RDNA3/GFX1150 and modern HIP compilers
Co-authored-by: Junie <junie@jetbrains.com>
* Document MSVC 14.51 HIP build incompatibility and older toolset workaround
* Update HIP doc to the dynamic backend-registry implementation
* Error out when ENGINE_ENABLE_CUDA and ENGINE_ENABLE_HIP are both enabled
HIP compiles ggml's CUDA backend sources as HIP code, so both options
drive the same ggml backend. Enabling both started CUDA backend setup and
then failed confusingly on missing ROCm; fail fast at configure time with
a clear message instead. Also pass -DENGINE_ENABLE_CUDA=OFF explicitly in
build_windows_hip.ps1.
* Document hip/rocm backends in server help text
---------
Co-authored-by: Markus Hartung <mail@hartmark.se>
Co-authored-by: Junie <junie@jetbrains.com>1 parent 0433666 commit 7c3c688
13 files changed
Lines changed: 823 additions & 13 deletions
File tree
- app
- cli
- server
- docs
- external/ggml/src
- ggml-cuda
- ggml-hip
- include/engine/framework/core
- scripts
- src
- framework/core
- models/ace_step
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
96 | 96 | | |
97 | 97 | | |
98 | 98 | | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
99 | 102 | | |
100 | 103 | | |
101 | 104 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
| 51 | + | |
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
| 51 | + | |
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| |||

0 commit comments