Skip to content

parmance/chip-spv

 
 

Repository files navigation

CHIP-SPV

CHIP-SPV is a HIP implementation that abstracts HIP API, providing a set of base classes that can be derived from to implement an additional, SPIR-V capable backend on which to execute HIP calls. Currently CHIP-SPV OpenCL and Level Zero as backends. This project is a result of HIPCL and HIPLZ projects.

Prerequisites

  • Cmake >= 3.18.0
  • Clang with SPIR-V patches: hipcl-clang
  • For Level Zero Backend
  • For OpenCL Backend
    • An OpenCL implementation with (at least partial) 2.x support; HIPCL requires Shared Virtual Memory and clCreateProgramWithIL() support

Downloading Sources

git clone https://github.com/CHIP-SPV/chip-spv.git
cd chip-spv
git submodule update --init --recursive

Building

# export PATH=${PATH_TO_CLANG_SPIRV}:$PATH
mkdir build
cd build

cmake .. -DCMAKE_CXX_COMPILER=clang++

Testing

Run tests on the default backend:

make test

Run tests on a specific backend:

CHIP_BE=<backend> make test

Where the backend is a backend identification. Possible values for it are level0 and opencl.

About

CHIP-SPV is a backend infrastructure for HIP running on SPIR-V

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 59.6%
  • C 39.9%
  • CMake 0.5%