操作系统版本:ubuntu20.04
DTK版本:DTK24.04.1
驱动版本:rock-5.7.1-6.2.18 或者提供如下指令结果rpm -qa | grep rock
ubuntu@ubuntu:~$ dpkg --list|grep rock
ii rock-5.7.1 6.2.18 amd64 hydcu built using CMake
DCU类型:Z100L
Name: ZIFANG
Uuid: GPU-6f096431180e5141
Marketing Name: C878186
Vendor Name: HYGON
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: 4
Device Type: DCU
Cache Info:
L1: 16(0x10) KB
L2: 8192(0x2000) KB
Chip ID: 21431(0x53b7)
Cacheline Size: 64(0x40)
Max Clock Freq. (MHz): 700
BDFID: 1536
Internal Node ID: 4
Compute Unit: 60
SIMDs per CU: 4
Shader Engines: 4
Shader Arrs. per Eng.: 1
Allocatable: TRUE
Alloc Granule: 4KB
Alloc Alignment: 4KB
Accessible by all: FALSE
Pool 3
Segment: GLOBAL; FLAGS: FINE GRAINED
Size: 33538048(0x1ffc000) KB
Allocatable: TRUE
Alloc Granule: 4KB
Alloc Alignment: 4KB
Accessible by all: FALSE
Pool 4
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--gfx906:sramecc+: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
编译过程:
docker run -it --device=/dev/kfd --device=/dev/dri --device=/dev/mkfd --shm-size=1G -v ./:/data --rm
image.sourcefind.cn:5000/dcu/admin/base/pytorch:2.1.0-ubuntu20.04-dtk24.04.1-py3.8 bash
apt-get update && apt upgrade -y && \
DEBIAN_FRONTEND=noninteractive apt install --no-install-recommends -y \
gnupg \
ca-certificates \
wget \
git \
curl \
cmake \
python3.8-dev \
build-essential \
software-properties-common && \
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - &&\
echo "deb http://apt.llvm.org/focal/ llvm-toolchain-focal-17 main" | sudo tee /etc/apt/sources.list.d/llvm-17.list &&\
echo -e '[global]\nindex-url = https://pypi.tuna.tsinghua.edu.cn/simple\nbreak-system-packages = true' > /etc/pip.conf &&\
apt update &&\
apt install -y clang-17 &&\
update-alternatives --install /usr/bin/clang clang /usr/bin/clang-17 100 &&\
update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-17 100 &&\
echo -e '[global]\nindex-url = https://pypi.tuna.tsinghua.edu.cn/simple\nbreak-system-packages = true' > /etc/pip.conf &&\
git clone -b 2.1.0-release http://developer.hpccube.com/codes/aicomponent/torch-scatter.git &&\
cd torch-scatter &&\
git submodule sync &&\
git submodule update --init --recursive &&\
pip install numpy &&\
pip install 'urllib3==1.26.14' &&\
pip install wheel &&\
source /opt/dtk/env.sh &&\
source /opt/dtk/cuda/env.sh &&\
source /opt/dtk-24.04.1/.hyhal/hydm/hydmi_env.sh &&\
export PATH=/usr/bin:$PATH &&\
python setup.py bdist_wheel
部分报错日志:
错误1
In file included from /opt/dtk/cuda/include/driver_types.h:14:
/opt/dtk/cuda/include/vector_types.h:119:30: error: definition of type 'ushort4' conflicts with type alias of the same name
__cuda_builtin_vector_align8(ushort4, unsigned short x; unsigned short y; unsigned short z; unsigned short w;);
^
/opt/dtk/hip/include/hip/amd_detail/amd_hip_vector_types.h:1137:1: note: 'ushort4' declared here
__MAKE_VECTOR_TYPE__(ushort, unsigned short);
^
/opt/dtk/hip/include/hip/amd_detail/amd_hip_vector_types.h:1112:15: note: expanded from macro '__MAKE_VECTOR_TYPE__'
using CUDA_name##4 = HIP_vector_type<T, 4>;
^
<scratch space>:59:1: note: expanded from here
ushort4
错误2
In file included from /opt/dtk/cuda/include/cuda_runtime.h:36:
In file included from /opt/dtk/cuda/include/builtin_types.h:8:
In file included from /opt/dtk/cuda/include/driver_types.h:14:
/opt/dtk/cuda/include/vector_types.h:113:27: error: definition of type 'ushort3' conflicts with type alias of the same name
struct __device_builtin__ ushort3
错误3
In file included from /opt/dtk/cuda/include/thrust/iterator/iterator_traits.h:
__MAKE_VECTOR_TYPE__(short, short);
^
/opt/dtk/hip/include/hip/amd_detail/amd_hip_vector_types.h:1111:15: note: expanded from macro '__MAKE_VECTOR_TYPE__'
using CUDA_name##3 = HIP_vector_type<T, 3>;\
^
<scratch space>:62:1: note: expanded from here
short3
^
In file included from csrc/hip/segment_coo_cuda.hip:4:
还有其余基本都是类似错误
暂无数据
暂无数据