<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by ... on Medium]]></title>
        <description><![CDATA[Stories by ... on Medium]]></description>
        <link>https://medium.com/@cdbb_writes?source=rss-cbff4202d1d6------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*3dYVZyUdsAetjdBO5CLclQ.png</url>
            <title>Stories by ... on Medium</title>
            <link>https://medium.com/@cdbb_writes?source=rss-cbff4202d1d6------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 04:19:47 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@cdbb_writes/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[From bare metal to AI powerhouse — setting up AMD’s Strix Halo]]></title>
            <link>https://medium.com/@cdbb_writes/from-bare-metal-to-ai-powerhouse-setting-up-amds-strix-halo-a58a1f3bc675?source=rss-cbff4202d1d6------2</link>
            <guid isPermaLink="false">https://medium.com/p/a58a1f3bc675</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[fedora]]></category>
            <category><![CDATA[amd]]></category>
            <category><![CDATA[rocm]]></category>
            <dc:creator><![CDATA[...]]></dc:creator>
            <pubDate>Fri, 05 Dec 2025 05:41:03 GMT</pubDate>
            <atom:updated>2025-12-29T12:51:33.413Z</atom:updated>
            <content:encoded><![CDATA[<h3>From bare metal to AI powerhouse — setting up AMD’s Strix Halo</h3><p>No muss, no fuss, we’re going to take an AMD Stix Halo system with a blank SSD and have ComfyUI running in about 30 minutes.</p><p>We aren’t messing with containers, nor with virtual environments, there are no special drivers to install, no hacky workarounds.</p><p>[ I only mention Strix Halo because that’s what I’m using for this test, though you <em>should</em> be able to use this guide on any AMD system; servers, threadripper workstations, desktops, APU based miniPCs. Bonus points if you test on an AMD powered handheld]</p><h3>The Hardware</h3><p>Enter BIOS and set the UMA GFX limit to the <em>minimum</em> possible option (usually 512MB). This is a unified memory system. We do not want to manually partition memory into fake splits for system and “VRAM” which not only complicates things but forces unnecessary memory copies hurting performance and efficiency.</p><h3>The Operating System</h3><p>Many great linux distributions exist but we will use Fedora.</p><p>Currently, <a href="https://fedoraproject.org/wiki/SIGs/HC">Fedora</a> is the only distribution with an up-to-date ROCm stack pre-packaged so that’s what we are using. If you install something else life will be harder.</p><p>(note: AMD is working with other distros so this will change in the future).</p><p>Follow these instructions: <a href="https://docs.fedoraproject.org/en-US/quick-docs/creating-and-using-a-live-installation-image/">https://docs.fedoraproject.org/en-US/quick-docs/creating-and-using-a-live-installation-image/</a></p><p>Set your username/password, chosen a timezone, and be thankfully for avoiding the relentless up-sell of a Windows installation. With a fresh new OS installed we proceed — start your stopwatch!</p><h3>Kernel</h3><p>I ran into an odd issue where kernel `6.17.9–300` would cause a crash (GCVM_L2_PROTECTION_FAULT_STATUS) so I’m sticking to `6.17.8–300` until that is resolved. Update: Still not resolved in 6.18.0–65.</p><pre>$ sudo dnf versionlock add kernel-6.17.8-300.fc43.x86_64<br>Updating and loading repositories:<br>Repositories loaded.<br>Adding versionlock on &quot;kernel = 6.17.8-300.fc43&quot;.</pre><p>By default you might see ~64GB of a 128GB system available as shared memory, to unlock more you can add these kernel parameters:</p><pre>$sudo grubby --update-kernel=ALL --args=&quot;ttm.pages_limit=29360128 ttm.page_pool_size=29360128 amdttm.pages_limit=29360128 amdttm.page_pool_size=29360128&quot; </pre><h3>Install ROCm via dnf</h3><p>ROCm 7.1.1 (latest and recommended)</p><pre>user@fedora:~$ sudo dnf --releasever=44 install rocm-core rocm-hip rocm-opencl rocminfo rocm-smi <br>user@fedora:~$ sudo dnf --releasever=44 install rocm-hip-devel hipblas-devel hiprand-devel hipsparse-devel hipblaslt-devel rocblas-devel hipcub-devel hipsolver-devel rocsolver-devel</pre><p>Or ROCm 6.4.x (not generally recommended)</p><pre>user@fedora:~$ sudo dnf install rocm-core rocm-hip rocm-opencl rocminfo rocm-smi <br>user@fedora:~$ sudo dnf install rocm-hip-devel hipblas-devel hiprand-devel hipsparse-devel hipblaslt-devel rocblas-devel hipcub-devel</pre><p>Quick test</p><pre>user@fedora:~$ rocm-smi<br><br><br>WARNING: AMD GPU device(s) is/are in a low-power state. Check power control/runtime_status<br><br>Exception caught: map::at<br>========================================= ROCm System Management Interface =========================================<br>=================================================== Concise Info ===================================================<br>Device  Node  IDs              Temp    Power     Partitions          SCLK  MCLK     Fan  Perf  PwrCap  VRAM%  GPU%  <br>              (DID,     GUID)  (Edge)  (Socket)  (Mem, Compute, ID)                                                 <br>====================================================================================================================<br>0       1     0x1586,   2295   39.0°C  25.011W   N/A, N/A, 0         N/A   1000Mhz  0%   auto  N/A     67%    3%    <br>====================================================================================================================<br>=============================================== End of ROCm SMI Log ================================================</pre><h3>Install build tools</h3><pre>user@fedora:~$ sudo dnf install make automake gcc gcc-c++ python3-cmake python3-devel</pre><h3>Install Torch packages via pip</h3><p>ROCm 7.1 (latest and recommended)</p><pre>user@fedora:~​$ pip3 install --resume-retries 10 --pre torch torchvision torchaudio torchsde --index-url https://download.pytorch.org/whl/nightly/rocm7.1</pre><p>Or for ROCm 6.4.x should you have a specific need</p><pre>user@fedora:~​$ pip3 install --resume-retries 10 torch torchvision torchaudio transformers torchsde --index-url https://download.pytorch.org/whl/rocm6.4</pre><p>Note: if torchsde doesn’t install from the rocm repository either dnf install python3-torchsde or pip3 install torchsde are alternatives.</p><p>Build and install the <a href="https://github.com/google/sentencepiece">sentencepiece</a> module</p><pre>user@fedora:~$ git clone https://github.com/google/sentencepiece.git<br>user@fedora:~$ cd sentencepiece/python<br>user@fedora:~/sentencepiece/python$ pip install . --user</pre><p>Build and install the <a href="https://github.com/bitsandbytes-foundation/bitsandbytes">bitsandbytesmodule</a></p><pre>user@fedora:~$ git clone https://github.com/bitsandbytes-foundation/bitsandbytes.git<br>user@fedora:~$ cd bitsandbytes <br>user@fedora:~/bitsandbytes$ cmake -DCOMPUTE_BACKEND=hip -S .<br>user@fedora:~/bitsandbytes$ make<br>user@fedora:~/bitsandbytes$ pip install . --user --no-deps</pre><h3>Clone and setup ComfyUI</h3><pre>user@fedora:~$ git clone https://github.com/comfyanonymous/ComfyUI.git<br>user@fedora:~$ cd ComfyUI</pre><h4>Edit dependencies</h4><p>As our torchpackages are already installed we comment them out from requirements.txt otherwise they’ll be overwritten with incorrect versions.</p><p>Open up an editor and comment out these lines:</p><pre>...<br>comfyui-workflow-templates==0.2.11<br>comfyui-embedded-docs==0.3.1<br>#torch<br>#torchsde<br>#torchvision<br>#torchaudio<br>numpy&gt;=1.25.0<br>einops<br>...</pre><h4>Install the requirements</h4><pre>user@fedora:~/ComfyUI$ pip install -r requirements.txt</pre><h4>Run it</h4><pre>user@fedora:~/ComfyUI$ python3 main.py</pre><h4>Use it</h4><p>Load `<a href="http://127.0.0.1:8188/">http://127.0.0.1:8188/</a>` in your browser of choice.</p><h3>Examples</h3><h4>Qwen image at 1920x1080 + ESRGAN upscale</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*P2lCWasxrw0yuPqqAPCYMg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Y4xTS0stUEc1WDvRoVIDKQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-KheHMG5L9EZ9Tq_Ya8VUQ.png" /></figure><h3>Z-Image, 1920x1080–~150 seconds including x4 upscale, ~54 seconds at native 1080p</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*78ul-XfMPG2JEAVAWV8t_Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1WwnJAwvF-B0wZTpmIGOcg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*METOTF8ASfO26FAulwuSFg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Pb6PGbJcV7-zLEA9QN8d4Q.png" /></figure><h3>HunyuanVideo 1.5</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5x3vRXw_b8NCLrbrvsmAwQ.png" /></figure><p>Music generation works and text-to-speech also works just fine.</p><p>note: if you attach an eGPU and wish to tell ComfyUI to use the iGPU you can specify the device to use with this option:</p><pre>$ python3 main.py --cuda-device 1</pre><p>[ yes, it’s “ — cuda-device” because apparently the developers were unaware other GPU vendors existed when they wrote it. Maybe one day it will become “ — device” ]</p><h3>llama.cpp (ROCm or Vulkan)</h3><h4>Requirements</h4><pre>fedora:~$ sudo dnf install libcurl-devel.x86_64<br>fedora:~$ git clone https://github.com/ggml-org/llama.cpp<br>fedora:~$ cd llama.cpp</pre><h3>Build for Vulkan</h3><pre>fedora:~/llama.cpp$ cmake -S . -B build-vulkan \<br>    -DGGML_VULKAN=ON \<br>    -DGGML_HIP=OFF \<br>    -DCMAKE_BUILD_TYPE=Release<br>fedora:~/llama.cpp$ cmake --build build-vulkan --config Release -j 24</pre><h3>Build ROCm</h3><pre>fedora:~/llama.cpp$ HIPCXX=&quot;$(hipconfig -l)/clang&quot; HIP_PATH=&quot;$(hipconfig -R)&quot; \<br>cmake -S . -B build-rocm \<br>    -DGGML_HIP=ON \<br>    -DAMDGPU_TARGETS=&quot;gfx1151;gfx1201&quot; \<br>    -DGGML_HIP_ROCWMMA_FATTN=ON \<br>    -DGGML_HIP_UMA=ON \<br>    -DCMAKE_BUILD_TYPE=Release<br>fedora:~/llama.cpp$ cmake --build build-rocm --config Release -- -j 24</pre><h4>List device(s)</h4><pre>fedora:~/llama.cpp$ ./build/bin/llama-cli --list-devices</pre><p><em>note 1</em>: this includes curl libraries but you can omit them if you don’t need/want support for model downloading within llama.cpp.</p><p><em>note 2</em>: in the case of ROCm we compile dual kernels for RDNA3 (Strix) and also RDNA4 (in case you use an eGPU, we can add other targets for rdna2/3 if needed).</p><p><em>note 3</em>: we enable unified memory support and hardware flash attention support using WMMA.</p><h4>Grab a model for testing</h4><p>Qwen 30b is a good starting point. Here is the hugging face commands to download the 4-bit quantized version.</p><pre>fedora:~/llama.cpp$ hf download \<br>  unsloth/Qwen3-30B-A3B-Thinking-2507-GGUF \<br>  --include &quot;*Q4_K_M.gguf&quot; \<br>  --local-dir ./models</pre><pre>fedora:~/llama.cpp$ hf download unsloth/Qwen3-Next-80B-A3B-Thinking-GGUF \<br>  --include &quot;*Q8_K_XL/*&quot; \<br>  --local-dir ./models</pre><h4>Run script</h4><h4>ROCm</h4><pre>#!/bin/bash<br><br># By default the iGPU is device 0 but if you add an eGPU<br># that might become device 0 with the iGPU moving to 1<br># export HIP_VISIBLE_DEVICES=0<br><br># If you need to force the architecture ( shouldn&#39;t be needed )<br># export HSA_OVERRIDE_GFX_VERSION=11.5.1<br><br># Model Path<br>MODEL=&quot;./models/Qwen3-Next-80B-A3B-Thinking-Q4_K_M.gguf&quot;<br><br># Performance Flags<br># -ngl 99:    Put 100% of layers on the iGPU.<br># --threads 16: Physical Core count (Best for latency).<br># --ctx-size 32768: Massive context window (You have the RAM for it!).<br># -no-cnv:    Disable conversation mode (Optional, remove if you want chat interface).<br><br>echo &quot;Starting Strix Halo Native Server ..&quot;<br><br>./build-rocm/bin/llama-server \<br>  -m &quot;$MODEL&quot; \<br>  --n-gpu-layers 99 \<br>  --threads 16 \<br>  --ctx-size 32768 \<br>  --batch-size 512 \<br>  --temp 0.6 \<br>  --min-p 0.05 \<br>  --host 0.0.0.0 \<br>  --no-mmap</pre><h4>Vulkan</h4><pre>#!/bin/bash<br># If you want to run from an eGPU you might need to define the device number:<br># export GGML_VK_VISIBLE_DEVICES=0<br><br># Model Path - set this to whereever your model was downloaded<br>MODEL=&quot;./models/Qwen3-Next-80B-A3B-Thinking-Q4_K_M.gguf&quot;<br># Performance Flags<br># -ngl 99:    Put 100% of layers on the iGPU<br># --threads 16: Physical Core count<br># --ctx-size 32768: Massive context window - why not!<br># Start<br>./build-vulkan/bin/llama-server \<br>  -m &quot;$MODEL&quot; \<br>  --n-gpu-layers 99 \<br>  --threads 16 \<br>  --ctx-size 32768 \<br>  --batch-size 512 \<br>  --temp 0.6 \<br>  --min-p 0.05 \<br>  --host 0.0.0.0 \<br>  --no-mmap</pre><h3>llama.cpp benchmarks — Qwen3-Next-80B-A3B-Thinking</h3><p>Using a very large (39KB) prompt file asking for a summary of a quartly financial report I get these results from the Vulkan backend:</p><h4>CPU</h4><p>~10-13 t/s depending on prompt size</p><p>side note: Let’s take a moment to appreciate the pure absurdity of this. That’s an 80 billion parameter count model (46GB file in Q4) seeing usable performance on an APU’s CPU. The power of having 16 Zen5 cores with AVX-512!</p><h4>iGPU</h4><p>~32 tokens/second, now that’s more like it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LWFUTEwWh7LymCR15fsvQA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FiVmV2vP9WjjSibYmGyWLQ.png" /></figure><p>Did it work though? More or less.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/540/1*YSCgepPepSFXDk4jote89A.png" /></figure><p>It’s usable but Qwen-Next is not yet optimized for this setup, doesn’t take advantage of the NPU for prompt processing, and time to first token is pretty slow.</p><h3>llama.cpp — Qwen3–30B-A3B-Thinking</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*V_zBLC8Wje7-oe3VBVatnw.png" /></figure><p>This came back with 71 tokens/second. The code ran but again the box drawing wasn’t perfect.</p><p>I have not been able to load Qwen3-Next-80B-A3B-Thinking-UD-Q8_K_XL with ROCm due to an apparent issue whereby I cannot make a single memory allocation over 64GB. Does not affect Vulkan compiled llama.cpp and I was able to allocate the full ~85GB for the model with ~25 tokens/second. I expect this will be resolved in a future ROCm release.</p><h3>GPT-OSS-120b Q4_K_M</h3><p>Happily generating at 54 tokens/second with Vulkan (ROCm 7.1.1–1 is failing)</p><pre>prompt eval time =     479.62 ms /    47 tokens (   10.20 ms per token,    97.99 tokens per second)<br>       eval time =   16012.02 ms /   865 tokens (   18.51 ms per token,    54.02 tokens per second)<br>      total time =   16491.64 ms /   912 tokens</pre><h4>Optional extras</h4><p>Additional packages I find useful (dnf install) :</p><ul><li>btop — system monitoring from the terminal</li><li>glow — ‘less’ for markdown files</li><li>npm — For insalling gemini-cli</li><li>gh — github</li><li>git-lfs — large file support for git</li></ul><p>Additional development packages if you want to write graphical applications/ GPU shaders ( dnf install) :</p><ul><li>vulkan-headers</li><li>vulkan-loader-devel</li><li>opencl-headers.noarch</li><li>rocm-opencl-devel</li><li>glslc</li></ul><h3>If you have issues</h3><p>Check versions are consistent, we don’t want packages mixed between versions 7/6. If you are installing ROCm 7.1 then all related packages, rocm, hip, and torch, should reflect this.</p><pre>user@fedora:~$ rpm -qa rocm\* hip\*<br>rocm-runtime-7.1.0-1.fc44.x86_64<br>rocminfo-7.1.0-1.fc44.x86_64<br>rocm-core-7.1.0-1.fc44.x86_64<br>rocm-origami-7.1.0-1.fc44.x86_64<br>rocm-smi-7.1.0-1.fc44.x86_64<br>hipblaslt-7.1.0-1.fc44.x86_64<br>rocm-llvm-filesystem-20-7.rocm7.1.0.fc44.x86_64<br>rocm-libc++-20-7.rocm7.1.0.fc44.x86_64<br>rocm-llvm-libs-20-7.rocm7.1.0.fc44.x86_64<br>rocm-clang-libs-20-7.rocm7.1.0.fc44.x86_64<br>rocm-lld-20-7.rocm7.1.0.fc44.x86_64<br>rocm-llvm-20-7.rocm7.1.0.fc44.x86_64<br>rocm-llvm-static-20-7.rocm7.1.0.fc44.x86_64<br>rocm-comgr-20-7.rocm7.1.0.fc44.x86_64<br>rocm-clang-20-7.rocm7.1.0.fc44.x86_64<br>rocm-device-libs-20-7.rocm7.1.0.fc44.x86_64<br>hipcc-20-7.rocm7.1.0.fc44.x86_64<br>rocm-opencl-7.1.0-2.fc44.x86_64<br>rocm-hip-7.1.0-2.fc44.x86_64<br>hipsparse-7.1.0-2.fc44.x86_64<br>hiprand-7.1.0-3.fc44.x86_64<br>hipblas-7.1.0-4.fc44.x86_64<br>...</pre><pre>user@fedora:~$ pip list | grep torch<br>pytorch-triton-rocm                    3.5.1+gitbfeb0668<br>torch                                  2.10.0.dev20251120+rocm7.1<br>torchaudio                             2.10.0.dev20251121+rocm7.1<br>torchsde                               0.2.6<br>torchvision                            0.25.0.dev20251121+rocm7.1</pre><h3>Final thoughts</h3><p>I am really impressed by Strix Halo which has turned out to be an impressive little workstation in terms of performance and versatility.</p><p>This process is relatively quick and simple but had room to improve.</p><ol><li>AMD is working with other distros to package ROCm upsteam</li><li>We are using the rawhide repo to pull in the latest ROCm version, but I don’t see this being necessary after F44 is released in ~April next year.</li><li>bitsandbytes has mainlined the multi-backend branch which is a nice improvement and sometime in the future we shouldn’t need to build it ourselves.</li><li>Neither should compiling sentencepiece be required in the future.</li><li>The XDNA2 NPU goes completely at the moment leaving a lot of performance on the table. ONNX based nodes in ComfyUI has the potential to significantly accelerate some workloads but I’ve not tested any.</li><li>I am able to run ComfyUI image generation on my eGPU at the same time as running Qwen LLM via the iGPU and the system remains completly responsive.</li><li>This system boots <em>quickly</em>.</li></ol><h4>TODO</h4><p>Lemonade — <a href="https://github.com/lemonade-sdk/lemonade">https://lemonade-server.ai/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a58a1f3bc675" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>