GNU PROLOG with UTF8 support
Data Structures | Macros | Typedefs | Functions
fd_range.h File Reference
#include "bool.h"
#include "pl_long.h"
#include "fd_hook_range.h"
Include dependency graph for fd_range.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  Range
 

Macros

#define WORD_SIZE   32
 
#define WORD_SIZE_BITS   5
 
#define Word_No_And_Bit_No(w, b)
 
#define Word_No(n)   ((VecWord) (n) >> WORD_SIZE_BITS)
 
#define Bit_No(n)   ((n) & (((VecWord) 1 << WORD_SIZE_BITS)-1))
 
#define Vector_Test_Value(vec, n)   ((vec[Word_No(n)] & ((VecWord) 1 << Bit_No(n))) != 0)
 
#define Vector_Set_Value(vec, n)   (vec[Word_No(n)] |= ((VecWord) 1 << Bit_No(n)))
 
#define Vector_Reset_Value(vec, n)   (vec[Word_No(n)] &= ~((VecWord) 1 << Bit_No(n)))
 
#define Vector_Allocate_If_Necessary(vec)
 
#define Vector_Allocate(vec)
 
#define VECTOR_BEGIN_ENUM(vec, vec_elem)
 
#define VECTOR_END_ENUM
 
#define Is_Interval(range)   ((range)->vec == NULL)
 
#define Is_Sparse(range)   ((range)->vec != NULL)
 
#define Is_Empty(range)   ((range)->min > (range)->max)
 
#define Is_Not_Empty(range)   ((range)->max >= (range)->min)
 
#define Set_To_Empty(range)   (range)->max = (int)(1 << (sizeof(int) * 8 - 1))
 
#define Range_Init_Interval(range, r_min, r_max)
 

Typedefs

typedef PlULong VecWord
 
typedef VecWordVector
 

Functions

void Pl_Define_Vector_Size (int max_val)
 
void Pl_Vector_From_Interval (Vector vec, int min, int max)
 
int Pl_Vector_Nb_Elem (Vector vec)
 
int Pl_Vector_Ith_Elem (Vector vec, int n)
 
int Pl_Vector_Next_After (Vector vec, int n)
 
int Pl_Vector_Next_Before (Vector vec, int n)
 
void Pl_Vector_Empty (Vector vec)
 
void Pl_Vector_Full (Vector vec)
 
Bool Pl_Vector_Test_Null_Inter (Vector vec, Vector vec1)
 
void Pl_Vector_Copy (Vector vec, Vector vec1)
 
void Pl_Vector_Union (Vector vec, Vector vec1)
 
void Pl_Vector_Inter (Vector vec, Vector vec1)
 
void Pl_Vector_Compl (Vector vec)
 
void Pl_Vector_Add_Vector (Vector vec, Vector vec1)
 
void Pl_Vector_Sub_Vector (Vector vec, Vector vec1)
 
void Pl_Vector_Mul_Vector (Vector vec, Vector vec1)
 
void Pl_Vector_Div_Vector (Vector vec, Vector vec1)
 
void Pl_Vector_Mod_Vector (Vector vec, Vector vec1)
 
void Pl_Vector_Add_Value (Vector vec, int n)
 
void Pl_Vector_Mul_Value (Vector vec, int n)
 
void Pl_Vector_Div_Value (Vector vec, int n)
 
void Pl_Vector_Mod_Value (Vector vec, int n)
 
Bool Pl_Range_Test_Value (Range *range, int n)
 
Bool Pl_Range_Test_Null_Inter (Range *range, Range *range1)
 
void Pl_Range_Copy (Range *range, Range *range1)
 
int Pl_Range_Nb_Elem (Range *range)
 
int Pl_Range_Ith_Elem (Range *range, int n)
 
int Pl_Range_Next_After (Range *range, int n)
 
int Pl_Range_Next_Before (Range *range, int n)
 
void Pl_Range_Set_Value (Range *range, int n)
 
void Pl_Range_Reset_Value (Range *range, int n)
 
void Pl_Range_Becomes_Sparse (Range *range)
 
void Pl_Range_From_Vector (Range *range)
 
