Module PolkaGrid

module PolkaGrid: sig .. end
Reduced product of NewPolka polyhedra and PPL grids

type 'a t 
Type of abstract values, where 'a is Polka.loose or Polka.strict.
val manager_alloc : 'a Polka.t Apron.Manager.t ->
Ppl.grid Ppl.t Apron.Manager.t -> 'a t Apron.Manager.t
Create a PolkaGrid manager from a (loose or strict) polka manager, and a PPL grid manager
val manager_decompose : 'a t Apron.Manager.t ->
'a Polka.t Apron.Manager.t * Ppl.grid Ppl.t Apron.Manager.t
Decompose the manager
val decompose : 'a t Apron.Abstract0.t ->
'a Polka.t Apron.Abstract0.t * Ppl.grid Ppl.t Apron.Abstract0.t
Decompose an abstract value
val compose : 'a t Apron.Manager.t ->
'a Polka.t Apron.Abstract0.t ->
Ppl.grid Ppl.t Apron.Abstract0.t -> 'a t Apron.Abstract0.t
Compose an abstract value

Type conversions


val manager_is_polkagrid : 'a Apron.Manager.t -> bool
Return true iff the argument manager is a polkagrid manager
val manager_of_polkagrid : 'a t Apron.Manager.t -> 'b Apron.Manager.t
Makes a polkagrid manager generic
val manager_to_polkagrid : 'a Apron.Manager.t -> 'b t Apron.Manager.t
Instanciate the type of a polkagrid manager. Raises Failure if the argument manager is not a polkagrid manager
module Abstract0: sig .. end
module Abstract1: sig .. end

Compilation information

See Compiling and linking client programs against APRON for complete explanations. We just show examples with the file mlexample.ml.

Do not forget the -cc "g++" option: PPL is a C++ library which requires a C++ linker.

Bytecode compilation

ocamlc -cc "g++"-I $MLGMPIDL_PREFIX/lib -I $APRON_PREFIX/lib -o mlexample.byte \
  bigarray.cma gmp.cma apron.cma polkaMPQ.cma ppl.cma polkaGrid.cma mlexample.ml

ocamlc -cc "g++" -I $MLGMPIDL_PREFIX/lib -I $APRON_PREFIX/lib -make-runtime -o myrun \
  bigarray.cma gmp.cma apron.cma polkaMPQ.cma ppl.cma polkaGrid.cma 

ocamlc -cc "g++" -I $MLGMPIDL_PREFIX/lib -I $APRON_PREFIX/lib -use-runtime myrun -o mlexample.byte \
  bigarray.cma gmp.cma apron.cma polkaMPQ.cma ppl.cma polkaGrid.cma mlexample.ml 

Native-code compilation

ocamlopt -cc "g++" -I $MLGMPIDL_PREFIX/lib -I $APRON_PREFIX/lib -o mlexample.opt \
  bigarray.cmxa gmp.cmxa apron.cmxa polkaMPQ.cmxa ppl.cmxa polkaGrid.cmxa mlexample.ml 

Without auto-linking feature

ocamlopt -cc "g++" -I $MLGMPIDL_PREFIX/lib -I $APRON_PREFIX/lib -noautolink -o mlexample.opt \
  bigarray.cmxa gmp.cmxa apron.cmxa polkaMPQ.cmxa ppl.cmxa polkaGrid.cmxa mlexample.ml \
  -cclib "-L$MLGMPIDL_PREFIX/lib -L$APRON_PREFIX/lib -L$PPL_PREFIX/lib \
          -lpolkaGrid_caml_debug -lap_pkgrid_debug \
          -lpolkaMPQ_caml_debug -lpolkaMPQ_debug \
	  -lap_ppl_caml_debug -lap_ppl_debug -lppl -lgmpxx \
	  -lapron_caml_debug -lapron_debug \
	  -lgmp_caml -L$MPFR_PREFIX/lib -lmpfr -L$GMP_PREFIX/lib -lgmp \
	  -L$CAMLIDL_PREFIX/lib/ocaml -lcamlidl \
	  -lbigarray"