Go to file
Nathanaël Courant 4312b2188d README -> README.md 2020-10-07 11:13:37 +02:00
VPL@49c5847e10 Add VPL submodule 2018-06-04 13:25:12 +02:00
doc Documentation: add references to the paper 2020-10-07 11:07:54 +02:00
ocaml Fix a few minor bugs, add README and nix file 2020-10-05 15:09:06 +02:00
tools Code generation with multiple polyhedra: finally works! 2018-07-03 17:24:14 +02:00
.gitignore Fix Makefile 2020-10-05 17:57:04 +02:00
.gitmodules Add VPL submodule 2018-06-04 13:25:12 +02:00
ASTGen.v Add license at the top of files 2018-07-19 11:58:58 +02:00
Canonizer.v Add license at the top of files 2018-07-19 11:58:58 +02:00
CodeGen.v Add toplevel semantics preservation theorem 2018-07-19 11:58:59 +02:00
Extraction.v Fix a few minor bugs, add README and nix file 2020-10-05 15:09:06 +02:00
Heuristics.v Add license at the top of files 2018-07-19 11:58:58 +02:00
ImpureAlarmConfig.v Add license at the top of files 2018-07-19 11:58:58 +02:00
ImpureOperations.v Add license at the top of files 2018-07-19 11:58:58 +02:00
Instr.v Add license at the top of files 2018-07-19 11:58:58 +02:00
LICENSE Add LICENSE file 2018-07-19 13:28:51 +02:00
Linalg.v Add toplevel semantics preservation theorem 2018-07-19 11:58:59 +02:00
Loop.v Add license at the top of files 2018-07-19 11:58:58 +02:00
LoopGen.v Add license at the top of files 2018-07-19 11:58:58 +02:00
Makefile Fix Makefile 2020-10-05 17:57:04 +02:00
Misc.v Add toplevel semantics preservation theorem 2018-07-19 11:58:59 +02:00
Mymap.v Add license at the top of files 2018-07-19 11:58:58 +02:00
PolyLang.v Add toplevel semantics preservation theorem 2018-07-19 11:58:59 +02:00
PolyLoop.v Add license at the top of files 2018-07-19 11:58:58 +02:00
PolyLoopSimpl.v Add license at the top of files 2018-07-19 11:58:58 +02:00
PolyOperations.v Add license at the top of files 2018-07-19 11:58:58 +02:00
PolyTest.v Add license at the top of files 2018-07-19 11:58:58 +02:00
Projection.v Add license at the top of files 2018-07-19 11:58:58 +02:00
README.md README -> README.md 2020-10-07 11:13:37 +02:00
Result.v Add license at the top of files 2018-07-19 11:58:58 +02:00
Semantics.v Add license at the top of files 2018-07-19 11:58:58 +02:00
TopoSort.v Add license at the top of files 2018-07-19 11:58:58 +02:00
VplInterface.v Add license at the top of files 2018-07-19 11:58:58 +02:00
_CoqProject Add _CoqProject 2018-06-25 17:18:03 +02:00
default.nix Make building of documentation working 2020-10-05 16:07:04 +02:00

README.md

Installing dependencies

The Coq development requires Coq version 8.7.2 and OCaml between 4.05.0 and 4.07.1 and may not work with newer versions of Coq and OCaml.

You will need the bundled version of the Verimag Polyhedra Library, which you can get with:

git submodule init
git submodule update --recursive

Some additional C and OCaml libraries are required, as described below.

We recommend to use either OPAM (the OCaml package manager) or Nix (a Linux package manager).

With OPAM

Create a new OPAM switch: opam switch create polygen 4.06.1+flambda. Install GMP, Debian/Ubuntu package libgmp-dev Install GLPK, Debian/Ubuntu package libglpk-dev Install eigen, Debian/Ubuntu package libeigen3-dev. Install the following ocaml packages: opam install zarith glpk menhir coq=8.7.2.

With Nix

Another way is to use nix. Type nix-shell to get a shell where all dependencies have been downloaded and installed. One way to install nix is:

curl https://nixos.org/nix/install | sh

Note that, if you use OPAM, the OPAM init scripts can add your current version of ocaml to your $PATH. In that case, it is advised to use nix-shell --pure, which will run a shell where all dependencies have been downloaded and installed, but no other programs will be available, avoiding the conflicts with a preexisting OPAM installation.

Compiling

There are four steps for compiling the code:

  • Setup the VPL: make vplsetup. This step compiles the bundled version of the Verimag Polyhedra Library that we use.
  • Compile the Coq files: make.
  • Extract the code generator to OCaml: make extract.
  • Compile the extracted code: make ocaml.

The executable running the code generator on different tests will be in ocaml/test. Just run ./ocaml/test, the results will be displayed on standard output.

Alternatively, if using nix, you can just type nix build, and the executable will be available in result/bin/test.

You can build the documentation with make documentation, and it will be available in doc/index.html, or result/doc/index.html if you used nix build.