PPL C Language Interface  1.2
ppl_c_header.h File Reference
#include <stdio.h>
#include <gmp.h>
#include <stddef.h>
#include "ppl_c_version.h"
#include "ppl_c_domains.h"
Include dependency graph for ppl_c_header.h:

Go to the source code of this file.

Macros

#define PPL_PROTO(protos)   ()
 
#define PPL_TYPE_DECLARATION(Type)
 
#define PPL_DECLARE_PRINT_FUNCTIONS(Type)
 
#define PPL_DECLARE_ASCII_DUMP_LOAD_FUNCTIONS(Type)
 
#define PPL_DECLARE_IO_FUNCTIONS(Type)
 
#define PPL_DECLARE_AND_DOCUMENT_PRINT_FUNCTIONS(Type)
 
#define PPL_DECLARE_AND_DOCUMENT_ASCII_DUMP_LOAD_FUNCTIONS(Type)
 
#define PPL_DECLARE_AND_DOCUMENT_IO_FUNCTIONS(Type)
 

Typedefs

typedef size_t ppl_dimension_type
 An unsigned integral type for representing space dimensions. More...
 
typedef const charppl_io_variable_output_function_type(ppl_dimension_type var)
 The type of output functions used for printing variables. More...
 

Enumerations

enum  ppl_enum_error_code {
  PPL_ERROR_OUT_OF_MEMORY, PPL_ERROR_INVALID_ARGUMENT, PPL_ERROR_DOMAIN_ERROR, PPL_ERROR_LENGTH_ERROR,
  PPL_ARITHMETIC_OVERFLOW, PPL_STDIO_ERROR, PPL_ERROR_INTERNAL_ERROR, PPL_ERROR_UNKNOWN_STANDARD_EXCEPTION,
  PPL_ERROR_UNEXPECTED_ERROR, PPL_TIMEOUT_EXCEPTION, PPL_ERROR_LOGIC_ERROR
}
 Defines the error codes that any function may return. More...
 
enum  ppl_enum_Constraint_Type {
  PPL_CONSTRAINT_TYPE_LESS_THAN, PPL_CONSTRAINT_TYPE_LESS_OR_EQUAL, PPL_CONSTRAINT_TYPE_EQUAL, PPL_CONSTRAINT_TYPE_GREATER_OR_EQUAL,
  PPL_CONSTRAINT_TYPE_GREATER_THAN
}
 Describes the relations represented by a constraint. More...
 
enum  ppl_enum_Generator_Type { PPL_GENERATOR_TYPE_LINE, PPL_GENERATOR_TYPE_RAY, PPL_GENERATOR_TYPE_POINT, PPL_GENERATOR_TYPE_CLOSURE_POINT }
 Describes the different kinds of generators. More...
 
enum  ppl_enum_Grid_Generator_Type { PPL_GRID_GENERATOR_TYPE_LINE, PPL_GRID_GENERATOR_TYPE_PARAMETER, PPL_GRID_GENERATOR_TYPE_POINT }
 Describes the different kinds of grid generators. More...
 
enum  ppl_enum_Bounded_Integer_Type_Width {
  PPL_BITS_8, PPL_BITS_16, PPL_BITS_32, PPL_BITS_64,
  PPL_BITS_128
}
 Widths of bounded integer types. More...
 
enum  ppl_enum_Bounded_Integer_Type_Representation { PPL_UNSIGNED, PPL_SIGNED_2_COMPLEMENT }
 Representation of bounded integer types. More...
 
enum  ppl_enum_Bounded_Integer_Type_Overflow { PPL_OVERFLOW_WRAPS, PPL_OVERFLOW_UNDEFINED, PPL_OVERFLOW_IMPOSSIBLE }
 Overflow behavior of bounded integer types. More...
 

Functions

int ppl_initialize (void)
 Initializes the Parma Polyhedra Library. This function must be called before any other function. More...
 
int ppl_finalize (void)
 Finalizes the Parma Polyhedra Library. This function must be called after any other function. More...
 
int ppl_set_rounding_for_PPL (void)
 Sets the FPU rounding mode so that the PPL abstractions based on floating point numbers work correctly. More...
 
int ppl_restore_pre_PPL_rounding (void)
 Sets the FPU rounding mode as it was before initialization of the PPL. More...
 
int ppl_irrational_precision (unsigned *p)
 Writes to p the precision parameter used for irrational calculations. More...
 
int ppl_set_irrational_precision (unsigned p)
 Sets the precision parameter used for irrational calculations. More...
 
int ppl_version_major (void)
 Returns the major number of the PPL version. More...
 
int ppl_version_minor (void)
 Returns the minor number of the PPL version. More...
 
int ppl_version_revision (void)
 Returns the revision number of the PPL version. More...
 
int ppl_version_beta (void)
 Returns the beta number of the PPL version. More...
 
int ppl_version (const char **p)
 Writes to *p a pointer to a character string containing the PPL version. More...
 
int ppl_banner (const char **p)
 Writes to *p a pointer to a character string containing the PPL banner. More...
 
int ppl_set_error_handler (void(*h)(enum ppl_enum_error_code code, const char *description))
 Installs the user-defined error handler pointed at by h. More...
 
int ppl_set_timeout (unsigned csecs)
 Sets the timeout for computations whose completion could require an exponential amount of time. More...
 
