PPL
1.2
|
The base class of all concrete expressions. More...
#include <Concrete_Expression_types.hh>
Related Functions | |
(Note that these are not member functions.) | |
template<typename Target , typename FP_Interval_Type > | |
static bool | add_linearize (const Binary_Operator< Target > &bop_expr, const FP_Oracle< Target, FP_Interval_Type > &oracle, const std::map< dimension_type, Linear_Form< FP_Interval_Type > > &lf_store, Linear_Form< FP_Interval_Type > &result) |
template<typename Target , typename FP_Interval_Type > | |
static bool | sub_linearize (const Binary_Operator< Target > &bop_expr, const FP_Oracle< Target, FP_Interval_Type > &oracle, const std::map< dimension_type, Linear_Form< FP_Interval_Type > > &lf_store, Linear_Form< FP_Interval_Type > &result) |
template<typename Target , typename FP_Interval_Type > | |
static bool | mul_linearize (const Binary_Operator< Target > &bop_expr, const FP_Oracle< Target, FP_Interval_Type > &oracle, const std::map< dimension_type, Linear_Form< FP_Interval_Type > > &lf_store, Linear_Form< FP_Interval_Type > &result) |
template<typename Target , typename FP_Interval_Type > | |
static bool | div_linearize (const Binary_Operator< Target > &bop_expr, const FP_Oracle< Target, FP_Interval_Type > &oracle, const std::map< dimension_type, Linear_Form< FP_Interval_Type > > &lf_store, Linear_Form< FP_Interval_Type > &result) |
template<typename Target , typename FP_Interval_Type > | |
static bool | cast_linearize (const Cast_Operator< Target > &cast_expr, const FP_Oracle< Target, FP_Interval_Type > &oracle, const std::map< dimension_type, Linear_Form< FP_Interval_Type > > &lf_store, Linear_Form< FP_Interval_Type > &result) |
template<typename Target , typename FP_Interval_Type > | |
bool | linearize (const Concrete_Expression< Target > &expr, const FP_Oracle< Target, FP_Interval_Type > &oracle, const std::map< dimension_type, Linear_Form< FP_Interval_Type > > &lf_store, Linear_Form< FP_Interval_Type > &result) |
Linearizes a floating point expression. More... | |
The base class of all concrete expressions.
Definition at line 28 of file Concrete_Expression_types.hh.
|
related |
Helper function used by linearize
to linearize a sum of floating point expressions.
Makes result
become the linearization of *this
in the given composite abstract store.
Target | A type template parameter specifying the instantiation of Concrete_Expression to be used. |
FP_Interval_Type | A type template parameter for the intervals used in the abstract domain. The interval bounds should have a floating point type. |
true
if the linearization succeeded, false
otherwise.bop_expr | The binary operator concrete expression to linearize. Its binary operator type must be ADD . |
oracle | The FP_Oracle to be queried. |
lf_store | The linear form abstract store. |
result | The modified linear form. |
Let and
be two linear forms and
a sound abstract operator on linear forms such that:
Given an expression and a composite abstract store
, we construct the interval linear form
as follows:
where is the relative error associated to
(see method
relative_error
of class Linear_Form) and is a rounding error computed by function
compute_absolute_error
.
Definition at line 110 of file linearize.hh.
References Parma_Polyhedra_Library::Linear_Form< C >::overflows(), and Parma_Polyhedra_Library::Linear_Form< C >::relative_error().
|
related |
Helper function used by linearize
to linearize a cast floating point expression.
Makes result
become the linearization of *this
in the given composite abstract store.
Target | A type template parameter specifying the instantiation of Concrete_Expression to be used. |
FP_Interval_Type | A type template parameter for the intervals used in the abstract domain. The interval bounds should have a floating point type. |
true
if the linearization succeeded, false
otherwise.cast_expr | The cast operator concrete expression to linearize. |
oracle | The FP_Oracle to be queried. |
lf_store | The linear form abstract store. |
result | The modified linear form. |
Definition at line 635 of file linearize.hh.
References Parma_Polyhedra_Library::FP_Oracle< Target, FP_Interval_Type >::get_integer_expr_value(), Parma_Polyhedra_Library::is_less_precise_than(), Parma_Polyhedra_Library::Linear_Form< C >::overflows(), and Parma_Polyhedra_Library::Linear_Form< C >::relative_error().
|
related |
Helper function used by linearize
to linearize a division of floating point expressions.
Makes result
become the linearization of *this
in the given composite abstract store.
Target | A type template parameter specifying the instantiation of Concrete_Expression to be used. |
FP_Interval_Type | A type template parameter for the intervals used in the abstract domain. The interval bounds should have a floating point type. |
true
if the linearization succeeded, false
otherwise.bop_expr | The binary operator concrete expression to linearize. Its binary operator type must be DIV . |
oracle | The FP_Oracle to be queried. |
lf_store | The linear form abstract store. |
result | The modified linear form. |
Let and
be two linear forms,
and
two sound abstract operator on linear forms such that:
Given an expression and a composite abstract store
, we construct the interval linear form
as follows:
given an expression and a composite abstract store
, we construct the interval linear form
as follows:
where is the relative error associated to
(see method
relative_error
of class Linear_Form), is the intervalization of
(see method
intervalize
of class Linear_Form), and is a rounding error computed by function
compute_absolute_error
.
Definition at line 560 of file linearize.hh.
References Parma_Polyhedra_Library::Linear_Form< C >::overflows(), and Parma_Polyhedra_Library::Linear_Form< C >::relative_error().
|
related |
Linearizes a floating point expression.
Makes result
become a linear form that correctly approximates the value of expr
in the given composite abstract store.
Target | A type template parameter specifying the instantiation of Concrete_Expression to be used. |
FP_Interval_Type | A type template parameter for the intervals used in the abstract domain. The interval bounds should have a floating point type. |
true
if the linearization succeeded, false
otherwise.expr | The concrete expression to linearize. |
oracle | The FP_Oracle to be queried. |
lf_store | The linear form abstract store. |
result | Becomes the linearized expression. |
Formally, if expr
represents the expression and
lf_store
represents the linear form abstract store , then
result
will become if the linearization succeeds.
Definition at line 729 of file linearize.hh.
References Parma_Polyhedra_Library::EMPTY, Parma_Polyhedra_Library::FP_Oracle< Target, FP_Interval_Type >::get_associated_dimensions(), Parma_Polyhedra_Library::FP_Oracle< Target, FP_Interval_Type >::get_fp_constant_value(), Parma_Polyhedra_Library::FP_Oracle< Target, FP_Interval_Type >::get_interval(), Parma_Polyhedra_Library::Linear_Form< C >::negate(), Parma_Polyhedra_Library::not_a_dimension(), Parma_Polyhedra_Library::Linear_Form< C >::overflows(), and PPL_COMPILE_TIME_CHECK.
|
related |
Helper function used by linearize
to linearize a product of floating point expressions.
Makes result
become the linearization of *this
in the given composite abstract store.
Target | A type template parameter specifying the instantiation of Concrete_Expression to be used. |
FP_Interval_Type | A type template parameter for the intervals used in the abstract domain. The interval bounds should have a floating point type. |
true
if the linearization succeeded, false
otherwise.bop_expr | The binary operator concrete expression to linearize. Its binary operator type must be MUL . |
oracle | The FP_Oracle to be queried. |
lf_store | The linear form abstract store. |
result | The modified linear form. |
Let and
be two linear forms,
and
two sound abstract operators on linear forms such that:
Given an expression and a composite abstract store
, we construct the interval linear form
as follows:
.
Given an expression and a composite abstract store
, we construct the interval linear form
as follows:
Given an expression and a composite abstract store
, we construct the interval linear form
as follows:
where is the relative error associated to
(see method
relative_error
of class Linear_Form), is the intervalization of
(see method
intervalize
of class Linear_Form), and is a rounding error computed by function
compute_absolute_error
.
Even though we intervalize the first operand in the above example, the actual implementation utilizes an heuristics for choosing which of the two operands must be intervalized in order to obtain the most precise result.
Definition at line 366 of file linearize.hh.
References Parma_Polyhedra_Library::Linear_Form< C >::overflows(), and Parma_Polyhedra_Library::Linear_Form< C >::relative_error().
|
related |
Helper function used by linearize
to linearize a difference of floating point expressions.
Makes result
become the linearization of *this
in the given composite abstract store.
Target | A type template parameter specifying the instantiation of Concrete_Expression to be used. |
FP_Interval_Type | A type template parameter for the intervals used in the abstract domain. The interval bounds should have a floating point type. |
true
if the linearization succeeded, false
otherwise.bop_expr | The binary operator concrete expression to linearize. Its binary operator type must be SUB . |
oracle | The FP_Oracle to be queried. |
lf_store | The linear form abstract store. |
result | The modified linear form. |
Let and
be two linear forms,
and
two sound abstract operators on linear form such that:
Given an expression and a composite abstract store
, we construct the interval linear form
on
as follows:
where is the relative error associated to
(see method
relative_error
of class Linear_Form) and is a rounding error computed by function
compute_absolute_error
.
Definition at line 224 of file linearize.hh.
References Parma_Polyhedra_Library::Linear_Form< C >::overflows(), and Parma_Polyhedra_Library::Linear_Form< C >::relative_error().