void Pl_Range_Union (Range *range, Range *range1)
 
void Pl_Range_Inter (Range *range, Range *range1)
 
void Pl_Range_Compl (Range *range)
 
void Pl_Range_Add_Range (Range *range, Range *range1)
 
void Pl_Range_Sub_Range (Range *range, Range *range1)
 
void Pl_Range_Mul_Range (Range *range, Range *range1)
 
void Pl_Range_Div_Range (Range *range, Range *range1)
 
void Pl_Range_Mod_Range (Range *range, Range *range1)
 
void Pl_Range_Add_Value (Range *range, int n)
 
void Pl_Range_Mul_Value (Range *range, int n)
 
void Pl_Range_Div_Value (Range *range, int n)
 
void Pl_Range_Mod_Value (Range *range, int n)
 
char * Pl_Range_To_String (Range *range)
 

Macro Definition Documentation

#define Bit_No (   n)    ((n) & (((VecWord) 1 << WORD_SIZE_BITS)-1))
#define Is_Empty (   range)    ((range)->min > (range)->max)
#define Is_Interval (   range)    ((range)->vec == NULL)
#define Is_Not_Empty (   range)    ((range)->max >= (range)->min)
#define Is_Sparse (   range)    ((range)->vec != NULL)
#define Range_Init_Interval (   range,
  r_min,
  r_max 
)
Value:
do \
{ \
(range)->extra_cstr = FALSE; \
(range)->min = (r_min); \
(range)->max = (r_max); \
(range)->vec = NULL; \
} \
while (0)
#define FALSE
Definition: bool.h:49
#define Set_To_Empty (   range)    (range)->max = (int)(1 << (sizeof(int) * 8 - 1))
#define Vector_Allocate (   vec)
Value:
do \
{ \
} \
while (0)
VecWord * Vector
Definition: fd_range.h:52
#define RANGE_TOP_STACK
Definition: fd_hook_range.h:43
WamWord pl_vec_size
#define Vector_Allocate_If_Necessary (   vec)
Value:
do \
{ \
if (vec == NULL) \
} \
while (0)
#define Vector_Allocate(vec)
Definition: fd_range.h:229
#define VECTOR_BEGIN_ENUM (   vec,
  vec_elem 
)
Value:
{ \
Vector enum_end = vec + pl_vec_size, enum_i = vec; \
int enum_j; \
VecWord enum_word; \
\
vec_elem = 0; \
do \
{ \
enum_word = *enum_i; \
for (enum_j = 0; enum_j++ < WORD_SIZE; enum_word >>= 1, vec_elem++) \
{ \
if (enum_word & 1) \
{
VecWord * Vector
Definition: fd_range.h:52
PlULong VecWord
Definition: fd_range.h:50
WamWord pl_vec_size
#define WORD_SIZE
Definition: fd_range.h:75
#define VECTOR_END_ENUM
Value:
} \
} \
} \
while (++enum_i < enum_end); \
}
#define Vector_Reset_Value (   vec,
 
)    (vec[Word_No(n)] &= ~((VecWord) 1 << Bit_No(n)))
#define Vector_Set_Value (   vec,
 
)    (vec[Word_No(n)] |= ((VecWord) 1 << Bit_No(n)))
#define Vector_Test_Value (   vec,
 
)    ((vec[Word_No(n)] & ((VecWord) 1 << Bit_No(n))) != 0)
#define Word_No (   n)    ((VecWord) (n) >> WORD_SIZE_BITS)
#define Word_No_And_Bit_No (   w,
 
)
Value:
(((VecWord) (w) << WORD_SIZE_BITS)|\
(VecWord) (b))
PlULong VecWord
Definition: fd_range.h:50
#define WORD_SIZE_BITS
Definition: fd_range.h:82
#define WORD_SIZE   32
#define WORD_SIZE_BITS   5

Typedef Documentation

typedef VecWord* Vector
typedef PlULong VecWord

Function Documentation

void Pl_Define_Vector_Size ( int  max_val)

Here is the caller graph for this function:

void Pl_Range_Add_Range ( Range range,
Range range1 
)

