This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
yap-6.3/packages/cuda/pred.h

48 lines
919 B
C
Raw Normal View History

2013-10-09 13:33:10 +01:00
#ifndef _PRED_H_
#define _PRED_H_
2013-10-17 00:44:24 +01:00
// #define DEBUG_MEM 1
2013-10-09 13:33:10 +01:00
typedef struct Nodo{
int name;
int num_rows;
int num_columns;
int is_fact;
int *address_host_table;
2016-04-19 23:30:02 +01:00
int *negatives;
char *predname;
double *weight;
2013-10-09 13:33:10 +01:00
}gpunode;
typedef gpunode predicate;
2016-04-19 23:30:02 +01:00
//#define TIMER 1
#define DATALOG 1
#define NUM_T 4
#define INISIZE 1000000
2013-10-16 16:19:03 +01:00
#if TIMER
typedef struct Stats{
size_t joins, selects, unions, builtins;
size_t calls;
double total_time;
float max_time, min_time;
float select1_time, select2_time, join_time, sort_time, union_time, pred_time;
}statinfo;
extern statinfo cuda_stats;
#endif
2016-04-19 23:30:02 +01:00
/*Constants used to mark comparison predicates*/
#define BPOFFSET (-6)
2013-10-09 14:59:57 +01:00
#define SBG_EQ (-1)
#define SBG_GT (-2)
#define SBG_LT (-3)
#define SBG_GE (-4)
#define SBG_LE (-5)
#define SBG_DF (-6)
2016-04-19 23:30:02 +01:00
int Cuda_Eval(predicate**, int, predicate**, int, int*, int**, char*, int);
2013-10-16 16:19:03 +01:00
void Cuda_Statistics( void );
2013-10-09 13:33:10 +01:00
#endif