How do I get Cycles to recognize my AMD RDNA GPU on Fedora Linux?

Hi all,

I’d like to use my AMD Radeon RX 5700 XT to accelerate Cycles rendering with HIP. I’ve installed Blender 3.2.1 via the Fedora 36 updates-testing repository. I’ve also installed all 6 of the available ROCm packages for Fedora. After rebooting, I still see the “No compatible GPUs found for Cycles” message in Blender Preferences:

rocminfo output:

ROCk module is loaded
=====================    
HSA System Attributes    
=====================    
Runtime Version:         1.1
System Timestamp Freq.:  1000.000000MHz
Sig. Max Wait Duration:  18446744073709551615 (0xFFFFFFFFFFFFFFFF) (timestamp count)
Machine Model:           LARGE                              
System Endianness:       LITTLE                             

==========               
HSA Agents               
==========               
*******                  
Agent 1                  
*******                  
  Name:                    AMD Ryzen 7 5800X 8-Core Processor 
  Uuid:                    CPU-XX                             
  Marketing Name:          AMD Ryzen 7 5800X 8-Core Processor 
  Vendor Name:             CPU                                
  Feature:                 None specified                     
  Profile:                 FULL_PROFILE                       
  Float Round Mode:        NEAR                               
  Max Queue Number:        0(0x0)                             
  Queue Min Size:          0(0x0)                             
  Queue Max Size:          0(0x0)                             
  Queue Type:              MULTI                              
  Node:                    0                                  
  Device Type:             CPU                                
  Cache Info:              
    L1:                      32768(0x8000) KB                   
  Chip ID:                 0(0x0)                             
  Cacheline Size:          64(0x40)                           
  Max Clock Freq. (MHz):   3800                               
  BDFID:                   0                                  
  Internal Node ID:        0                                  
  Compute Unit:            16                                 
  SIMDs per CU:            0                                  
  Shader Engines:          0                                  
  Shader Arrs. per Eng.:   0                                  
  WatchPts on Addr. Ranges:1                                  
  Features:                None
  Pool Info:               
    Pool 1                   
      Segment:                 GLOBAL; FLAGS: FINE GRAINED        
      Size:                    32676344(0x1f299f8) KB             
      Allocatable:             TRUE                               
      Alloc Granule:           4KB                                
      Alloc Alignment:         4KB                                
      Accessible by all:       TRUE                               
    Pool 2                   
      Segment:                 GLOBAL; FLAGS: KERNARG, FINE GRAINED
      Size:                    32676344(0x1f299f8) KB             
      Allocatable:             TRUE                               
      Alloc Granule:           4KB                                
      Alloc Alignment:         4KB                                
      Accessible by all:       TRUE                               
    Pool 3                   
      Segment:                 GLOBAL; FLAGS: COARSE GRAINED      
      Size:                    32676344(0x1f299f8) KB             
      Allocatable:             TRUE                               
      Alloc Granule:           4KB                                
      Alloc Alignment:         4KB                                
      Accessible by all:       TRUE                               
  ISA Info:                
*******                  
Agent 2                  
*******                  
  Name:                    gfx1010                            
  Uuid:                    GPU-XX                             
  Marketing Name:          AMD Radeon RX 5700 XT              
  Vendor Name:             AMD                                
  Feature:                 KERNEL_DISPATCH                    
  Profile:                 BASE_PROFILE                       
  Float Round Mode:        NEAR                               
  Max Queue Number:        128(0x80)                          
  Queue Min Size:          64(0x40)                           
  Queue Max Size:          131072(0x20000)                    
  Queue Type:              MULTI                              
  Node:                    1                                  
  Device Type:             GPU                                
  Cache Info:              
    L1:                      16(0x10) KB                        
    L2:                      4096(0x1000) KB                    
  Chip ID:                 29471(0x731f)                      
  Cacheline Size:          64(0x40)                           
  Max Clock Freq. (MHz):   2100                               
  BDFID:                   2048                               
  Internal Node ID:        1                                  
  Compute Unit:            40                                 
  SIMDs per CU:            2                                  
  Shader Engines:          4                                  
  Shader Arrs. per Eng.:   2                                  
  WatchPts on Addr. Ranges:4                                  
  Features:                KERNEL_DISPATCH 
  Fast F16 Operation:      TRUE                               
  Wavefront Size:          32(0x20)                           
  Workgroup Max Size:      1024(0x400)                        
  Workgroup Max Size per Dimension:
    x                        1024(0x400)                        
    y                        1024(0x400)                        
    z                        1024(0x400)                        
  Max Waves Per CU:        40(0x28)                           
  Max Work-item Per CU:    1280(0x500)                        
  Grid Max Size:           4294967295(0xffffffff)             
  Grid Max Size per Dimension:
    x                        4294967295(0xffffffff)             
    y                        4294967295(0xffffffff)             
    z                        4294967295(0xffffffff)             
  Max fbarriers/Workgrp:   32                                 
  Pool Info:               
    Pool 1                   
      Segment:                 GLOBAL; FLAGS: COARSE GRAINED      
      Size:                    8372224(0x7fc000) KB               
      Allocatable:             TRUE                               
      Alloc Granule:           4KB                                
      Alloc Alignment:         4KB                                
      Accessible by all:       FALSE                              
    Pool 2                   
      Segment:                 GROUP                              
      Size:                    64(0x40) KB                        
      Allocatable:             FALSE                              
      Alloc Granule:           0KB                                
      Alloc Alignment:         0KB                                
      Accessible by all:       FALSE                              
  ISA Info:                
    ISA 1                    
      Name:                    amdgcn-amd-amdhsa--gfx1010:xnack-  
      Machine Models:          HSA_MACHINE_MODEL_LARGE            
      Profiles:                HSA_PROFILE_BASE                   
      Default Rounding Mode:   NEAR                               
      Default Rounding Mode:   NEAR                               
      Fast f16:                TRUE                               
      Workgroup Max Size:      1024(0x400)                        
      Workgroup Max Size per Dimension:
        x                        1024(0x400)                        
        y                        1024(0x400)                        
        z                        1024(0x400)                        
      Grid Max Size:           4294967295(0xffffffff)             
      Grid Max Size per Dimension:
        x                        4294967295(0xffffffff)             
        y                        4294967295(0xffffffff)             
        z                        4294967295(0xffffffff)             
      FBarrier Max Size:       32

