ReactOS  0.4.15-dev-4610-g11e0ed3
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 {
71  };
74  DWORD Name;
77 
78 typedef struct _IMAGE_THUNK_DATA64
79 {
80  union {
85  } u1;
87 
88 typedef struct _RUNTIME_FUNCTION
89 {
94 
95 typedef union _UNWIND_CODE
96 {
97  struct
98  {
100  UBYTE UnwindOp:4;
101  UBYTE OpInfo:4;
102  };
105 
106 enum
107 {
111 };
112 
113 typedef struct _UNWIND_INFO
114 {
115  UBYTE Version:3;
116  UBYTE Flags:5;
120  UBYTE FrameOffset:4;
122 /* union {
123  OPTIONAL ULONG ExceptionHandler;
124  OPTIONAL ULONG FunctionEntry;
125  };
126  OPTIONAL ULONG ExceptionData[];
127 */
129 
130 typedef struct _C_SCOPE_TABLE_ENTRY
131 {
137 
138 typedef struct _C_SCOPE_TABLE
139 {
143 
144 
145 typedef struct
146 {
148  char *pName;
149  void *p;
151 } SECTION;
152 
153 typedef struct
154 {
155  char* FilePtr;
156  size_t cbInFileSize;
158 
159  /* PE data pointers */
167  void *Symbols;
168  char *Strings;
171  char *UseSection;
172 
173  /* Sections */
176 
180 
181  char *AlignBuf;
182 
186 
void * p
Definition: rsym64.h:149
char * FilePtr
Definition: rsym64.h:155
union _UNWIND_CODE UNWIND_CODE
struct _IMAGE_THUNK_DATA64 * PIMAGE_THUNK_DATA64
struct _UNWIND_INFO * PUNWIND_INFO
BYTE FrameOffset
Definition: cpu_x86_64.c:67
ULONG Target
Definition: rsym64.h:135
struct _FILE_INFO FILE_INFO
struct FILE_INFO * PFILE_INFO
SECTION eh_frame
Definition: rsym64.h:177
ULONG NewSectionHeaderSize
Definition: rsym64.h:165
ULONG64 ImageBase
Definition: rsym64.h:169
BYTE UnwindOp
Definition: cpu_x86_64.c:54
struct _UNWIND_INFO UNWIND_INFO
struct _C_SCOPE_TABLE * PC_SCOPE_TABLE
ULONG cScopes
Definition: rsym64.h:185
struct _C_SCOPE_TABLE C_SCOPE_TABLE
union _IMAGE_THUNK_DATA64::@2087 u1
char * AlignBuf
Definition: rsym64.h:181
ULONG FunctionEnd
Definition: rsym64.h:91
ULONG cUWOP
Definition: rsym64.h:184
PIMAGE_OPTIONAL_HEADER64 OptionalHeader
Definition: rsym64.h:162
BYTE CodeOffset
Definition: cpu_x86_64.c:53
ULONGLONG AddressOfData
Definition: ntimage.h:505
PIMAGE_SECTION_HEADER NewSectionHeaders
Definition: rsym64.h:164
struct _SECTION SECTION
void * Symbols
Definition: rsym64.h:167
SECTION xdata
Definition: rsym64.h:179
SECTION pdata
Definition: rsym64.h:178
BYTE Version
Definition: cpu_x86_64.c:62
BYTE FrameRegister
Definition: cpu_x86_64.c:66
uint64_t ULONGLONG
Definition: typedefs.h:67
ULONG End
Definition: rsym64.h:133
size_t cbNewFileSize
Definition: rsym64.h:157
unsigned long DWORD
Definition: ntddk_ex.h:95
uint64_t ULONG64
Definition: rsym64.h:9
ULONGLONG Function
Definition: ntimage.h:503
struct _RUNTIME_FUNCTION RUNTIME_FUNCTION
unsigned char UBYTE
Definition: lzx.c:48
struct _RUNTIME_FUNCTION * PRUNTIME_FUNCTION
unsigned __int64 ULONG64
Definition: imports.h:198
PIMAGE_FILE_HEADER FileHeader
Definition: rsym64.h:161
char * pName
Definition: rsym64.h:148
size_t cbInFileSize
Definition: rsym64.h:156
struct _IMAGE_IMPORT_DESCRIPTOR IMAGE_IMPORT_DESCRIPTOR
UNWIND_CODE UnwindCode[1]
Definition: cpu_x86_64.c:68
struct _IMAGE_IMPORT_DESCRIPTOR * PIMAGE_IMPORT_DESCRIPTOR
BYTE SizeOfProlog
Definition: cpu_x86_64.c:64
USHORT FrameOffset
Definition: cpu_x86_64.c:57
UINT64 uint64_t
Definition: types.h:77
unsigned short USHORT
Definition: pedump.c:61
ULONG NumEntries
Definition: rsym64.h:140
IMAGE_SECTION_HEADER * psh
Definition: rsym64.h:147
ULONG HeaderSize
Definition: rsym64.h:170
union _UNWIND_CODE * PUNWIND_CODE
ULONG idx
Definition: rsym64.h:150
PIMAGE_SECTION_HEADER SectionHeaders
Definition: rsym64.h:163
struct _IMAGE_THUNK_DATA64 IMAGE_THUNK_DATA64
ULONG FunctionStart
Definition: rsym64.h:90
unsigned char UBYTE
Definition: rsym64.h:4
PIMAGE_DOS_HEADER DosHeader
Definition: rsym64.h:160
ULONG UsedSections
Definition: rsym64.h:175
unsigned int ULONG
Definition: retypes.h:1
char * UseSection
Definition: rsym64.h:171
Definition: rsym64.h:130
ULONG cFuncs
Definition: rsym64.h:183
ULONG UnwindInfo
Definition: rsym64.h:92
ULONGLONG ForwarderString
Definition: ntimage.h:502
PIMAGE_BASE_RELOCATION Relocations
Definition: rsym64.h:166
ULONG AllSections
Definition: rsym64.h:174
char * Strings
Definition: rsym64.h:168
ULONGLONG Ordinal
Definition: ntimage.h:504
ULONG Begin
Definition: rsym64.h:132
base of all file and directory entries
Definition: entries.h:82
BYTE CountOfCodes
Definition: cpu_x86_64.c:65
#define __int64
Definition: basetyps.h:16
ULONG Handler
Definition: rsym64.h:134
struct _C_SCOPE_TABLE_ENTRY C_SCOPE_TABLE_ENTRY
struct _C_SCOPE_TABLE_ENTRY * PC_SCOPE_TABLE_ENTRY