int ppl_reset_timeout (void)
 Resets the timeout time so that the computation is not interrupted. More...
 
int ppl_set_deterministic_timeout (unsigned long unscaled_weight, unsigned scale)
 Sets a threshold for computations whose completion could require an exponential amount of time. More...
 
int ppl_reset_deterministic_timeout (void)
 Resets the deterministic timeout so that the computation is not interrupted. More...
 
int ppl_max_space_dimension (ppl_dimension_type *m)
 Writes to m the maximum space dimension this library can handle. More...
 
int ppl_not_a_dimension (ppl_dimension_type *m)
 Writes to m a value that does not designate a valid dimension. More...
 
int ppl_io_print_variable (ppl_dimension_type var)
 Pretty-prints var to stdout. More...
 
int ppl_io_fprint_variable (FILE *stream, ppl_dimension_type var)
 Pretty-prints var to the given output stream. More...
 
int ppl_io_asprint_variable (char **strp, ppl_dimension_type var)
 Pretty-prints var to a malloc-allocated string, a pointer to which is returned via strp. More...
 
int ppl_io_set_variable_output_function (ppl_io_variable_output_function_type *p)
 Sets the output function to be used for printing variables to p. More...
 
int ppl_io_get_variable_output_function (ppl_io_variable_output_function_type **pp)
 Writes a pointer to the current variable output function to pp. More...
 
charppl_io_wrap_string (const char *src, unsigned indent_depth, unsigned preferred_first_line_length, unsigned preferred_line_length)
 Utility function for the wrapping of lines of text. More...
 
Constructors, Assignment and Destructor
int ppl_new_Generator_System_zero_dim_univ (ppl_Generator_System_t *pgs)
 
int ppl_new_Grid_Generator_System_zero_dim_univ (ppl_Grid_Generator_System_t *pgs)
 

Variables

unsigned int PPL_COMPLEXITY_CLASS_POLYNOMIAL
 Code of the worst-case polynomial complexity class. More...
 
unsigned int PPL_COMPLEXITY_CLASS_SIMPLEX
 Code of the worst-case exponential but typically polynomial complexity class. More...
 
unsigned int PPL_COMPLEXITY_CLASS_ANY
 Code of the universal complexity class. More...
 
unsigned int PPL_POLY_CON_RELATION_IS_DISJOINT
 Individual bit saying that the polyhedron and the set of points satisfying the constraint are disjoint. More...
 
unsigned int PPL_POLY_CON_RELATION_STRICTLY_INTERSECTS
 Individual bit saying that the polyhedron intersects the set of points satisfying the constraint, but it is not included in it. More...
 
unsigned int PPL_POLY_CON_RELATION_IS_INCLUDED
 Individual bit saying that the polyhedron is included in the set of points satisfying the constraint. More...
 
unsigned int PPL_POLY_CON_RELATION_SATURATES
 Individual bit saying that the polyhedron is included in the set of points saturating the constraint. More...
 
unsigned int PPL_POLY_GEN_RELATION_SUBSUMES
 Individual bit saying that adding the generator would not change the polyhedron. More...
 

Macro Definition Documentation

#define PPL_DECLARE_AND_DOCUMENT_ASCII_DUMP_LOAD_FUNCTIONS (   Type)

Definition at line 803 of file ppl_c_header.h.

#define PPL_DECLARE_AND_DOCUMENT_IO_FUNCTIONS (   Type)
Value:
\ \
Type
#define PPL_DECLARE_AND_DOCUMENT_ASCII_DUMP_LOAD_FUNCTIONS(Type)
Definition: ppl_c_header.h:803
#define PPL_DECLARE_AND_DOCUMENT_PRINT_FUNCTIONS(Type)
Definition: ppl_c_header.h:791

Definition at line 813 of file ppl_c_header.h.

#define PPL_DECLARE_AND_DOCUMENT_PRINT_FUNCTIONS (   Type)

Definition at line 791 of file ppl_c_header.h.

#define PPL_DECLARE_ASCII_DUMP_LOAD_FUNCTIONS (   Type)

Definition at line 777 of file ppl_c_header.h.

#define PPL_DECLARE_IO_FUNCTIONS (   Type)
Value:
Type
#define PPL_DECLARE_PRINT_FUNCTIONS(Type)
Definition: ppl_c_header.h:766
#define PPL_DECLARE_ASCII_DUMP_LOAD_FUNCTIONS(Type)
Definition: ppl_c_header.h:777

Definition at line 787 of file ppl_c_header.h.

#define PPL_DECLARE_PRINT_FUNCTIONS (   Type)

Definition at line 766 of file ppl_c_header.h.

#define PPL_PROTO (   protos)    ()

Definition at line 162 of file ppl_c_header.h.

#define PPL_TYPE_DECLARATION (   Type)
Value:
\
typedef struct ppl_##Type##_tag* ppl_##Type##_t; \ \
typedef struct ppl_##Type##_tag const* ppl_const_##Type##_t;
Type
const

Definition at line 548 of file ppl_c_header.h.

Function Documentation

int ppl_new_Generator_System_zero_dim_univ ( ppl_Generator_System_t *  pgs)
int ppl_new_Grid_Generator_System_zero_dim_univ ( ppl_Grid_Generator_System_t *  pgs)