Skip to content

ROCm 1.5.0 RC1 binary package

Pre-release
Pre-release
Compare
Choose a tag to compare
@whchung whchung released this 13 Mar 01:27
· 1887 commits to clang_tot_upgrade since this release

ROCm 1.5.0 RC1 binary package

Note:

  • This is the first release candidate for HCC for ROCm 1.5.0. It contains codes in remove-promote-decouple-generic-0 branch which stems from a pending upstream patch: https://reviews.llvm.org/D27627

Contents:

  • ROCm Device Library
  • HCC Compiler

Build Environment:

  • OS: Ubuntu Linux 16.04
  • Compiler: gcc 5.4.0
  • ROCm: 1.4

Steps to build from source:
(adopted from https://github.com/RadeonOpenCompute/HCC-Native-GCN-ISA/wiki )

# Initialize the Workspace
mkdir repo-roc-1.5.0-rc1
cd repo-roc-1.5.0-rc1
repo init -u https://github.com/RadeonOpenCompute/HCC-Native-GCN-ISA.git -b refs/tags/roc-1.5.0-rc1
repo sync

# build various LLVM components in order to build ROCm device library
mkdir llvm/build
cd llvm/build
cmake .. -DCMAKE_BUILD_TYPE=Release -DLLVM_TARGETS_TO_BUILD="AMDGPU;X86" -DLLVM_APPEND_VC_REV=ON 
make -j64
cd ../..

# build ROCm device library
mkdir ocml/build
cd ocml/build
export LLVM_BUILD=`pwd`/../../llvm/build
CC=$LLVM_BUILD/bin/clang cmake -DLLVM_DIR=$LLVM_BUILD -DAMDHSACOD=/opt/rocm/bin/amdhsacod ..
make -j64
# build binary packages for distribution
make package
# install the package built so HCC could be properly configured
sudo dpkg -i rocm-device-libs-0.0.1-Linux.deb
cd ../..


# build HCC compiler and HCC runtime
mkdir hcc/build
cd hcc/build

# configure HCC
# add -DDISTRO=xenial in case you build under Ubuntu Linux 16.04
# add -DDISTRO=fd23 in case you build under Fedora Linux 23
cmake .. \
  -DROCM_DEVICE_LIB_DIR=/opt/rocm/lib \
  -DNUM_BUILD_THREADS=64

# build HCC
make -j64

# build binary packages for distribution
make package

cd ../..