BAM
Abstract Machine for Bottom-Up Evaluation with the Push Method
Main Page
Related Pages
Classes
Files
File List
File Members
emu
itype.h
Go to the documentation of this file.
1
// ============================================================================
2
// Project: Deductive Database
3
// Filename: itype.h
4
// Purpose: Enumeration Type for classifying BAM instructions by arguments
5
// Last Change: 19.09.2017
6
// Language: C++
7
// EMail: brass@informatik.uni-halle.de
8
// WWW: http://www.informatik.uni-halle.de/~brass/
9
// Address: Feldschloesschen 15, D-06120 Halle (Saale), GERMANY
10
// Copyright: (c) 2017 by Stefan Brass
11
// License: See file "LICENSE" for copying conditions.
12
// Note: There is no warranty at all - this code may contain bugs.
13
// ============================================================================
14
15
22
//=============================================================================
23
// Include File Frame:
24
//=============================================================================
25
26
#ifndef ITYPE_INCLUDED
27
#define ITYPE_INCLUDED
28
29
//=============================================================================
30
// Used Types and Macros:
31
//=============================================================================
32
33
#ifndef VER_INCLUDED
34
#include "../base/ver.h"
35
#endif
36
37
#ifndef STR_INCLUDED
38
#include "../base/str.h"
39
#endif
40
41
#ifndef CHECK_INCLUDED
42
#include "../base/check.h"
43
#endif
44
45
//=============================================================================
46
// Exported Types:
47
//=============================================================================
48
49
//-----------------------------------------------------------------------------
50
// itype_t: Instruction types (classified by number and length of arguments).
51
//-----------------------------------------------------------------------------
52
57
typedef
enum
itype_enum
{
58
// Instruction with no arguments:
59
ITYPE_NONE,
60
61
// Instruction with one 8 bit argument:
62
ITYPE_8,
63
64
// Instruction with one 16 bit argument:
65
ITYPE_16,
66
67
// Instruction with two 8 bit arguments:
68
ITYPE_8_8,
69
70
// Instruction with three 8 bit arguments:
71
ITYPE_8_8_8,
72
73
// Instruction with one 8 bit argument and one 16 bit argument:
74
ITYPE_8_16,
75
76
// Instruction with three arguments (8 bit, 16 bit, 8 bit):
77
ITYPE_8_16_8,
78
79
}
itype_t
;
80
81
82
//=============================================================================
83
// Exported Functions:
84
//=============================================================================
85
86
//-----------------------------------------------------------------------------
87
// itype_valid: Is the parameter a valid element of the enumeration type?
88
//-----------------------------------------------------------------------------
89
90
#if VER_DEBUG
91
97
bool
itype_valid(
itype_t
itype);
98
#endif
99
100
//-----------------------------------------------------------------------------
101
// itype_name: String representation of this instruction type.
102
//-----------------------------------------------------------------------------
103
110
str_t
itype_name
(
itype_t
itype);
111
112
113
//=============================================================================
114
// End of File:
115
//=============================================================================
116
117
#endif
118
itype_t
enum itype_enum itype_t
itype_name
str_t itype_name(itype_t itype)
Definition:
itype.cpp:70
itype_enum
itype_enum
Definition:
itype.h:57
str_t
const char * str_t
Definition:
str.h:41
Generated by
1.8.10