I have compiled the latest available Blender 3.1 devel version on Arch Linux with rocm 4.5 installed with the changes from this commit.
https://developer.blender.org/rB01f39ef89d40bd8dfced3efbe1c9007a0c6532cc
I have Vega 64 and I use the kernel driver, I have changed these options specifically:
CmakeLists.txt
# AMD HIP
if(WIN32)
option(WITH_CYCLES_DEVICE_HIP "Enable Cycles AMD HIP support" ON)
else()
option(WITH_CYCLES_DEVICE_HIP "Enable Cycles AMD HIP support" ON)
endif()
option(WITH_CYCLES_HIP_BINARIES "Build Cycles AMD HIP binaries" ON)
set(CYCLES_HIP_BINARIES_ARCH gfx900 gfx1010 gfx1011 gfx1012 gfx1030 gfx1031 gfx1032 gfx1034 CACHE STRING "AMD HIP architectures to build binaries for")
mark_as_advanced(WITH_CYCLES_DEVICE_HIP)
mark_as_advanced(CYCLES_HIP_BINARIES_ARCH)
util.h
return (major > 7) || (major == 7 && minor >= 0);
It compiled without any errors and installed successfully.
When I go to Edit > Preferences > System and select HIP Blender crashes with Segmentation fault (core dumped) error.
blender.crash.txt
# Blender 3.1.0, Commit date: 2021-11-16 09:16, Hash d4c868da9f97
# backtrace
blender(BLI_system_backtrace+0x34) [0x5569b63a0d34]
blender(+0xf1458d) [0x5569b3dee58d]
/usr/lib/libc.so.6(+0x3cda0) [0x7f5a5afe4da0]
blender(hipGetDeviceProperties+0) [0x5569b7f3f398]
# Python backtrace
File "/usr/share/blender/3.1/scripts/addons/cycles/properties.py", line 1355 in get_devices_for_type
File "/usr/share/blender/3.1/scripts/addons/cycles/properties.py", line 1445 in draw_impl
File "/usr/share/blender/3.1/scripts/startup/bl_ui/space_userpref.py", line 612 in draw_centered
File "/usr/share/blender/3.1/scripts/startup/bl_ui/space_userpref.py", line 182 in draw
Why is it crashing and how can it be fixed?
rocminfo output:
Agent 2
*******
Name: gfx900
Uuid: GPU-0215087234ce2984
Marketing Name: AMD Radeon RX Vega
Vendor Name: AMD
Feature: KERNEL_DISPATCH
Profile: BASE_PROFILE
Float Round Mode: NEAR
Max Queue Number: 128(0x80)
Queue Min Size: 4096(0x1000)
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: 26751(0x687f)
Cacheline Size: 64(0x40)
Max Clock Freq. (MHz): 1630
BDFID: 2304
Internal Node ID: 1
Compute Unit: 64
SIMDs per CU: 4
Shader Engines: 4
Shader Arrs. per Eng.: 1
WatchPts on Addr. Ranges:4
Features: KERNEL_DISPATCH
Fast F16 Operation: FALSE
Wavefront Size: 64(0x40)
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: 2560(0xa00)
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--gfx900: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
*** Done ***