Build and Install from Source¶
To build and install HeteroCL from source, please follow the following steps.
Create a virtual environment with conda (e.g., Anaconda or miniconda)
Download the source code from GitHub. For developers, please fork from the repo instead.
git clone https://github.com/cornell-zhang/heterocl.git
(Optional) Specify the CMake and/or LLVM path in
Makefile.config
. For instance
# set your own path to llvm-config
LLVM_CONFIG = /path/to/llvm-config
Run make to build and install HeteroCL
make -j8
For Developers¶
Set the environment variable
PYTHONPATH
to reflect the modifications of Python files
export PYTHONPATH=$HCL_HOME/python:$HCL_HOME/hlib/python
Run make under
tvm
to reflect the modification of C source files
make -C tvm