This repository contains HTrOP, a prototype implementation to automatically generate and execute OpenCL code from sequential CPU code. Computational hotspots can be automatically identified and transparently offloaded to different resources (tested with CPU, GPGPU and Xeon Phi).
- llvm-3.8.0 (http://releases.llvm.org/3.8.0/llvm-3.8.0.src.tar.xz)
- clang (http://releases.llvm.org/3.8.0/cfe-3.8.0.src.tar.xz)
- polly (http://releases.llvm.org/3.8.0/polly-3.8.0.src.tar.xz)
- axtor (https://github.com/cdl-saarland/axtor/tree/llvm_38)
- protobuf-3.0.0-beta-3.1 (https://github.com/protocolbuffers/protobuf.git)
- googletest (https://github.com/google/googletest)
- Build llvm from source with CMake (See: Building LLVM with CMake, Polly - Getting Started)
- Download and extract llvm, clang and polly
- Place clang and polly into the right directories in the llvm source directory
- Download axtor and place it in the project folder in the llvm source
- Rebuild llvm
- Build protobuf and googletest according to the documentation
-
Download HTrOP, create a seperate HTrOP build directory and switch to it.
-
Configure build with CMake
cmake -DLLVM_SRC_DIR= -DLLVM_BIN_DIR= -DLLVM_DIR=/cmake/modules/CMakeFiles -DPROTOBUF_SRC_DIR= -DPROTOBUF_BIN_DIR= -DGTEST_SRC_DIR= -DGTEST_BIN_DIR=/googlemock/gtest
-
Build with make
- Go to <HTrOP source directory>/test/
- Update the Common.mk with the correct paths
- Go to motion and run: make llvmir
- Go to <HTrOP build directory>/out/bin
- Start the htrop_server in the background
- Start the htrop_client with the generated file (step 3) as then argument
For more options run the htrop_server and htrop_client with the -help option
Issue : Error in hds.pb.*
Solution: Go to <HTrOP source directory>/common/hds.proto and follow the instructions to generate the hds files
- H. Riebler, G. Vaz, T. Kenter, C. Plessl. Automated Code Acceleration Targeting Heterogeneous OpenCL Devices. In Proc. ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP), ACM, 2018.
- H. Riebler, G. Vaz, T. Kenter, C. Plessl. Transparent Acceleration for Heterogeneous Platforms with Compilation to OpenCL. In *ACM Transactions on Architecture and Code Optimization (TACO) Volume 16 Issue April, 2019.
Please cite
@article{riebler19transparent,
author = {Riebler, Heinrich and Vaz, Gavin and Kenter, Tobias and Plessl, Christian},
title = {Transparent Acceleration for Heterogeneous Platforms With Compilation to OpenCL},
journal = {ACM Trans. Archit. Code Optim.},
issue_date = {April 2019},
volume = {16},
number = {2},
month = apr,
year = {2019},
issn = {1544-3566},
pages = {14:1--14:26},
articleno = {14},
numpages = {26},
url = {http://doi.acm.org/10.1145/3319423},
doi = {10.1145/3319423},
acmid = {3319423},
publisher = {ACM},
address = {New York, NY, USA},
keywords = {OpenCL, Transparent acceleration, multi-accelerator, runtime system},
}