Here is the call graph for this function:

void Pl_Range_Add_Value ( Range range,
int  n 
)

Here is the call graph for this function:

void Pl_Range_Becomes_Sparse ( Range range)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Range_Compl ( Range range)

Here is the call graph for this function:

void Pl_Range_Copy ( Range range,
Range range1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Range_Div_Range ( Range range,
Range range1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Range_Div_Value ( Range range,
int  n 
)

Here is the call graph for this function:

void Pl_Range_From_Vector ( Range range)

Here is the caller graph for this function:

void Pl_Range_Inter ( Range range,
Range range1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int Pl_Range_Ith_Elem ( Range range,
int  n 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Range_Mod_Range ( Range range,
Range range1 
)

Here is the call graph for this function:

void Pl_Range_Mod_Value ( Range range,
int  n 
)

Here is the call graph for this function:

void Pl_Range_Mul_Range ( Range range,
Range range1 
)

Here is the call graph for this function:

void Pl_Range_Mul_Value ( Range range,
int  n 
)

Here is the call graph for this function:

int Pl_Range_Nb_Elem ( Range range)

Here is the call graph for this function:

Here is the caller graph for this function:

int Pl_Range_Next_After ( Range range,
int  n 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int Pl_Range_Next_Before ( Range range,
int  n 
)

Here is the call graph for this function:

void Pl_Range_Reset_Value ( Range range,
int  n 
)

Here is the call graph for this function:

void Pl_Range_Set_Value ( Range range,
int  n 
)

Here is the call graph for this function:

void Pl_Range_Sub_Range ( Range range,
Range range1 
)

Here is the call graph for this function:

Bool Pl_Range_Test_Null_Inter ( Range range,
Range range1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

Bool Pl_Range_Test_Value ( Range range,
int  n 
)

Here is the caller graph for this function:

char* Pl_Range_To_String ( Range range)

Here is the caller graph for this function:

void Pl_Range_Union ( Range range,
Range range1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Vector_Add_Value ( Vector  vec,
int  n 
)

Here is the caller graph for this function:

void Pl_Vector_Add_Vector ( Vector  vec,
Vector  vec1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Vector_Compl ( Vector  vec)

Here is the caller graph for this function:

void Pl_Vector_Copy ( Vector  vec,
Vector  vec1 
)

Here is the caller graph for this function:

void Pl_Vector_Div_Value ( Vector  vec,
int  n 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Vector_Div_Vector ( Vector  vec,
Vector  vec1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Vector_Empty ( Vector  vec)

Here is the caller graph for this function:

void Pl_Vector_From_Interval ( Vector  vec,
int  min,
int  max 
)

Here is the caller graph for this function:

void Pl_Vector_Full ( Vector  vec)

Here is the caller graph for this function:

void Pl_Vector_Inter ( Vector  vec,
Vector  vec1 
)

Here is the caller graph for this function:

int Pl_Vector_Ith_Elem ( Vector  vec,
int  n 
)

Here is the caller graph for this function:

void Pl_Vector_Mod_Value ( Vector  vec,
int  n 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Vector_Mod_Vector ( Vector  vec,
Vector  vec1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Vector_Mul_Value ( Vector  vec,
int  n 
)

Here is the call graph for this function:

Here is the caller graph for this function:

void Pl_Vector_Mul_Vector ( Vector  vec,
Vector  vec1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int Pl_Vector_Nb_Elem ( Vector  vec)

Here is the caller graph for this function:

int Pl_Vector_Next_After ( Vector  vec,
int  n 
)

Here is the caller graph for this function:

int Pl_Vector_Next_Before ( Vector  vec,
int  n 
)

Here is the caller graph for this function:

void Pl_Vector_Sub_Vector ( Vector  vec,
Vector  vec1 
)

Here is the call graph for this function:

Here is the caller graph for this function:

Bool Pl_Vector_Test_Null_Inter ( Vector  vec,
Vector  vec1 
)

Here is the caller graph for this function:

void Pl_Vector_Union ( Vector  vec,
Vector  vec1 
)

Here is the caller graph for this function: