-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathinstructions.h
50 lines (44 loc) · 1.04 KB
/
instructions.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
48
49
50
#ifndef INSTRUCTIONS_H
#define INSTRUCTIONS_H
#include "instlib.H"
#include <list>
#include <vector>
// These are used as a bit field to check operand types
enum OPTYPES : UINT32
{
NONE_OPERATOR_TYPE = 0,
READ_OPERATOR_TYPE = 1,
WRITE_OPERATOR_TYPE = 2,
BOTH_OPERATOR_TYPE = 3
};
enum instructionType
{
IGNORED_INS_TYPE, // Instruction is not traced at all
NORMAL_INS_TYPE, // Standard instruction
MOVEONLY_INS_TYPE, // Instruction only moves memory or registers
X87_INS_TYPE // X87 Instruction that is not supported
};
struct instructionLocationsData
{
instructionLocationsData(){ip=0;logged = FALSE;};
vector<xed_reg_enum_t> registers_read;
vector<xed_reg_enum_t> registers_written;
list<long long> loopid;
ADDRINT ip;
bool logged;
instructionType type;
UINT32 memOperands;
USIZE memReadSize;
USIZE memWriteSize;
string rtn_name;
};
struct instructionDebugData
{
instructionDebugData(){line_number=0;col_number=0;};
string file_name;
int line_number;
int col_number; // Not reported
bool logged;
string instruction;
};
#endif