| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Tree expressions of level 1 are created as objects of type
ap_texpr1_t*. They are manipulated in a functional way (except
a few operations), unlike linear expressions on which most operations
acts by side-effects.
typedef enum ap_texpr_op_t {
/* Binary operators */
AP_TEXPR_ADD, AP_TEXPR_SUB, AP_TEXPR_MUL, AP_TEXPR_DIV,
AP_TEXPR_MOD, /* either integer or real, no rounding */
/* Unary operators */
AP_TEXPR_NEG /* no rounding */,
AP_TEXPR_CAST, AP_TEXPR_SQRT,
} ap_texpr_op_t;
|
typedef enum ap_texpr_rtype_t {
AP_RTYPE_REAL, /* real (no rounding) */
AP_RTYPE_INT, /* integer */
AP_RTYPE_SINGLE, /* IEEE 754 32-bit single precision, e.g.: C's float */
AP_RTYPE_DOUBLE, /* IEEE 754 64-bit double precision, e.g.: C's double */
AP_RTYPE_EXTENDED, /* non-standard 80-bit double extended, e.g.: Intel's long double */
AP_RTYPE_QUAD, /* non-standard 128-bit quadruple precision, e.g.: Motorola's long double */
} ap_texpr_rtype_t;
|
typedef enum ap_texpr_rdir_t {
AP_RDIR_NEAREST /* Nearest */
AP_RDIR_ZERO /* Zero (truncation for integers) */
AP_RDIR_UP /* + Infinity */
AP_RDIR_DOWN /* - Infinity */
AP_RDIR_RND, /* All possible mode, non deterministically */
AP_RDIR_SIZE /* Not to be used ! */
} ap_texpr_rdir_t;
|