Skip to content

Commit c3c8046

Browse files
docs: add Windows HIP build instructions and troubleshooting (#285)
Signed-off-by: Khushi <khushisingh82072@gmail.com>
1 parent 365877d commit c3c8046

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

docs/contribute/source/plugin/wasi_nn.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -328,6 +328,14 @@ Then developers can build by following the steps.
328328
& "<the ninja-build folder>\ninja.exe" -C build
329329
```
330330

331+
- If you want to enable HIP (AMD GPU):
332+
333+
```console
334+
# HIP ENABLE:
335+
& "C:\Program files\CMake\bin\cmake.exe" -Bbuild -GNinja -DCMAKE_BUILD_TYPE=Release -DWASMEDGE_PLUGIN_WASI_NN_BACKEND=ggml -DWASMEDGE_PLUGIN_WASI_NN_GGML_LLAMA_HIP=ON -DWASMEDGE_USE_LLVM=OFF .
336+
& "<the ninja-build folder>\ninja.exe" -C build
337+
```
338+
331339
#### Execute the WASI-NN plugin with the llama example on Windows
332340

333341
1. Set the environment variables
@@ -345,6 +353,22 @@ Then developers can build by following the steps.
345353
wasmedge --dir .:. --env llama3=true --env n_gpu_layers=100 --nn-preload default:GGML:AUTO:Meta-Llama-3-8B-Instruct.Q5_K_M.gguf wasmedge-ggml-llama.wasm default
346354
```
347355

356+
#### Troubleshooting: AMD Radeon Integrated Graphics (Windows)
357+
358+
If you are building the GGML backend on Windows with an integrated AMD GPU (e.g., Radeon 780M / gfx1103) and encounter `rocBLAS` or initialization errors, you may need the following workarounds:
359+
360+
1. **Set the Architecture Override:**
361+
The RDNA 3 integrated graphics require an override to match the available ROCm kernels.
362+
```console
363+
$env:HSA_OVERRIDE_GFX_VERSION = "11.0.0"
364+
```
365+
366+
2. **Manual Library Linking (ROCm 6.x):** The ROCm installer on Windows may not create the necessary symlinks for `gfx1103`. If you see errors related to missing `TensileLibrary` files:
367+
368+
* Navigate to your ROCm installation folder (e.g., `C:\Program Files\AMD\ROCm\6.x\bin\rocblas\library`).
369+
* Copy the `gfx1100` files and rename them to `gfx1103`.
370+
* Example: Copy `TensileLibrary_lazy_gfx1100.dat` -> `TensileLibrary_lazy_gfx1103.dat`
371+
348372
### Appendix for llama.cpp backend
349373

350374
We also provided the pre-built ggml plugins on the following platforms:

0 commit comments

Comments
 (0)