This commit is contained in:
Vitor Santos Costa
2016-04-19 23:30:02 +01:00
parent 3d68f0e06b
commit cd41d373db
28 changed files with 3153 additions and 2229 deletions

12
packages/cuda/pred.h Normal file → Executable file
View File

@@ -9,11 +9,17 @@ typedef struct Nodo{
int num_columns;
int is_fact;
int *address_host_table;
int *negatives;
char *predname;
double *weight;
}gpunode;
typedef gpunode predicate;
// #define TIMER 1
//#define TIMER 1
#define DATALOG 1
#define NUM_T 4
#define INISIZE 1000000
#if TIMER
typedef struct Stats{
@@ -27,6 +33,8 @@ typedef struct Stats{
extern statinfo cuda_stats;
#endif
/*Constants used to mark comparison predicates*/
#define BPOFFSET (-6)
#define SBG_EQ (-1)
#define SBG_GT (-2)
#define SBG_LT (-3)
@@ -34,6 +42,6 @@ extern statinfo cuda_stats;
#define SBG_LE (-5)
#define SBG_DF (-6)
int Cuda_Eval(predicate**, int, predicate**, int, predicate*, int**);
int Cuda_Eval(predicate**, int, predicate**, int, int*, int**, char*, int);
void Cuda_Statistics( void );
#endif