-
Notifications
You must be signed in to change notification settings - Fork 0
/
global.h
47 lines (32 loc) · 1.22 KB
/
global.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#ifndef _GLOBAL_H_
#define _GLOBAL_H_
/* ***************************************************************** */
/* */
/* */
/* ***************************************************************** */
/* The global declarations that every C file should have */
#define _GNU_SOURCE /* for strcasestr */
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <string.h>
#define CAST(t,v) ((t)(v))
typedef short Boolean;
#define TRUE 1
#define FALSE 0
typedef char *String;
Boolean debug;
FILE *debug_file;
/* A byte is just 8 bits */
typedef unsigned char byte;
/* A memory address is a 32-bit integer */
typedef int memory_address;
enum memory_access_type { MAT_LOAD, MAT_STORE, MAT_FETCH };
#define NUMBER_OF_MEMORY_ACCESS_TYPE 3
/* The type of the statistics counters */
typedef int counter_t;
/* ***************************************************************** */
/* */
/* */
/* ***************************************************************** */
#endif