Change tabbing for everything....
[IRC.git] / Robust / src / Runtime / DSTM / interface / mcpileq.h
1 #ifndef _MCPILEQ_H_
2 #define _MCPILEQ_H_
3
4 #include <pthread.h>
5 #include <stdio.h>
6 #include <stdlib.h>
7 #include <string.h>
8
9 //Structure to make machine groups when prefetching
10 typedef struct objpile {
11   unsigned int oid;
12   short numoffset;
13   short *offset;
14   struct objpile *next;
15 } objpile_t;
16
17 //Structure for prefetching tuples generated by the compiler
18 typedef struct prefetchpile {
19   unsigned int mid;
20   objpile_t *objpiles;
21   struct prefetchpile *next;
22 } prefetchpile_t;
23
24 typedef struct mcpileq {
25   prefetchpile_t *front, *rear;
26   pthread_mutex_t qlock;
27   pthread_mutexattr_t qlockattr;
28   pthread_cond_t qcond;
29 } mcpileq_t;
30
31 void mcpileqInit(void);
32 void mcpileenqueue(prefetchpile_t *, prefetchpile_t *);
33 prefetchpile_t *mcpiledequeue(void);
34 void mcpiledisplay();
35 void mcdealloc(prefetchpile_t *);
36
37 #endif