AccSynt
AccSynt is a library for automatically learning the behaviour of an accelerator by querying an interface for input / output examples. It is an experimental research project in a state of continuous development.
Building
Build prerequisites:
- CMake 3.2 or newer
- Conan
- A C++ compiler with C++17 support, such as
g++
7 or newer.
The build instructions in this section assume an environment variable
$BUILD_ROOT
that points to where you want to build LLVM and AccSynt.
LLVM 7
cd $BUILD_ROOT
git clone https://github.com/Baltoli/llvm.git
git checkout standalone
cd llvm/tools
git clone https://github.com/Baltoli/clang.git
git checkout research
cd $BUILD_ROOT/llvm
mkdir build
cd build
cmake -DCMAKE_CXX_COMPILER=g++-7 -DLLVM_ENABLE_RTTI=On -DCMAKE_INSTALL_PREFIX=$BUILD_ROOT/llvm-install ..
make install
Any other appropriate options to the LLVM CMake invocation can be used.
AccSynt
cd $BUILD_ROOT
git clone https://github.com/Baltoli/accsynt.git
mkdir accsynt/build
cd accsynt/build
cmake -DCMAKE_CXX_COMPILER=g++-7 -DLLVM_DIR=$BUILD_ROOT/llvm-install/lib/cmake/llvm ../src
make install
Usage
The project builds a number of different tools for the program synthesis workflow.
convert
This tool converts an LLVM function into IDL constraints that can be used to detect similar computations to that function.
detect
This tool loads a shared library containing an LLVM pass that detects an IDL idiom, then runs it against an IR module to generate a report. These shared libraries can be generated by the tools from the custom LLVM installation above.