Files
concrete/compiler
Andi Drebes 45577fb79e Rebase onto llvm-project f69328049e9e with local changes
This commit rebases the compiler onto commit f69328049e9e from
llvm-project.

Changes:

* Use of the one-shot bufferizer for improved memory management

* A new pass `OneShotBufferizeDPSWrapper` that converts functions
  returning tensors to destination-passing-style as required by the
  one-shot bufferizer

* A new pass `LinalgGenericOpWithTensorsToLoopsPass` that converts
  `linalg.generic` operations with value semantics to loop nests

* Rebase onto a fork of llvm-project at f69328049e9e with local
  modifications to enable bufferization of `linalg.generic` operations
  with value semantics

* Workaround for the absence of type propagation after type conversion
  via extra patterns in all dialect conversion passes

* Printer, parser and verifier definitions moved from inline
  declarations in ODS to the respective source files as required by
  upstream changes

* New tests for functions with a large number of inputs

* Increase the number of allowed task inputs as required by new tests

* Use upstream function `mlir_configure_python_dev_packages()` to
  locate Python development files for compatibility with various CMake
  versions

Co-authored-by: Quentin Bourgerie <quentin.bourgerie@zama.ai>
Co-authored-by: Ayoub Benaissa <ayoub.benaissa@zama.ai>
Co-authored-by: Antoniu Pop <antoniu.pop@zama.ai>
2022-06-14 14:35:25 +02:00
..
2021-06-04 09:18:14 +02:00
2022-03-17 16:15:02 +01:00

Building the compiler

Install MLIR following https://mlir.llvm.org/getting_started/ Use commit c2415d67a564

Install pybind11:

pip install pybind11

Build concrete library:

git clone https://github.com/zama-ai/concrete_internal
cd concrete_internal
git checkout engine_c_api
cd concrete-ffi
RUSTFLAGS="-C target-cpu=native" cargo build --release 

Generate the compiler build system, in the build directory

export LLVM_PROJECT="PATH_TO_LLVM_PROJECT"
export CONCRETE_PROJECT="PATH_TO_CONCRETE_INTERNAL_PROJECT"
make build-initialized

Build the compiler

make concretecompiler

Test the compiler

#TODO: let cmake set this PATH
export LD_LIBRARY_PATH="path_to_concrete-compiler/compiler/build/lib/Runtime/"
make test

Run the compiler

./build/src/concretecompiler