I’d appreciate help with this so I can use my graphics card for more than just Eevee.

Relevant Ask Fedora thread: https://ask.fedoraproject.org/t/how-can-i-get-started-with-blender-cycles-hip-rendering/24705/3

AFAIK Blender requires HIP module to work. It looks that there is no rocm-hipamd package in your repo.

How HIP packaging looks on Fedora I don’t know. You might want to dig around.
Just a note that HIP was just recently greenlit to experimental on Debian:
https://lists.debian.org/debian-ai/2022/07/msg00066.html

2 Likes

Thanks for the tip. There’s an experimental rocm-hip package that Jeremy Newton (mystro256) uploaded to copr last month: https://copr.fedorainfracloud.org/coprs/mystro256/rocm-hip/

Do you think this is the module I’m missing?

2 Likes

Yep. That’s the one.

1 Like

Okay, I enabled that copr repository, installed rocm-hip & rebooted. Blender still displays the “No compatible GPUs” message in Preferences. I suppose that’s not surprising, given that it’s an experimental package. Is there anything else I could/should do?

1 Like

I don’t remember when exactly RDNA1 was (unofficially) enabled in ROCm. Because officially consumer cards aren’t. If Jeremy packaged older version first, then maybe 5700XT is not enabled at the driver level. But that’s my speculation. If HIP is from ROCm version above 5.1 I believe 5xxx cards should be recognized. And you possibly found a bug.

At this stage I pretty much expect that kind of problems.

Here is relevant message from Cordell Bloor (AMD employee) that is packaging ROCm for Debian about RDNA2 support:
https://lists.debian.org/debian-ai/2022/07/msg00036.html

2 Likes

While I marked the above AskFedora thread as “solved” a while back, it’s not a solution I’m happy with; the process is rather complicated and only kind of works.

awehrfritz is working on an improved rocm-hip package, so I think I’ll wait until their pull request has been completed and applied before trying again.

1 Like

I was afraid that will be the case. Just for comparison hip package landed in Debian recently but it’s version 5.0, so unusable with Blender.
I just wonder when version 5.1/5.2/5.3 land in unstable how much problems ROCm and particularly HIP will have with things like modern Linux kernels, LLVM and Clang that are shipped with the distro…

I just wonder when version 5.1/5.2/5.3 land in unstable how much problems ROCm and particularly HIP will have with things like … LLVM and Clang that are shipped with the distro…

I don’t have high hopes for that, considering awerfritz’s comment from yesterday:

ROCM 5.2 doesn’t work with upstream Clang 14 anymore and requires AMD’s Clang or additional patches for hipcc.

1 Like

I’m still on 20.40 PRO drivers from september 2020 since every newer version either breaks OpenCL on Vega II or is impossible to install.

The second working compute drivers lands in the repos I’m going to pin them for eternity.

I got the same problem, but with Linux Mint 21.

rocm-hipamd 5.2.3-1 was migrated to Debian testing on Saturday. Unfortunately, it was built with 1 error and 16 warnings.

I’m on unstable for some time now and I already tried ROCm/HIP with Blender.
Unfortunately I stumbled on compiler error that is still waiting for a fix: https://developer.blender.org/T102018

1 Like