use isl_*_reset_user instead of *_anonymize
[pet.git] / README
blobb16e84f93d31860b29d165579435ef6082f94b44
1 Requirements:
3 - pkg-config (http://www.freedesktop.org/wiki/Software/pkg-config)
4         (not needed when compiling a release using the included isl)
5 - gmp (http://gmplib.org/)
6 - libyaml (http://pyyaml.org/wiki/LibYAML)
7         (only needed if you want to compile the pet executable)
8 - LLVM/clang libraries, 2.9 or higher (http://clang.llvm.org/get_started.html)
9         Unless you have some other reasons for wanting to use the svn version,
10         it's best to install the latest release (3.3).
11         The svn version occasionally introduces incompatibilities.
12         Nevertheless, if you encounter any such incompatibilities, please
13         report them so that they can be fixed.
14         Also, if you are following the instructions on how to build
15         the svn version, make sure you also install LLVM
16         (through "make install").  You may want to specify an installation
17         directory using the --prefix configure option.
19         If you configure LLVM using cmake, you may end up with clang libraries
20         that have been compiled with -fno-rtti without this option appearing
21         in the output of "llvm-config --cxxflags".  You may then run into
22         errors about undefined reference to the 'typeinfo' of some classes.
23         You will then have to add this option manually to CXXFLAGS while
24         configuring pet.
26         The ubuntu package libclang-dev (3.0-3) is not sufficient as it does
27         not contain the required libraries.
29 Preparing:
31 Grab the latest release and extract it or get the source from
32 the git repository as follows.  This process requires autoconf,
33 automake and libtool.
35         git clone git://repo.or.cz/pet.git
36         cd pet
37         git submodule init
38         git submodule update
39         ./autogen.sh
41 Compilation:
43         ./configure
44         make
45         make check
47 Use:
49 The main entry point is pet_scop_extract_from_C_source.
50 This function extracts a scop from the C source file with the given name
51 and returns it as a pet_scop.  The scop corresponds to the piece
52 of code delimited by
54     #pragma scop
56 and
58     #pragma endscop
60 The code in between needs to consist only of expression statements,
61 if statements and for statements.  All access relations and loop initializations
62 need to be piecewise quasi-affine.  Conditions are allowed to be non-affine,
63 in which case a separate statement is constructed to evaluate the condition.
65 If the autodetect option has been set, pet will try to automatically
66 detect a scop and no pragmas are required.  On the other hand, pet
67 will not produce any warnings in this case as any code that does not
68 satisfy the requirements is considered to lie outside of the scop.
70 The layout of pet_scop is documented in include/pet.h.