ReactOS
0.4.16-dev-136-g52192f1
rsym64.h
Go to the documentation of this file.
1
#pragma once
2
3
//C_ASSERT(sizeof(ULONG) == 4);
4
typedef
unsigned
char
UBYTE
;
5
#if defined(_MSC_VER) || defined(__MINGW32__)
6
typedef
unsigned
__int64
ULONG64
;
7
#else
8
#include <stdint.h>
9
typedef
uint64_t
ULONG64
;
10
#endif
11
12
13
#define IMAGE_FILE_MACHINE_I386 0x14c
14
#define IMAGE_FILE_MACHINE_AMD64 0x8664
15
#define IMAGE_FILE_MACHINE_ARM64 0xaa64
16
#define IMAGE_DIRECTORY_ENTRY_IMPORT 1
17
#define IMAGE_DIRECTORY_ENTRY_EXCEPTION 3
18
19
#define UWOP_PUSH_NONVOL 0
20
#define UWOP_ALLOC_LARGE 1
21
#define UWOP_ALLOC_SMALL 2
22
#define UWOP_SET_FPREG 3
23
#define UWOP_SAVE_NONVOL 4
24
#define UWOP_SAVE_NONVOL_FAR 5
25
#define UWOP_SAVE_XMM 6
26
#define UWOP_SAVE_XMM_FAR 7
27
#define UWOP_SAVE_XMM128 8
28
#define UWOP_SAVE_XMM128_FAR 9
29
#define UWOP_PUSH_MACHFRAME 10
30
31
#define REG_RAX 0
32
#define REG_RCX 1
33
#define REG_RDX 2
34
#define REG_RBX 3
35
#define REG_RSP 4
36
#define REG_RBP 5
37
#define REG_RSI 6
38
#define REG_RDI 7
39
#define REG_R8 8
40
#define REG_R9 9
41
#define REG_R10 10
42
#define REG_R11 11
43
#define REG_R12 12
44
#define REG_R13 13
45
#define REG_R14 14
46
#define REG_R15 15
47
48
#define REG_XMM0 0
49
#define REG_XMM1 1
50
#define REG_XMM2 2
51
#define REG_XMM3 3
52
#define REG_XMM4 4
53
#define REG_XMM5 5
54
#define REG_XMM6 6
55
#define REG_XMM7 7
56
#define REG_XMM8 8
57
#define REG_XMM9 9
58
#define REG_XMM10 10
59
#define REG_XMM11 11
60
#define REG_XMM12 12
61
#define REG_XMM13 13
62
#define REG_XMM14 14
63
#define REG_XMM15 15
64
65
66
typedef
struct
_IMAGE_IMPORT_DESCRIPTOR
67
{
68
union
{
69
DWORD
Characteristics
;
70
DWORD
OriginalFirstThunk
;
71
};
72
DWORD
TimeDateStamp
;
73
DWORD
ForwarderChain
;
74
DWORD
Name
;
75
DWORD
FirstThunk
;
76
}
IMAGE_IMPORT_DESCRIPTOR
, *
PIMAGE_IMPORT_DESCRIPTOR
;
77
78
typedef
struct
_IMAGE_THUNK_DATA64
79
{
80
union
{
81
ULONGLONG
ForwarderString
;
82
ULONGLONG
Function
;
83
ULONGLONG
Ordinal
;
84
ULONGLONG
AddressOfData
;
85
}
u1
;
86
}
IMAGE_THUNK_DATA64
, *
PIMAGE_THUNK_DATA64
;
87
88
typedef
struct
_RUNTIME_FUNCTION
89
{
90
ULONG
FunctionStart
;
91
ULONG
FunctionEnd
;
92
ULONG
UnwindInfo
;
93
}
RUNTIME_FUNCTION
, *
PRUNTIME_FUNCTION
;
94
95
typedef
union
_UNWIND_CODE
96
{
97
struct
98
{
99
UBYTE
CodeOffset
;
100
UBYTE
UnwindOp
:4;
101
UBYTE
OpInfo
:4;
102
};
103
USHORT
FrameOffset
;
104
}
UNWIND_CODE
, *
PUNWIND_CODE
;
105
106
enum
107
{
108
UNW_FLAG_NHANDLER
= 0x00,
109
UNW_FLAG_EHANDLER
= 0x01,
110
UNW_FLAG_UHANDLER
= 0x02,
111
UNW_FLAG_CHAININFO
= 0x04
112
};
113
114
typedef
struct
_UNWIND_INFO
115
{
116
UBYTE
Version
:3;
117
UBYTE
Flags
:5;
118
UBYTE
SizeOfProlog
;
119
UBYTE
CountOfCodes
;
120
UBYTE
FrameRegister
:4;
121
UBYTE
FrameOffset
:4;
122
UNWIND_CODE
UnwindCode
[1];
123
/* union {
124
OPTIONAL ULONG ExceptionHandler;
125
OPTIONAL ULONG FunctionEntry;
126
};
127
OPTIONAL ULONG ExceptionData[];
128
*/
129
}
UNWIND_INFO
, *
PUNWIND_INFO
;
130
131
typedef
struct
_C_SCOPE_TABLE_ENTRY
132
{
133
ULONG
Begin
;
134
ULONG
End
;
135
ULONG
Handler
;
136
ULONG
Target
;
137
}
C_SCOPE_TABLE_ENTRY
, *
PC_SCOPE_TABLE_ENTRY
;
138
139
typedef
struct
_C_SCOPE_TABLE
140
{
141
ULONG
NumEntries
;
142
C_SCOPE_TABLE_ENTRY
Entry
[1];
143
}
C_SCOPE_TABLE
, *
PC_SCOPE_TABLE
;
144
145
146
typedef
struct
147
{
148
IMAGE_SECTION_HEADER
*
psh
;
149
char
*
pName
;
150
void
*
p
;
151
ULONG
idx
;
152
}
SECTION
;
153
154
typedef
struct
155
{
156
char
*
FilePtr
;
157
size_t
cbInFileSize
;
158
size_t
cbNewFileSize
;
159
160
/* PE data pointers */
161
PIMAGE_DOS_HEADER
DosHeader
;
162
PIMAGE_FILE_HEADER
FileHeader
;
163
PIMAGE_OPTIONAL_HEADER64
OptionalHeader
;
164
PIMAGE_SECTION_HEADER
SectionHeaders
;
165
PIMAGE_SECTION_HEADER
NewSectionHeaders
;
166
ULONG
NewSectionHeaderSize
;
167
PIMAGE_BASE_RELOCATION
Relocations
;
168
void
*
Symbols
;
169
char
*
Strings
;
170
ULONG64
ImageBase
;
171
ULONG
HeaderSize
;
172
char
*
UseSection
;
173
174
/* Sections */
175
ULONG
AllSections
;
176
ULONG
UsedSections
;
177
178
SECTION
eh_frame
;
179
SECTION
pdata
;
180
SECTION
xdata
;
181
182
char
*
AlignBuf
;
183
184
ULONG
cFuncs
;
185
ULONG
cUWOP
;
186
ULONG
cScopes
;
187
188
}
FILE_INFO
, *
PFILE_INFO
;
__int64
#define __int64
Definition:
basetyps.h:16
uint64_t
UINT64 uint64_t
Definition:
types.h:77
DWORD
unsigned long DWORD
Definition:
ntddk_ex.h:95
UBYTE
unsigned char UBYTE
Definition:
lzx.c:48
USHORT
unsigned short USHORT
Definition:
pedump.c:61
UBYTE
unsigned char UBYTE
Definition:
rsym64.h:4
PIMAGE_IMPORT_DESCRIPTOR
struct _IMAGE_IMPORT_DESCRIPTOR * PIMAGE_IMPORT_DESCRIPTOR
PRUNTIME_FUNCTION
struct _RUNTIME_FUNCTION * PRUNTIME_FUNCTION
UNWIND_CODE
union _UNWIND_CODE UNWIND_CODE
IMAGE_THUNK_DATA64
struct _IMAGE_THUNK_DATA64 IMAGE_THUNK_DATA64
PUNWIND_INFO
struct _UNWIND_INFO * PUNWIND_INFO
PC_SCOPE_TABLE
struct _C_SCOPE_TABLE * PC_SCOPE_TABLE
RUNTIME_FUNCTION
struct _RUNTIME_FUNCTION RUNTIME_FUNCTION
UNWIND_INFO
struct _UNWIND_INFO UNWIND_INFO
PUNWIND_CODE
union _UNWIND_CODE * PUNWIND_CODE
PC_SCOPE_TABLE_ENTRY
struct _C_SCOPE_TABLE_ENTRY * PC_SCOPE_TABLE_ENTRY
UNW_FLAG_EHANDLER
@ UNW_FLAG_EHANDLER
Definition:
rsym64.h:109
UNW_FLAG_CHAININFO
@ UNW_FLAG_CHAININFO
Definition:
rsym64.h:111
UNW_FLAG_NHANDLER
@ UNW_FLAG_NHANDLER
Definition:
rsym64.h:108
UNW_FLAG_UHANDLER
@ UNW_FLAG_UHANDLER
Definition:
rsym64.h:110
ULONG64
uint64_t ULONG64
Definition:
rsym64.h:9
PIMAGE_THUNK_DATA64
struct _IMAGE_THUNK_DATA64 * PIMAGE_THUNK_DATA64
IMAGE_IMPORT_DESCRIPTOR
struct _IMAGE_IMPORT_DESCRIPTOR IMAGE_IMPORT_DESCRIPTOR
PFILE_INFO
struct FILE_INFO * PFILE_INFO
C_SCOPE_TABLE_ENTRY
struct _C_SCOPE_TABLE_ENTRY C_SCOPE_TABLE_ENTRY
C_SCOPE_TABLE
struct _C_SCOPE_TABLE C_SCOPE_TABLE
Entry
base of all file and directory entries
Definition:
entries.h:83
FILE_INFO
Definition:
rsym64.h:155
FILE_INFO::FileHeader
PIMAGE_FILE_HEADER FileHeader
Definition:
rsym64.h:162
FILE_INFO::ImageBase
ULONG64 ImageBase
Definition:
rsym64.h:170
FILE_INFO::cbInFileSize
size_t cbInFileSize
Definition:
rsym64.h:157
FILE_INFO::FilePtr
char * FilePtr
Definition:
rsym64.h:156
FILE_INFO::Symbols
void * Symbols
Definition:
rsym64.h:168
FILE_INFO::AllSections
ULONG AllSections
Definition:
rsym64.h:175
FILE_INFO::AlignBuf
char * AlignBuf
Definition:
rsym64.h:182
FILE_INFO::cFuncs
ULONG cFuncs
Definition:
rsym64.h:184
FILE_INFO::Strings
char * Strings
Definition:
rsym64.h:169
FILE_INFO::NewSectionHeaders
PIMAGE_SECTION_HEADER NewSectionHeaders
Definition:
rsym64.h:165
FILE_INFO::HeaderSize
ULONG HeaderSize
Definition:
rsym64.h:171
FILE_INFO::SectionHeaders
PIMAGE_SECTION_HEADER SectionHeaders
Definition:
rsym64.h:164
FILE_INFO::OptionalHeader
PIMAGE_OPTIONAL_HEADER64 OptionalHeader
Definition:
rsym64.h:163
FILE_INFO::UseSection
char * UseSection
Definition:
rsym64.h:172
FILE_INFO::cbNewFileSize
size_t cbNewFileSize
Definition:
rsym64.h:158
FILE_INFO::eh_frame
SECTION eh_frame
Definition:
rsym64.h:178
FILE_INFO::UsedSections
ULONG UsedSections
Definition:
rsym64.h:176
FILE_INFO::cUWOP
ULONG cUWOP
Definition:
rsym64.h:185
FILE_INFO::NewSectionHeaderSize
ULONG NewSectionHeaderSize
Definition:
rsym64.h:166
FILE_INFO::xdata
SECTION xdata
Definition:
rsym64.h:180
FILE_INFO::Relocations
PIMAGE_BASE_RELOCATION Relocations
Definition:
rsym64.h:167
FILE_INFO::DosHeader
PIMAGE_DOS_HEADER DosHeader
Definition:
rsym64.h:161
FILE_INFO::cScopes
ULONG cScopes
Definition:
rsym64.h:186
FILE_INFO::pdata
SECTION pdata
Definition:
rsym64.h:179
SECTION
Definition:
rsym64.h:147
SECTION::idx
ULONG idx
Definition:
rsym64.h:151
SECTION::psh
IMAGE_SECTION_HEADER * psh
Definition:
rsym64.h:148
SECTION::p
void * p
Definition:
rsym64.h:150
SECTION::pName
char * pName
Definition:
rsym64.h:149
_C_SCOPE_TABLE_ENTRY
Definition:
rsym64.h:132
_C_SCOPE_TABLE_ENTRY::Target
ULONG Target
Definition:
rsym64.h:136
_C_SCOPE_TABLE_ENTRY::Handler
ULONG Handler
Definition:
rsym64.h:135
_C_SCOPE_TABLE_ENTRY::Begin
ULONG Begin
Definition:
rsym64.h:133
_C_SCOPE_TABLE_ENTRY::End
ULONG End
Definition:
rsym64.h:134
_C_SCOPE_TABLE
Definition:
rsym64.h:140
_C_SCOPE_TABLE::NumEntries
ULONG NumEntries
Definition:
rsym64.h:141
_IMAGE_BASE_RELOCATION
Definition:
ntimage.h:162
_IMAGE_DOS_HEADER
Definition:
ntddk_ex.h:99
_IMAGE_FILE_HEADER
Definition:
ntddk_ex.h:121
_IMAGE_IMPORT_DESCRIPTOR
Definition:
ntimage.h:572
_IMAGE_IMPORT_DESCRIPTOR::TimeDateStamp
ULONG TimeDateStamp
Definition:
ntimage.h:577
_IMAGE_IMPORT_DESCRIPTOR::Characteristics
ULONG Characteristics
Definition:
ntimage.h:574
_IMAGE_IMPORT_DESCRIPTOR::FirstThunk
ULONG FirstThunk
Definition:
ntimage.h:580
_IMAGE_IMPORT_DESCRIPTOR::ForwarderChain
ULONG ForwarderChain
Definition:
ntimage.h:578
_IMAGE_IMPORT_DESCRIPTOR::Name
ULONG Name
Definition:
ntimage.h:579
_IMAGE_IMPORT_DESCRIPTOR::OriginalFirstThunk
ULONG OriginalFirstThunk
Definition:
ntimage.h:575
_IMAGE_OPTIONAL_HEADER64
Definition:
ntimage.h:340
_IMAGE_SECTION_HEADER
Definition:
pedump.c:280
_IMAGE_THUNK_DATA64
Definition:
ntimage.h:500
_IMAGE_THUNK_DATA64::Function
ULONGLONG Function
Definition:
ntimage.h:503
_IMAGE_THUNK_DATA64::Ordinal
ULONGLONG Ordinal
Definition:
ntimage.h:504
_IMAGE_THUNK_DATA64::ForwarderString
ULONGLONG ForwarderString
Definition:
ntimage.h:502
_IMAGE_THUNK_DATA64::AddressOfData
ULONGLONG AddressOfData
Definition:
ntimage.h:505
_IMAGE_THUNK_DATA64::u1
union _IMAGE_THUNK_DATA64::@2137 u1
_RUNTIME_FUNCTION
Definition:
rsym64.h:89
_RUNTIME_FUNCTION::UnwindInfo
ULONG UnwindInfo
Definition:
rsym64.h:92
_RUNTIME_FUNCTION::FunctionEnd
ULONG FunctionEnd
Definition:
rsym64.h:91
_RUNTIME_FUNCTION::FunctionStart
ULONG FunctionStart
Definition:
rsym64.h:90
_UNWIND_INFO
Definition:
cpu_x86_64.c:61
_UNWIND_INFO::CountOfCodes
BYTE CountOfCodes
Definition:
cpu_x86_64.c:65
_UNWIND_INFO::FrameRegister
BYTE FrameRegister
Definition:
cpu_x86_64.c:66
_UNWIND_INFO::Version
BYTE Version
Definition:
cpu_x86_64.c:62
_UNWIND_INFO::SizeOfProlog
BYTE SizeOfProlog
Definition:
cpu_x86_64.c:64
_UNWIND_INFO::UnwindCode
UNWIND_CODE UnwindCode[1]
Definition:
cpu_x86_64.c:68
_UNWIND_INFO::FrameOffset
BYTE FrameOffset
Definition:
cpu_x86_64.c:67
_UNWIND_INFO::Flags
BYTE Flags
Definition:
cpu_x86_64.c:63
ULONG
uint32_t ULONG
Definition:
typedefs.h:59
ULONGLONG
uint64_t ULONGLONG
Definition:
typedefs.h:67
_UNWIND_CODE
Definition:
cpu_x86_64.c:50
_UNWIND_CODE::UnwindOp
BYTE UnwindOp
Definition:
cpu_x86_64.c:54
_UNWIND_CODE::CodeOffset
BYTE CodeOffset
Definition:
cpu_x86_64.c:53
_UNWIND_CODE::FrameOffset
USHORT FrameOffset
Definition:
cpu_x86_64.c:57
_UNWIND_CODE::OpInfo
BYTE OpInfo
Definition:
cpu_x86_64.c:55
sdk
tools
rsym
rsym64.h
Generated on Tue Oct 15 2024 06:14:10 for ReactOS by
1.9.6