LLVM 22.0.0git
COFF.h
Go to the documentation of this file.
1//===- COFF.h - COFF object file implementation -----------------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// This file declares the COFFObjectFile class.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_OBJECT_COFF_H
14#define LLVM_OBJECT_COFF_H
15
18#include "llvm/Object/Binary.h"
20#include "llvm/Object/Error.h"
25#include "llvm/Support/Endian.h"
28#include <cassert>
29#include <cstddef>
30#include <cstdint>
31#include <system_error>
32
33namespace llvm {
34
35template <typename T> class ArrayRef;
36
37namespace object {
38
39class Arm64XRelocRef;
40class BaseRelocRef;
41class DelayImportDirectoryEntryRef;
42class DynamicRelocRef;
43class ExportDirectoryEntryRef;
44class ImportDirectoryEntryRef;
45class ImportedSymbolRef;
46class ResourceSectionRef;
47
56
57/// The DOS compatible header at the front of all PE/COFF executables.
58struct dos_header {
59 char Magic[2];
78};
79
88
89 bool isImportLibrary() const { return NumberOfSections == 0xffff; }
90};
91
106};
107
108/// The 32-bit PE header that follows the COFF header.
133 // FIXME: This should be DllCharacteristics.
140 // FIXME: This should be NumberOfRvaAndSizes.
142};
143
144/// The 64-bit PE header that follows the COFF header.
175};
176
180};
181
191};
192
193template <typename IntTy>
195 IntTy Data;
196
197 bool isOrdinal() const { return Data < 0; }
198
200 assert(isOrdinal() && "ILT entry is not an ordinal!");
201 return Data & 0xFFFF;
202 }
203
205 assert(!isOrdinal() && "ILT entry is not a Hint/Name RVA!");
206 return Data & 0xFFFFFFFF;
207 }
208};
209
214
216 // dumpbin reports this field as "Characteristics" instead of "Attributes".
225};
226
239};
240
244};
245
248
252};
253
254template <typename SectionNumberType>
256 union {
260
262 SectionNumberType SectionNumber;
263
265
268};
269
272
273// Contains only common parts of coff_symbol16 and coff_symbol32.
275 union {
280};
281
284
286public:
287 COFFSymbolRef() = default;
288 COFFSymbolRef(const coff_symbol16 *CS) : CS16(CS) {}
289 COFFSymbolRef(const coff_symbol32 *CS) : CS32(CS) {}
290
291 const void *getRawPtr() const {
292 return CS16 ? static_cast<const void *>(CS16) : CS32;
293 }
294
296 if (CS16)
297 return reinterpret_cast<const coff_symbol_generic *>(CS16);
298 return reinterpret_cast<const coff_symbol_generic *>(CS32);
299 }
300
302 return A.getRawPtr() < B.getRawPtr();
303 }
304
305 bool isBigObj() const {
306 if (CS16)
307 return false;
308 if (CS32)
309 return true;
310 llvm_unreachable("COFFSymbolRef points to nothing!");
311 }
312
313 const char *getShortName() const {
314 return CS16 ? CS16->Name.ShortName : CS32->Name.ShortName;
315 }
316
318 assert(isSet() && "COFFSymbolRef points to nothing!");
319 return CS16 ? CS16->Name.Offset : CS32->Name.Offset;
320 }
321
323 assert(isSet() && "COFFSymbolRef points to nothing!");
324 return CS16 ? CS16->Value : CS32->Value;
325 }
326
327 int32_t getSectionNumber() const {
328 assert(isSet() && "COFFSymbolRef points to nothing!");
329 if (CS16) {
330 // Reserved sections are returned as negative numbers.
332 return CS16->SectionNumber;
333 return static_cast<int16_t>(CS16->SectionNumber);
334 }
335 return static_cast<int32_t>(CS32->SectionNumber);
336 }
337
339 assert(isSet() && "COFFSymbolRef points to nothing!");
340 return CS16 ? CS16->Type : CS32->Type;
341 }
342
344 assert(isSet() && "COFFSymbolRef points to nothing!");
345 return CS16 ? CS16->StorageClass : CS32->StorageClass;
346 }
347
349 assert(isSet() && "COFFSymbolRef points to nothing!");
350 return CS16 ? CS16->NumberOfAuxSymbols : CS32->NumberOfAuxSymbols;
351 }
352
353 uint8_t getBaseType() const { return getType() & 0x0F; }
354
356 return (getType() & 0xF0) >> COFF::SCT_COMPLEX_TYPE_SHIFT;
357 }
358
359 template <typename T> const T *getAux() const {
360 return CS16 ? reinterpret_cast<const T *>(CS16 + 1)
361 : reinterpret_cast<const T *>(CS32 + 1);
362 }
363
365 if (!getNumberOfAuxSymbols() ||
367 return nullptr;
368 return getAux<coff_aux_section_definition>();
369 }
370
372 if (!getNumberOfAuxSymbols() ||
374 return nullptr;
375 return getAux<coff_aux_weak_external>();
376 }
377
378 bool isAbsolute() const {
379 return getSectionNumber() == -1;
380 }
381
382 bool isExternal() const {
384 }
385
386 bool isCommon() const {
388 getValue() != 0;
389 }
390
391 bool isUndefined() const {
393 getValue() == 0;
394 }
395
398 }
399
400 bool isWeakExternal() const {
402 }
403
404 bool isFunctionDefinition() const {
408 }
409
410 bool isFunctionLineInfo() const {
412 }
413
414 bool isAnyUndefined() const {
415 return isUndefined() || isWeakExternal();
416 }
417
418 bool isFileRecord() const {
420 }
421
422 bool isSection() const {
424 }
425
426 bool isSectionDefinition() const {
427 // C++/CLI creates external ABS symbols for non-const appdomain globals.
428 // These are also followed by an auxiliary section definition.
429 bool isAppdomainGlobal =
432 bool isOrdinarySection = getStorageClass() == COFF::IMAGE_SYM_CLASS_STATIC;
434 return false;
435 return isAppdomainGlobal || isOrdinarySection;
436 }
437
438 bool isCLRToken() const {
440 }
441
442private:
443 bool isSet() const { return CS16 || CS32; }
444
445 const coff_symbol16 *CS16 = nullptr;
446 const coff_symbol32 *CS32 = nullptr;
447};
448
460
461 // Returns true if the actual number of relocations is stored in
462 // VirtualAddress field of the first relocation table entry.
465 NumberOfRelocations == UINT16_MAX;
466 }
467
469 // The IMAGE_SCN_TYPE_NO_PAD bit is a legacy way of getting to
470 // IMAGE_SCN_ALIGN_1BYTES.
472 return 1;
473
474 // Bit [20:24] contains section alignment. 0 means use a default alignment
475 // of 16.
476 uint32_t Shift = (Characteristics >> 20) & 0xF;
477 if (Shift > 0)
478 return 1U << (Shift - 1);
479 return 16;
480 }
481};
482
487};
488
494 char Unused1[2];
495};
496
497static_assert(sizeof(coff_aux_function_definition) == 18,
498 "auxiliary entry must be 18 bytes");
499
501 char Unused1[4];
503 char Unused2[6];
505 char Unused3[2];
506};
507
508static_assert(sizeof(coff_aux_bf_and_ef_symbol) == 18,
509 "auxiliary entry must be 18 bytes");
510
514 char Unused1[10];
515};
516
517static_assert(sizeof(coff_aux_weak_external) == 18,
518 "auxiliary entry must be 18 bytes");
519
529 int32_t getNumber(bool IsBigObj) const {
530 uint32_t Number = static_cast<uint32_t>(NumberLowPart);
531 if (IsBigObj)
532 Number |= static_cast<uint32_t>(NumberHighPart) << 16;
533 return static_cast<int32_t>(Number);
534 }
535};
536
537static_assert(sizeof(coff_aux_section_definition) == 18,
538 "auxiliary entry must be 18 bytes");
539
544 char MBZ[12];
545};
546
547static_assert(sizeof(coff_aux_clr_token) == 18,
548 "auxiliary entry must be 18 bytes");
549
559
560 int getType() const { return TypeInfo & 0x3; }
561 int getNameType() const { return (TypeInfo >> 2) & 0x7; }
562};
563
570
571 bool isNull() const {
572 return ImportLookupTableRVA == 0 && TimeDateStamp == 0 &&
573 ForwarderChain == 0 && NameRVA == 0 && ImportAddressTableRVA == 0;
574 }
575};
576
577template <typename IntTy>
585
587 // Bit [20:24] contains section alignment.
589 if (Shift > 0)
590 return 1U << (Shift - 1);
591 return 0;
592 }
593
595 uint32_t AlignBits = 0;
596 if (Align) {
597 assert(llvm::isPowerOf2_32(Align) && "alignment is not a power of 2");
598 assert(llvm::Log2_32(Align) <= 13 && "alignment requested is too large");
599 AlignBits = (llvm::Log2_32(Align) + 1) << 20;
600 }
602 (Characteristics & ~COFF::IMAGE_SCN_ALIGN_MASK) | AlignBits;
603 }
604};
605
608
609enum class frame_type : uint16_t { Fpo = 0, Trap = 1, Tss = 2, NonFpo = 3 };
610
616};
617
618/// 32-bit load config (IMAGE_LOAD_CONFIG_DIRECTORY32)
640
641 // Added in MSVC 2015 for /guard:cf.
646 support::ulittle32_t GuardFlags; // coff_guard_flags
647
648 // Added in MSVC 2017
663
664 // Added in MSVC 2019
674};
675
676/// 64-bit load config (IMAGE_LOAD_CONFIG_DIRECTORY64)
698
699 // Added in MSVC 2015 for /guard:cf.
705
706 // Added in MSVC 2017
721
722 // Added in MSVC 2019
732};
733
755
756 // Added in CHPE metadata v2
760};
761
762enum chpe_range_type { Arm64 = 0, Arm64EC = 1, Amd64 = 2 };
763
767
768 // The two low bits of StartOffset contain a range type.
769 static constexpr uint32_t TypeMask = 3;
770
771 uint32_t getStart() const { return StartOffset & ~TypeMask; }
772 uint16_t getType() const { return StartOffset & TypeMask; }
773};
774
779};
780
784};
785
790};
791
795};
796
799
800 int getType() const { return Data >> 12; }
801 int getOffset() const { return Data & ((1 << 12) - 1); }
802};
803
805 union {
808 uint32_t getNameOffset() const {
809 return maskTrailingOnes<uint32_t>(31) & NameOffset;
810 }
811 // Even though the PE/COFF spec doesn't mention this, the high bit of a name
812 // offset is set.
813 void setNameOffset(uint32_t Offset) { NameOffset = Offset | (1 << 31); }
815 union {
818
819 bool isSubDir() const { return SubdirOffset >> 31; }
820 uint32_t value() const {
821 return maskTrailingOnes<uint32_t>(31) & SubdirOffset;
822 }
823
825};
826
832};
833
841};
842
847};
848
852};
853
857};
858
862};
863
870};
871
878};
879
881private:
883
886 const coff_file_header *COFFHeader;
887 const coff_bigobj_file_header *COFFBigObjHeader;
888 const pe32_header *PE32Header;
889 const pe32plus_header *PE32PlusHeader;
890 const data_directory *DataDirectory;
891 const coff_section *SectionTable;
892 const coff_symbol16 *SymbolTable16;
893 const coff_symbol32 *SymbolTable32;
894 const char *StringTable;
895 uint32_t StringTableSize;
896 const coff_import_directory_table_entry *ImportDirectory;
897 const delay_import_directory_table_entry *DelayImportDirectory;
898 uint32_t NumberOfDelayImportDirectory;
899 const export_directory_table_entry *ExportDirectory;
900 const coff_base_reloc_block_header *BaseRelocHeader;
901 const coff_base_reloc_block_header *BaseRelocEnd;
902 const debug_directory *DebugDirectoryBegin;
903 const debug_directory *DebugDirectoryEnd;
904 const coff_tls_directory32 *TLSDirectory32;
905 const coff_tls_directory64 *TLSDirectory64;
906 // Either coff_load_configuration32 or coff_load_configuration64.
907 const void *LoadConfig = nullptr;
908 const chpe_metadata *CHPEMetadata = nullptr;
909 const coff_dynamic_reloc_table *DynamicRelocTable = nullptr;
910
911 Expected<StringRef> getString(uint32_t offset) const;
912
913 template <typename coff_symbol_type>
914 const coff_symbol_type *toSymb(DataRefImpl Symb) const;
915 const coff_section *toSec(DataRefImpl Sec) const;
916 const coff_relocation *toRel(DataRefImpl Rel) const;
917
918 // Finish initializing the object and return success or an error.
920
921 Error initSymbolTablePtr();
922 Error initImportTablePtr();
923 Error initDelayImportTablePtr();
924 Error initExportTablePtr();
925 Error initBaseRelocPtr();
926 Error initDebugDirectoryPtr();
927 Error initTLSDirectoryPtr();
928 Error initLoadConfigPtr();
929 Error initDynamicRelocPtr(uint32_t SectionIndex, uint32_t SectionOffset);
930
931public:
933 create(MemoryBufferRef Object);
934
935 uintptr_t getSymbolTable() const {
936 if (SymbolTable16)
937 return reinterpret_cast<uintptr_t>(SymbolTable16);
938 if (SymbolTable32)
939 return reinterpret_cast<uintptr_t>(SymbolTable32);
940 return uintptr_t(0);
941 }
942
944 return StringRef(StringTable, StringTableSize);
945 }
946
948 if (COFFHeader) {
949 if (CHPEMetadata) {
950 switch (COFFHeader->Machine) {
951 case COFF::IMAGE_FILE_MACHINE_AMD64:
952 return COFF::IMAGE_FILE_MACHINE_ARM64EC;
953 case COFF::IMAGE_FILE_MACHINE_ARM64:
954 return COFF::IMAGE_FILE_MACHINE_ARM64X;
955 }
956 }
957 return COFFHeader->Machine;
958 }
959 if (COFFBigObjHeader)
960 return COFFBigObjHeader->Machine;
961 llvm_unreachable("no COFF header!");
962 }
963
965 if (COFFHeader)
966 return COFFHeader->isImportLibrary() ? 0
967 : COFFHeader->SizeOfOptionalHeader;
968 // bigobj doesn't have this field.
969 if (COFFBigObjHeader)
970 return 0;
971 llvm_unreachable("no COFF header!");
972 }
973
975 if (COFFHeader)
976 return COFFHeader->isImportLibrary() ? 0 : COFFHeader->Characteristics;
977 // bigobj doesn't have characteristics to speak of,
978 // editbin will silently lie to you if you attempt to set any.
979 if (COFFBigObjHeader)
980 return 0;
981 llvm_unreachable("no COFF header!");
982 }
983
985 if (COFFHeader)
986 return COFFHeader->TimeDateStamp;
987 if (COFFBigObjHeader)
988 return COFFBigObjHeader->TimeDateStamp;
989 llvm_unreachable("no COFF header!");
990 }
991
993 if (COFFHeader)
994 return COFFHeader->isImportLibrary() ? 0 : COFFHeader->NumberOfSections;
995 if (COFFBigObjHeader)
996 return COFFBigObjHeader->NumberOfSections;
997 llvm_unreachable("no COFF header!");
998 }
999
1001 if (COFFHeader)
1002 return COFFHeader->isImportLibrary() ? 0
1003 : COFFHeader->PointerToSymbolTable;
1004 if (COFFBigObjHeader)
1005 return COFFBigObjHeader->PointerToSymbolTable;
1006 llvm_unreachable("no COFF header!");
1007 }
1008
1010 if (COFFHeader)
1011 return COFFHeader->isImportLibrary() ? 0 : COFFHeader->NumberOfSymbols;
1012 if (COFFBigObjHeader)
1013 return COFFBigObjHeader->NumberOfSymbols;
1014 llvm_unreachable("no COFF header!");
1015 }
1016
1018 if (!SymbolTable16 && !SymbolTable32)
1019 return 0;
1020 return getRawNumberOfSymbols();
1021 }
1022
1023 uint32_t getStringTableSize() const { return StringTableSize; }
1024
1026 return ExportDirectory;
1027 }
1028
1030 assert(!is64());
1031 return reinterpret_cast<const coff_load_configuration32 *>(LoadConfig);
1032 }
1033
1035 assert(is64());
1036 return reinterpret_cast<const coff_load_configuration64 *>(LoadConfig);
1037 }
1038
1039 const chpe_metadata *getCHPEMetadata() const { return CHPEMetadata; }
1041 return DynamicRelocTable;
1042 }
1043
1044 StringRef getRelocationTypeName(uint16_t Type) const;
1045
1046protected:
1047 void moveSymbolNext(DataRefImpl &Symb) const override;
1048 Expected<StringRef> getSymbolName(DataRefImpl Symb) const override;
1049 Expected<uint64_t> getSymbolAddress(DataRefImpl Symb) const override;
1050 uint32_t getSymbolAlignment(DataRefImpl Symb) const override;
1051 uint64_t getSymbolValueImpl(DataRefImpl Symb) const override;
1052 uint64_t getCommonSymbolSizeImpl(DataRefImpl Symb) const override;
1053 Expected<uint32_t> getSymbolFlags(DataRefImpl Symb) const override;
1055 Expected<section_iterator> getSymbolSection(DataRefImpl Symb) const override;
1056 void moveSectionNext(DataRefImpl &Sec) const override;
1057 Expected<StringRef> getSectionName(DataRefImpl Sec) const override;
1058 uint64_t getSectionAddress(DataRefImpl Sec) const override;
1059 uint64_t getSectionIndex(DataRefImpl Sec) const override;
1060 uint64_t getSectionSize(DataRefImpl Sec) const override;
1062 getSectionContents(DataRefImpl Sec) const override;
1063 uint64_t getSectionAlignment(DataRefImpl Sec) const override;
1064 bool isSectionCompressed(DataRefImpl Sec) const override;
1065 bool isSectionText(DataRefImpl Sec) const override;
1066 bool isSectionData(DataRefImpl Sec) const override;
1067 bool isSectionBSS(DataRefImpl Sec) const override;
1068 bool isSectionVirtual(DataRefImpl Sec) const override;
1069 bool isDebugSection(DataRefImpl Sec) const override;
1070 relocation_iterator section_rel_begin(DataRefImpl Sec) const override;
1071 relocation_iterator section_rel_end(DataRefImpl Sec) const override;
1072
1073 void moveRelocationNext(DataRefImpl &Rel) const override;
1074 uint64_t getRelocationOffset(DataRefImpl Rel) const override;
1075 symbol_iterator getRelocationSymbol(DataRefImpl Rel) const override;
1076 uint64_t getRelocationType(DataRefImpl Rel) const override;
1077 void getRelocationTypeName(DataRefImpl Rel,
1078 SmallVectorImpl<char> &Result) const override;
1079
1080public:
1081 basic_symbol_iterator symbol_begin() const override;
1082 basic_symbol_iterator symbol_end() const override;
1083 section_iterator section_begin() const override;
1084 section_iterator section_end() const override;
1085
1086 bool is64Bit() const override { return false; }
1087
1088 const coff_section *getCOFFSection(const SectionRef &Section) const;
1089 COFFSymbolRef getCOFFSymbol(const DataRefImpl &Ref) const;
1090 COFFSymbolRef getCOFFSymbol(const SymbolRef &Symbol) const;
1091 const coff_relocation *getCOFFRelocation(const RelocationRef &Reloc) const;
1092 unsigned getSectionID(SectionRef Sec) const;
1093 unsigned getSymbolSectionID(SymbolRef Sym) const;
1094
1095 uint8_t getBytesInAddress() const override;
1096 StringRef getFileFormatName() const override;
1097 Triple::ArchType getArch() const override;
1098 Expected<uint64_t> getStartAddress() const override;
1100 return SubtargetFeatures();
1101 }
1102 std::unique_ptr<MemoryBuffer> getHybridObjectView() const;
1103
1104 import_directory_iterator import_directory_begin() const;
1105 import_directory_iterator import_directory_end() const;
1106 delay_import_directory_iterator delay_import_directory_begin() const;
1107 delay_import_directory_iterator delay_import_directory_end() const;
1108 export_directory_iterator export_directory_begin() const;
1109 export_directory_iterator export_directory_end() const;
1110 base_reloc_iterator base_reloc_begin() const;
1111 base_reloc_iterator base_reloc_end() const;
1112 dynamic_reloc_iterator dynamic_reloc_begin() const;
1113 dynamic_reloc_iterator dynamic_reloc_end() const;
1115 return DebugDirectoryBegin;
1116 }
1118 return DebugDirectoryEnd;
1119 }
1120
1121 iterator_range<import_directory_iterator> import_directories() const;
1123 delay_import_directories() const;
1124 iterator_range<export_directory_iterator> export_directories() const;
1125 iterator_range<base_reloc_iterator> base_relocs() const;
1126 iterator_range<dynamic_reloc_iterator> dynamic_relocs() const;
1128 return make_range(debug_directory_begin(), debug_directory_end());
1129 }
1130
1132 return TLSDirectory32;
1133 }
1135 return TLSDirectory64;
1136 }
1137
1138 const dos_header *getDOSHeader() const {
1139 if (!PE32Header && !PE32PlusHeader)
1140 return nullptr;
1141 return reinterpret_cast<const dos_header *>(base());
1142 }
1143
1144 const coff_file_header *getCOFFHeader() const { return COFFHeader; }
1146 return COFFBigObjHeader;
1147 }
1148 const pe32_header *getPE32Header() const { return PE32Header; }
1149 const pe32plus_header *getPE32PlusHeader() const { return PE32PlusHeader; }
1150
1151 const data_directory *getDataDirectory(uint32_t index) const;
1152 Expected<const coff_section *> getSection(int32_t index) const;
1153
1155 if (index >= getNumberOfSymbols())
1156 return errorCodeToError(object_error::parse_failed);
1157 if (SymbolTable16)
1158 return COFFSymbolRef(SymbolTable16 + index);
1159 if (SymbolTable32)
1160 return COFFSymbolRef(SymbolTable32 + index);
1161 return errorCodeToError(object_error::parse_failed);
1162 }
1163
1164 template <typename T>
1165 Error getAuxSymbol(uint32_t index, const T *&Res) const {
1166 Expected<COFFSymbolRef> S = getSymbol(index);
1167 if (Error E = S.takeError())
1168 return E;
1169 Res = reinterpret_cast<const T *>(S->getRawPtr());
1170 return Error::success();
1171 }
1172
1175
1176 ArrayRef<uint8_t> getSymbolAuxData(COFFSymbolRef Symbol) const;
1177
1178 uint32_t getSymbolIndex(COFFSymbolRef Symbol) const;
1179
1181 if (COFFHeader)
1182 return sizeof(coff_symbol16);
1183 if (COFFBigObjHeader)
1184 return sizeof(coff_symbol32);
1185 llvm_unreachable("null symbol table pointer!");
1186 }
1187
1188 ArrayRef<coff_relocation> getRelocations(const coff_section *Sec) const;
1189
1190 Expected<StringRef> getSectionName(const coff_section *Sec) const;
1191 uint64_t getSectionSize(const coff_section *Sec) const;
1192 Error getSectionContents(const coff_section *Sec,
1193 ArrayRef<uint8_t> &Res) const;
1194
1195 uint64_t getImageBase() const;
1196 Error getVaPtr(uint64_t VA, uintptr_t &Res) const;
1197 Error getRvaPtr(uint32_t Rva, uintptr_t &Res,
1198 const char *ErrorContext = nullptr) const;
1199
1200 /// Given an RVA base and size, returns a valid array of bytes or an error
1201 /// code if the RVA and size is not contained completely within a valid
1202 /// section.
1203 Error getRvaAndSizeAsBytes(uint32_t RVA, uint32_t Size,
1204 ArrayRef<uint8_t> &Contents,
1205 const char *ErrorContext = nullptr) const;
1206
1207 Error getHintName(uint32_t Rva, uint16_t &Hint,
1208 StringRef &Name) const;
1209
1210 /// Get PDB information out of a codeview debug directory entry.
1211 Error getDebugPDBInfo(const debug_directory *DebugDir,
1212 const codeview::DebugInfo *&Info,
1213 StringRef &PDBFileName) const;
1214
1215 /// Get PDB information from an executable. If the information is not present,
1216 /// Info will be set to nullptr and PDBFileName will be empty. An error is
1217 /// returned only on corrupt object files. Convenience accessor that can be
1218 /// used if the debug directory is not already handy.
1219 Error getDebugPDBInfo(const codeview::DebugInfo *&Info,
1220 StringRef &PDBFileName) const;
1221
1222 bool isRelocatableObject() const override;
1223 bool is64() const { return PE32PlusHeader; }
1224
1225 StringRef mapDebugSectionName(StringRef Name) const override;
1226
1227 static bool classof(const Binary *v) { return v->isCOFF(); }
1228};
1229
1230// The iterator for the import directory table.
1232public:
1235 uint32_t I, const COFFObjectFile *Owner)
1236 : ImportTable(Table), Index(I), OwningObject(Owner) {}
1237
1238 LLVM_ABI bool operator==(const ImportDirectoryEntryRef &Other) const;
1239 LLVM_ABI void moveNext();
1240
1244
1248 lookup_table_symbols() const;
1249
1250 LLVM_ABI Error getName(StringRef &Result) const;
1253
1256
1257private:
1258 const coff_import_directory_table_entry *ImportTable;
1259 uint32_t Index;
1260 const COFFObjectFile *OwningObject = nullptr;
1261};
1262
1264public:
1267 uint32_t I, const COFFObjectFile *Owner)
1268 : Table(T), Index(I), OwningObject(Owner) {}
1269
1270 LLVM_ABI bool operator==(const DelayImportDirectoryEntryRef &Other) const;
1271 LLVM_ABI void moveNext();
1272
1276
1277 LLVM_ABI Error getName(StringRef &Result) const;
1280 LLVM_ABI Error getImportAddress(int AddrIndex, uint64_t &Result) const;
1281
1282private:
1284 uint32_t Index;
1285 const COFFObjectFile *OwningObject = nullptr;
1286};
1287
1288// The iterator for the export directory table entry.
1290public:
1293 const COFFObjectFile *Owner)
1294 : ExportTable(Table), Index(I), OwningObject(Owner) {}
1295
1296 LLVM_ABI bool operator==(const ExportDirectoryEntryRef &Other) const;
1297 LLVM_ABI void moveNext();
1298
1299 LLVM_ABI Error getDllName(StringRef &Result) const;
1300 LLVM_ABI Error getOrdinalBase(uint32_t &Result) const;
1301 LLVM_ABI Error getOrdinal(uint32_t &Result) const;
1302 LLVM_ABI Error getExportRVA(uint32_t &Result) const;
1303 LLVM_ABI Error getSymbolName(StringRef &Result) const;
1304
1305 LLVM_ABI Error isForwarder(bool &Result) const;
1306 LLVM_ABI Error getForwardTo(StringRef &Result) const;
1307
1308private:
1309 const export_directory_table_entry *ExportTable;
1310 uint32_t Index;
1311 const COFFObjectFile *OwningObject = nullptr;
1312};
1313
1315public:
1318 const COFFObjectFile *Owner)
1319 : Entry32(Entry), Entry64(nullptr), Index(I), OwningObject(Owner) {}
1321 const COFFObjectFile *Owner)
1322 : Entry32(nullptr), Entry64(Entry), Index(I), OwningObject(Owner) {}
1323
1324 LLVM_ABI bool operator==(const ImportedSymbolRef &Other) const;
1325 LLVM_ABI void moveNext();
1326
1327 LLVM_ABI Error getSymbolName(StringRef &Result) const;
1328 LLVM_ABI Error isOrdinal(bool &Result) const;
1329 LLVM_ABI Error getOrdinal(uint16_t &Result) const;
1330 LLVM_ABI Error getHintNameRVA(uint32_t &Result) const;
1331
1332private:
1333 const import_lookup_table_entry32 *Entry32;
1334 const import_lookup_table_entry64 *Entry64;
1335 uint32_t Index;
1336 const COFFObjectFile *OwningObject = nullptr;
1337};
1338
1340public:
1341 BaseRelocRef() = default;
1343 const COFFObjectFile *Owner)
1344 : Header(Header), Index(0) {}
1345
1346 LLVM_ABI bool operator==(const BaseRelocRef &Other) const;
1347 LLVM_ABI void moveNext();
1348
1350 LLVM_ABI Error getRVA(uint32_t &Result) const;
1351
1352private:
1353 const coff_base_reloc_block_header *Header;
1354 uint32_t Index;
1355};
1356
1358public:
1359 DynamicRelocRef() = default;
1360 DynamicRelocRef(const void *Header, const COFFObjectFile *Owner)
1361 : Obj(Owner), Header(reinterpret_cast<const uint8_t *>(Header)) {}
1362
1363 LLVM_ABI bool operator==(const DynamicRelocRef &Other) const;
1364 LLVM_ABI void moveNext();
1365 LLVM_ABI uint32_t getType() const;
1367
1371
1372private:
1373 Error validate() const;
1374
1375 const COFFObjectFile *Obj;
1376 const uint8_t *Header;
1377
1378 friend class COFFObjectFile;
1379};
1380
1382public:
1383 Arm64XRelocRef() = default;
1385 : Header(Header), Index(Index) {}
1386
1387 LLVM_ABI bool operator==(const Arm64XRelocRef &Other) const;
1388 LLVM_ABI void moveNext();
1389
1391 return COFF::Arm64XFixupType((getReloc() >> 12) & 3);
1392 }
1393 uint32_t getRVA() const { return Header->PageRVA + (getReloc() & 0xfff); }
1394 LLVM_ABI uint8_t getSize() const;
1395 LLVM_ABI uint64_t getValue() const;
1396
1397private:
1398 const support::ulittle16_t &getReloc(uint32_t Offset = 0) const {
1399 return reinterpret_cast<const support::ulittle16_t *>(Header +
1400 1)[Index + Offset];
1401 }
1402
1403 uint16_t getArg() const { return getReloc() >> 14; }
1404 uint8_t getEntrySize() const;
1405 Error validate(const COFFObjectFile *Obj) const;
1406
1407 const coff_base_reloc_block_header *Header;
1408 uint32_t Index;
1409
1410 friend class DynamicRelocRef;
1411};
1412
1414public:
1417 : BBS(Ref, llvm::endianness::little) {}
1418
1420 LLVM_ABI Error load(const COFFObjectFile *O, const SectionRef &S);
1421
1431
1434
1435private:
1436 BinaryByteStream BBS;
1437
1438 SectionRef Section;
1439 const COFFObjectFile *Obj = nullptr;
1440
1441 std::vector<const coff_relocation *> Relocs;
1442
1445 getTableEntryAtOffset(uint32_t Offset);
1447 getDataEntryAtOffset(uint32_t Offset);
1448 Expected<ArrayRef<UTF16>> getDirStringAtOffset(uint32_t Offset);
1449};
1450
1451// Corresponds to `_FPO_DATA` structure in the PE/COFF spec.
1452struct FpoData {
1453 support::ulittle32_t Offset; // ulOffStart: Offset 1st byte of function code
1454 support::ulittle32_t Size; // cbProcSize: # bytes in function
1455 support::ulittle32_t NumLocals; // cdwLocals: # bytes in locals/4
1456 support::ulittle16_t NumParams; // cdwParams: # bytes in params/4
1458
1459 // cbProlog: # bytes in prolog
1460 int getPrologSize() const { return Attributes & 0xF; }
1461
1462 // cbRegs: # regs saved
1463 int getNumSavedRegs() const { return (Attributes >> 8) & 0x7; }
1464
1465 // fHasSEH: true if seh is func
1466 bool hasSEH() const { return (Attributes >> 9) & 1; }
1467
1468 // fUseBP: true if EBP has been allocated
1469 bool useBP() const { return (Attributes >> 10) & 1; }
1470
1471 // cbFrame: frame pointer
1472 frame_type getFP() const { return static_cast<frame_type>(Attributes >> 14); }
1473};
1474
1476 : public ErrorInfo<SectionStrippedError, BinaryError> {
1477public:
1479};
1480
1481} // end namespace object
1482
1483} // end namespace llvm
1484
1485#endif // LLVM_OBJECT_COFF_H
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
aarch64 promote const
AMDGPU Mark last scratch load
static GCRegistry::Add< OcamlGC > B("ocaml", "ocaml 3.10-compatible GC")
static GCRegistry::Add< ErlangGC > A("erlang", "erlang-compatible garbage collector")
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
Analysis containing CSE Info
Definition: CSEInfo.cpp:27
static StringRef getSymbolName(SymbolKind SymKind)
#define LLVM_ABI
Definition: Compiler.h:213
Given that RA is a live value
std::string Name
uint32_t Index
uint64_t Size
static bool isDebugSection(const SectionBase &Sec)
Definition: ELFObjcopy.cpp:49
Symbol * Sym
Definition: ELF_riscv.cpp:479
#define I(x, y, z)
Definition: MD5.cpp:58
static unsigned getSymbolSectionID(const ObjectFile &O, SymbolRef Sym)
Definition: SymbolSize.cpp:39
static unsigned getSectionID(const ObjectFile &O, SectionRef Sec)
Definition: SymbolSize.cpp:29
static void initialize(TargetLibraryInfoImpl &TLI, const Triple &T, ArrayRef< StringLiteral > StandardNames)
Initialize the set of available library functions based on the specified target triple.
std::pair< llvm::MachO::Target, std::string > UUID
static std::unique_ptr< PDBSymbol > getSymbolType(const PDBSymbol &Symbol)
Definition: UDTLayout.cpp:35
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Definition: ArrayRef.h:41
An implementation of BinaryStream which holds its entire data set in a single contiguous buffer.
Base class for user error types.
Definition: Error.h:354
Lightweight error class with error context and mandatory checking.
Definition: Error.h:159
Tagged union holding either a T or a Error.
Definition: Error.h:485
Error takeError()
Take ownership of the stored error.
Definition: Error.h:612
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
Definition: SmallVector.h:574
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:55
A table of densely packed, null-terminated strings indexed by offset.
Definition: StringTable.h:33
Manages the enabling and disabling of subtarget specific features.
The instances of the Type class are immutable: once they are created, they are never changed.
Definition: Type.h:45
A range adaptor for a pair of iterators.
uint32_t getRVA() const
Definition: COFF.h:1393
Arm64XRelocRef(const coff_base_reloc_block_header *Header, uint32_t Index=0)
Definition: COFF.h:1384
COFF::Arm64XFixupType getType() const
Definition: COFF.h:1390
LLVM_ABI uint8_t getSize() const
LLVM_ABI uint64_t getValue() const
BaseRelocRef(const coff_base_reloc_block_header *Header, const COFFObjectFile *Owner)
Definition: COFF.h:1342
LLVM_ABI Error getType(uint8_t &Type) const
LLVM_ABI Error getRVA(uint32_t &Result) const
const dos_header * getDOSHeader() const
Definition: COFF.h:1138
static bool classof(const Binary *v)
Definition: COFF.h:1227
uint32_t getRawNumberOfSymbols() const
Definition: COFF.h:1009
const coff_tls_directory64 * getTLSDirectory64() const
Definition: COFF.h:1134
const pe32_header * getPE32Header() const
Definition: COFF.h:1148
Expected< COFFSymbolRef > getSymbol(uint32_t index) const
Definition: COFF.h:1154
const debug_directory * debug_directory_end() const
Definition: COFF.h:1117
const coff_tls_directory32 * getTLSDirectory32() const
Definition: COFF.h:1131
Expected< SubtargetFeatures > getFeatures() const override
Definition: COFF.h:1099
uint32_t getPointerToSymbolTable() const
Definition: COFF.h:1000
iterator_range< const debug_directory * > debug_directories() const
Definition: COFF.h:1127
const coff_dynamic_reloc_table * getDynamicRelocTable() const
Definition: COFF.h:1040
uint32_t getNumberOfSymbols() const
Definition: COFF.h:1017
const coff_file_header * getCOFFHeader() const
Definition: COFF.h:1144
size_t getSymbolTableEntrySize() const
Definition: COFF.h:1180
Error getAuxSymbol(uint32_t index, const T *&Res) const
Definition: COFF.h:1165
uintptr_t getSymbolTable() const
Definition: COFF.h:935
const coff_bigobj_file_header * getCOFFBigObjHeader() const
Definition: COFF.h:1145
const coff_load_configuration64 * getLoadConfig64() const
Definition: COFF.h:1034
uint32_t getNumberOfSections() const
Definition: COFF.h:992
uint32_t getTimeDateStamp() const
Definition: COFF.h:984
uint32_t getStringTableSize() const
Definition: COFF.h:1023
const chpe_metadata * getCHPEMetadata() const
Definition: COFF.h:1039
const debug_directory * debug_directory_begin() const
Definition: COFF.h:1114
const coff_load_configuration32 * getLoadConfig32() const
Definition: COFF.h:1029
StringRef getStringTable() const
Definition: COFF.h:943
uint16_t getSizeOfOptionalHeader() const
Definition: COFF.h:964
uint16_t getCharacteristics() const
Definition: COFF.h:974
const pe32plus_header * getPE32PlusHeader() const
Definition: COFF.h:1149
uint16_t getMachine() const
Definition: COFF.h:947
const export_directory_table_entry * getExportTable() const
Definition: COFF.h:1025
bool is64Bit() const override
Definition: COFF.h:1086
const void * getRawPtr() const
Definition: COFF.h:291
bool isCommon() const
Definition: COFF.h:386
const StringTableOffset & getStringTableOffset() const
Definition: COFF.h:317
uint8_t getStorageClass() const
Definition: COFF.h:343
uint16_t getType() const
Definition: COFF.h:338
const T * getAux() const
Definition: COFF.h:359
bool isAnyUndefined() const
Definition: COFF.h:414
bool isFileRecord() const
Definition: COFF.h:418
const coff_symbol_generic * getGeneric() const
Definition: COFF.h:295
const coff_aux_weak_external * getWeakExternal() const
Definition: COFF.h:371
bool isAbsolute() const
Definition: COFF.h:378
bool isSectionDefinition() const
Definition: COFF.h:426
uint8_t getComplexType() const
Definition: COFF.h:355
uint8_t getNumberOfAuxSymbols() const
Definition: COFF.h:348
bool isExternal() const
Definition: COFF.h:382
bool isFunctionLineInfo() const
Definition: COFF.h:410
uint8_t getBaseType() const
Definition: COFF.h:353
COFFSymbolRef(const coff_symbol32 *CS)
Definition: COFF.h:289
COFFSymbolRef(const coff_symbol16 *CS)
Definition: COFF.h:288
uint32_t getValue() const
Definition: COFF.h:322
const coff_aux_section_definition * getSectionDefinition() const
Definition: COFF.h:364
bool isWeakExternal() const
Definition: COFF.h:400
bool isEmptySectionDeclaration() const
Definition: COFF.h:396
friend bool operator<(COFFSymbolRef A, COFFSymbolRef B)
Definition: COFF.h:301
const char * getShortName() const
Definition: COFF.h:313
bool isSection() const
Definition: COFF.h:422
int32_t getSectionNumber() const
Definition: COFF.h:327
bool isCLRToken() const
Definition: COFF.h:438
bool isBigObj() const
Definition: COFF.h:305
bool isUndefined() const
Definition: COFF.h:391
bool isFunctionDefinition() const
Definition: COFF.h:404
LLVM_ABI imported_symbol_iterator imported_symbol_begin() const
LLVM_ABI Error getImportAddress(int AddrIndex, uint64_t &Result) const
LLVM_ABI iterator_range< imported_symbol_iterator > imported_symbols() const
LLVM_ABI imported_symbol_iterator imported_symbol_end() const
LLVM_ABI Error getDelayImportTable(const delay_import_directory_table_entry *&Result) const
DelayImportDirectoryEntryRef(const delay_import_directory_table_entry *T, uint32_t I, const COFFObjectFile *Owner)
Definition: COFF.h:1266
LLVM_ABI Error getName(StringRef &Result) const
LLVM_ABI arm64x_reloc_iterator arm64x_reloc_begin() const
LLVM_ABI void getContents(ArrayRef< uint8_t > &Ref) const
LLVM_ABI uint32_t getType() const
LLVM_ABI arm64x_reloc_iterator arm64x_reloc_end() const
LLVM_ABI iterator_range< arm64x_reloc_iterator > arm64x_relocs() const
DynamicRelocRef(const void *Header, const COFFObjectFile *Owner)
Definition: COFF.h:1360
LLVM_ABI Error getDllName(StringRef &Result) const
ExportDirectoryEntryRef(const export_directory_table_entry *Table, uint32_t I, const COFFObjectFile *Owner)
Definition: COFF.h:1292
LLVM_ABI Error getExportRVA(uint32_t &Result) const
LLVM_ABI Error getOrdinalBase(uint32_t &Result) const
LLVM_ABI Error getOrdinal(uint32_t &Result) const
LLVM_ABI Error isForwarder(bool &Result) const
LLVM_ABI Error getForwardTo(StringRef &Result) const
LLVM_ABI Error getSymbolName(StringRef &Result) const
LLVM_ABI imported_symbol_iterator imported_symbol_end() const
LLVM_ABI imported_symbol_iterator imported_symbol_begin() const
LLVM_ABI Error getImportLookupTableRVA(uint32_t &Result) const
LLVM_ABI Error getImportTableEntry(const coff_import_directory_table_entry *&Result) const
LLVM_ABI imported_symbol_iterator lookup_table_end() const
ImportDirectoryEntryRef(const coff_import_directory_table_entry *Table, uint32_t I, const COFFObjectFile *Owner)
Definition: COFF.h:1234
LLVM_ABI iterator_range< imported_symbol_iterator > lookup_table_symbols() const
LLVM_ABI iterator_range< imported_symbol_iterator > imported_symbols() const
LLVM_ABI imported_symbol_iterator lookup_table_begin() const
LLVM_ABI Error getImportAddressTableRVA(uint32_t &Result) const
LLVM_ABI Error getName(StringRef &Result) const
LLVM_ABI Error getHintNameRVA(uint32_t &Result) const
ImportedSymbolRef(const import_lookup_table_entry32 *Entry, uint32_t I, const COFFObjectFile *Owner)
Definition: COFF.h:1317
LLVM_ABI Error getOrdinal(uint16_t &Result) const
LLVM_ABI Error getSymbolName(StringRef &Result) const
ImportedSymbolRef(const import_lookup_table_entry64 *Entry, uint32_t I, const COFFObjectFile *Owner)
Definition: COFF.h:1320
LLVM_ABI Error isOrdinal(bool &Result) const
This class is the base class for all object file types.
Definition: ObjectFile.h:231
This is a value type class that represents a single relocation in the list of relocations in the obje...
Definition: ObjectFile.h:54
LLVM_ABI Expected< const coff_resource_dir_table & > getBaseTable()
LLVM_ABI Expected< const coff_resource_dir_table & > getEntrySubDir(const coff_resource_dir_entry &Entry)
LLVM_ABI Expected< const coff_resource_data_entry & > getEntryData(const coff_resource_dir_entry &Entry)
ResourceSectionRef(StringRef Ref)
Definition: COFF.h:1416
LLVM_ABI Expected< ArrayRef< UTF16 > > getEntryNameString(const coff_resource_dir_entry &Entry)
LLVM_ABI Expected< StringRef > getContents(const coff_resource_data_entry &Entry)
LLVM_ABI Expected< const coff_resource_dir_entry & > getTableEntry(const coff_resource_dir_table &Table, uint32_t Index)
This is a value type class that represents a single section in the list of sections in the object fil...
Definition: ObjectFile.h:83
This is a value type class that represents a single symbol in the list of symbols in the object file.
Definition: ObjectFile.h:170
This provides a very simple, boring adaptor for a begin and end iterator into a range type.
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
@ IMAGE_SCN_ALIGN_MASK
Definition: COFF.h:329
@ IMAGE_SCN_LNK_NRELOC_OVFL
Definition: COFF.h:330
@ IMAGE_SCN_TYPE_NO_PAD
Definition: COFF.h:302
@ NameSize
Definition: COFF.h:58
@ IMAGE_SYM_CLASS_SECTION
Line number, reformatted as symbol.
Definition: COFF.h:248
@ IMAGE_SYM_CLASS_FUNCTION
".bf" or ".ef" - beginning or end of function
Definition: COFF.h:244
@ IMAGE_SYM_CLASS_EXTERNAL
External symbol.
Definition: COFF.h:224
@ IMAGE_SYM_CLASS_FILE
File name.
Definition: COFF.h:246
@ IMAGE_SYM_CLASS_CLR_TOKEN
External symbol in dmert public lib.
Definition: COFF.h:251
@ IMAGE_SYM_CLASS_WEAK_EXTERNAL
Duplicate tag.
Definition: COFF.h:249
@ IMAGE_SYM_CLASS_STATIC
Static.
Definition: COFF.h:225
Arm64XFixupType
Definition: COFF.h:448
const int32_t MaxNumberOfSections16
Definition: COFF.h:33
bool isReservedSectionNumber(int32_t SectionNumber)
Definition: COFF.h:866
@ IMAGE_SYM_TYPE_NULL
No type information or unknown base type.
Definition: COFF.h:255
@ IMAGE_SYM_UNDEFINED
Definition: COFF.h:214
@ IMAGE_SYM_ABSOLUTE
Definition: COFF.h:213
@ IMAGE_SYM_DTYPE_FUNCTION
A function that returns a base type.
Definition: COFF.h:276
@ SCT_COMPLEX_TYPE_SHIFT
Type is formed as (base + (derived << SCT_COMPLEX_TYPE_SHIFT))
Definition: COFF.h:280
Expected< const typename ELFT::Shdr * > getSection(typename ELFT::ShdrRange Sections, uint32_t Index)
Definition: ELF.h:539
coff_symbol< support::ulittle32_t > coff_symbol32
Definition: COFF.h:271
coff_symbol< support::ulittle16_t > coff_symbol16
Definition: COFF.h:270
chpe_range_type
Definition: COFF.h:762
@ Arm64EC
Definition: COFF.h:762
detail::packed_endian_specific_integral< uint16_t, llvm::endianness::little, unaligned > ulittle16_t
Definition: Endian.h:286
detail::packed_endian_specific_integral< uint32_t, llvm::endianness::little, unaligned > ulittle32_t
Definition: Endian.h:289
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
@ Offset
Definition: DWP.cpp:477
iterator_range< T > make_range(T x, T y)
Convenience function for iterating over sub-ranges.
unsigned Log2_32(uint32_t Value)
Return the floor log base 2 of the specified value, -1 if the value is zero.
Definition: MathExtras.h:336
constexpr bool isPowerOf2_32(uint32_t Value)
Return true if the argument is a power of two > 0.
Definition: MathExtras.h:288
@ Ref
The access may reference the value stored in memory.
@ Other
Any other memory.
ArrayRef(const T &OneElt) -> ArrayRef< T >
LLVM_ABI Error errorCodeToError(std::error_code EC)
Helper for converting an std::error_code to a Error.
Definition: Error.cpp:111
endianness
Definition: bit.h:71
This struct is a compact representation of a valid (non-zero power of two) alignment.
Definition: Alignment.h:39
support::ulittle32_t NumLocals
Definition: COFF.h:1455
bool hasSEH() const
Definition: COFF.h:1466
bool useBP() const
Definition: COFF.h:1469
int getNumSavedRegs() const
Definition: COFF.h:1463
support::ulittle32_t Size
Definition: COFF.h:1454
int getPrologSize() const
Definition: COFF.h:1460
frame_type getFP() const
Definition: COFF.h:1472
support::ulittle16_t NumParams
Definition: COFF.h:1456
support::ulittle16_t Attributes
Definition: COFF.h:1457
support::ulittle32_t Offset
Definition: COFF.h:1453
support::ulittle32_t Offset
Definition: COFF.h:251
support::ulittle32_t Zeroes
Definition: COFF.h:250
Definition: COFF.h:775
support::ulittle32_t EntryPoint
Definition: COFF.h:778
support::ulittle32_t StartRva
Definition: COFF.h:776
support::ulittle32_t EndRva
Definition: COFF.h:777
support::ulittle32_t AuxiliaryDelayloadIAT
Definition: COFF.h:757
support::ulittle32_t HybridImageInfoBitfield
Definition: COFF.h:759
support::ulittle32_t AlternateEntryPoint
Definition: COFF.h:745
support::ulittle32_t SetX64InformationFunctionPointer
Definition: COFF.h:750
support::ulittle32_t ExtraRFETableSize
Definition: COFF.h:752
support::ulittle32_t __os_arm64x_dispatch_ret
Definition: COFF.h:741
support::ulittle32_t __os_arm64x_dispatch_call_no_redirect
Definition: COFF.h:740
support::ulittle32_t RedirectionMetadataCount
Definition: COFF.h:748
support::ulittle32_t __os_arm64x_dispatch_icall_cfg
Definition: COFF.h:744
support::ulittle32_t CodeMap
Definition: COFF.h:736
support::ulittle32_t AuxiliaryIATCopy
Definition: COFF.h:754
support::ulittle32_t AuxiliaryDelayloadIATCopy
Definition: COFF.h:758
support::ulittle32_t __os_arm64x_dispatch_icall
Definition: COFF.h:743
support::ulittle32_t CodeRangesToEntryPointsCount
Definition: COFF.h:747
support::ulittle32_t AuxiliaryIAT
Definition: COFF.h:746
support::ulittle32_t GetX64InformationFunctionPointer
Definition: COFF.h:749
support::ulittle32_t ExtraRFETable
Definition: COFF.h:751
support::ulittle32_t Version
Definition: COFF.h:735
support::ulittle32_t CodeMapCount
Definition: COFF.h:737
support::ulittle32_t __os_arm64x_dispatch_fptr
Definition: COFF.h:753
support::ulittle32_t RedirectionMetadata
Definition: COFF.h:739
support::ulittle32_t CodeRangesToEntryPoints
Definition: COFF.h:738
support::ulittle32_t __os_arm64x_dispatch_call
Definition: COFF.h:742
Definition: COFF.h:764
support::ulittle32_t Length
Definition: COFF.h:766
static constexpr uint32_t TypeMask
Definition: COFF.h:769
support::ulittle32_t StartOffset
Definition: COFF.h:765
uint32_t getStart() const
Definition: COFF.h:771
uint16_t getType() const
Definition: COFF.h:772
Definition: COFF.h:781
support::ulittle32_t Source
Definition: COFF.h:782
support::ulittle32_t Destination
Definition: COFF.h:783
support::ulittle32_t PointerToNextFunction
Definition: COFF.h:504
support::ulittle16_t Linenumber
Definition: COFF.h:502
support::ulittle32_t SymbolTableIndex
Definition: COFF.h:543
support::ulittle32_t PointerToLinenumber
Definition: COFF.h:492
support::ulittle32_t TotalSize
Definition: COFF.h:491
support::ulittle32_t PointerToNextFunction
Definition: COFF.h:493
support::ulittle16_t NumberOfLinenumbers
Definition: COFF.h:523
support::ulittle32_t CheckSum
Definition: COFF.h:524
int32_t getNumber(bool IsBigObj) const
Definition: COFF.h:529
support::ulittle16_t NumberHighPart
Definition: COFF.h:528
support::ulittle16_t NumberLowPart
Definition: COFF.h:525
support::ulittle16_t NumberOfRelocations
Definition: COFF.h:522
support::ulittle32_t Characteristics
Definition: COFF.h:513
support::ulittle32_t TagIndex
Definition: COFF.h:512
Definition: COFF.h:797
support::ulittle16_t Data
Definition: COFF.h:798
int getOffset() const
Definition: COFF.h:801
int getType() const
Definition: COFF.h:800
support::ulittle32_t BlockSize
Definition: COFF.h:794
support::ulittle32_t unused2
Definition: COFF.h:100
support::ulittle16_t Version
Definition: COFF.h:95
support::ulittle32_t PointerToSymbolTable
Definition: COFF.h:104
support::ulittle32_t unused1
Definition: COFF.h:99
support::ulittle16_t Sig1
Definition: COFF.h:93
support::ulittle32_t NumberOfSections
Definition: COFF.h:103
support::ulittle16_t Machine
Definition: COFF.h:96
support::ulittle32_t unused4
Definition: COFF.h:102
support::ulittle32_t unused3
Definition: COFF.h:101
support::ulittle32_t TimeDateStamp
Definition: COFF.h:97
support::ulittle16_t Sig2
Definition: COFF.h:94
support::ulittle32_t NumberOfSymbols
Definition: COFF.h:105
support::ulittle32_t Version
Definition: COFF.h:850
support::ulittle32_t Size
Definition: COFF.h:851
support::ulittle32_t HeaderSize
Definition: COFF.h:865
support::ulittle32_t FixupInfoSize
Definition: COFF.h:866
support::ulittle32_t SymbolGroup
Definition: COFF.h:868
support::ulittle32_t BaseRelocSize
Definition: COFF.h:856
support::ulittle32_t Symbol
Definition: COFF.h:855
support::ulittle32_t HeaderSize
Definition: COFF.h:873
support::ulittle32_t SymbolGroup
Definition: COFF.h:876
support::ulittle32_t FixupInfoSize
Definition: COFF.h:874
support::ulittle32_t BaseRelocSize
Definition: COFF.h:861
support::ulittle64_t Symbol
Definition: COFF.h:860
support::ulittle16_t Machine
Definition: COFF.h:81
support::ulittle32_t NumberOfSymbols
Definition: COFF.h:85
support::ulittle16_t Characteristics
Definition: COFF.h:87
support::ulittle32_t PointerToSymbolTable
Definition: COFF.h:84
support::ulittle16_t NumberOfSections
Definition: COFF.h:82
bool isImportLibrary() const
Definition: COFF.h:89
support::ulittle16_t SizeOfOptionalHeader
Definition: COFF.h:86
support::ulittle32_t TimeDateStamp
Definition: COFF.h:83
Definition: COFF.h:564
support::ulittle32_t TimeDateStamp
Definition: COFF.h:566
support::ulittle32_t ImportAddressTableRVA
Definition: COFF.h:569
support::ulittle32_t ForwarderChain
Definition: COFF.h:567
bool isNull() const
Definition: COFF.h:571
support::ulittle32_t NameRVA
Definition: COFF.h:568
support::ulittle32_t ImportLookupTableRVA
Definition: COFF.h:565
support::ulittle16_t TypeInfo
Definition: COFF.h:558
support::ulittle16_t Machine
Definition: COFF.h:554
support::ulittle32_t SizeOfData
Definition: COFF.h:556
support::ulittle16_t Sig2
Definition: COFF.h:552
support::ulittle16_t OrdinalHint
Definition: COFF.h:557
support::ulittle32_t TimeDateStamp
Definition: COFF.h:555
support::ulittle16_t Version
Definition: COFF.h:553
support::ulittle16_t Sig1
Definition: COFF.h:551
32-bit load config (IMAGE_LOAD_CONFIG_DIRECTORY32)
Definition: COFF.h:619
support::ulittle16_t MinorVersion
Definition: COFF.h:623
support::ulittle32_t SEHandlerCount
Definition: COFF.h:639
support::ulittle32_t GuardAddressTakenIatEntryCount
Definition: COFF.h:651
support::ulittle32_t GuardRFFailureRoutineFunctionPointer
Definition: COFF.h:657
support::ulittle32_t DynamicValueRelocTable
Definition: COFF.h:654
support::ulittle32_t GuardCFCheckFunction
Definition: COFF.h:642
support::ulittle32_t GuardRFVerifyStackPointerFunctionPointer
Definition: COFF.h:661
support::ulittle32_t GuardEHContinuationTable
Definition: COFF.h:668
support::ulittle32_t Size
Definition: COFF.h:620
support::ulittle32_t SEHandlerTable
Definition: COFF.h:638
support::ulittle32_t LockPrefixTable
Definition: COFF.h:629
support::ulittle16_t CSDVersion
Definition: COFF.h:634
support::ulittle16_t Reserved2
Definition: COFF.h:660
support::ulittle32_t CHPEMetadataPointer
Definition: COFF.h:655
support::ulittle32_t VirtualMemoryThreshold
Definition: COFF.h:631
support::ulittle32_t GuardCFFunctionCount
Definition: COFF.h:645
support::ulittle32_t DeCommitFreeBlockThreshold
Definition: COFF.h:627
support::ulittle32_t ProcessAffinityMask
Definition: COFF.h:632
support::ulittle32_t MaximumAllocationSize
Definition: COFF.h:630
support::ulittle32_t EnclaveConfigurationPointer
Definition: COFF.h:666
support::ulittle16_t DependentLoadFlags
Definition: COFF.h:635
support::ulittle32_t TimeDateStamp
Definition: COFF.h:621
support::ulittle32_t GuardXFGCheckFunctionPointer
Definition: COFF.h:670
support::ulittle32_t GuardCFCheckDispatch
Definition: COFF.h:643
support::ulittle32_t GuardLongJumpTargetCount
Definition: COFF.h:653
support::ulittle32_t GuardLongJumpTargetTable
Definition: COFF.h:652
support::ulittle32_t Reserved3
Definition: COFF.h:665
support::ulittle32_t GuardAddressTakenIatEntryTable
Definition: COFF.h:650
support::ulittle32_t CriticalSectionDefaultTimeout
Definition: COFF.h:626
support::ulittle32_t GuardEHContinuationCount
Definition: COFF.h:669
support::ulittle16_t DynamicValueRelocTableSection
Definition: COFF.h:659
support::ulittle32_t GuardXFGTableDispatchFunctionPointer
Definition: COFF.h:672
support::ulittle32_t GuardCFFunctionTable
Definition: COFF.h:644
support::ulittle32_t GuardFlags
Definition: COFF.h:646
support::ulittle32_t SecurityCookie
Definition: COFF.h:637
support::ulittle32_t HotPatchTableOffset
Definition: COFF.h:662
coff_load_config_code_integrity CodeIntegrity
Definition: COFF.h:649
support::ulittle16_t MajorVersion
Definition: COFF.h:622
support::ulittle32_t ProcessHeapFlags
Definition: COFF.h:633
support::ulittle32_t GuardXFGDispatchFunctionPointer
Definition: COFF.h:671
support::ulittle32_t GuardRFFailureRoutine
Definition: COFF.h:656
support::ulittle32_t DynamicValueRelocTableOffset
Definition: COFF.h:658
support::ulittle32_t DeCommitTotalFreeThreshold
Definition: COFF.h:628
support::ulittle32_t GlobalFlagsSet
Definition: COFF.h:625
support::ulittle32_t EditList
Definition: COFF.h:636
support::ulittle32_t GlobalFlagsClear
Definition: COFF.h:624
support::ulittle32_t CastGuardOsDeterminedFailureMode
Definition: COFF.h:673
support::ulittle32_t VolatileMetadataPointer
Definition: COFF.h:667
64-bit load config (IMAGE_LOAD_CONFIG_DIRECTORY64)
Definition: COFF.h:677
support::ulittle64_t VirtualMemoryThreshold
Definition: COFF.h:689
support::ulittle32_t TimeDateStamp
Definition: COFF.h:679
support::ulittle64_t GuardCFFunctionCount
Definition: COFF.h:703
support::ulittle32_t GuardFlags
Definition: COFF.h:704
support::ulittle64_t VolatileMetadataPointer
Definition: COFF.h:725
support::ulittle16_t MinorVersion
Definition: COFF.h:681
support::ulittle16_t MajorVersion
Definition: COFF.h:680
support::ulittle64_t GuardRFFailureRoutineFunctionPointer
Definition: COFF.h:715
support::ulittle32_t DynamicValueRelocTableOffset
Definition: COFF.h:716
support::ulittle16_t DependentLoadFlags
Definition: COFF.h:693
support::ulittle16_t Reserved2
Definition: COFF.h:718
support::ulittle32_t GlobalFlagsSet
Definition: COFF.h:683
support::ulittle64_t GuardAddressTakenIatEntryTable
Definition: COFF.h:708
support::ulittle64_t EditList
Definition: COFF.h:694
support::ulittle64_t DeCommitFreeBlockThreshold
Definition: COFF.h:685
support::ulittle64_t GuardXFGCheckFunctionPointer
Definition: COFF.h:728
coff_load_config_code_integrity CodeIntegrity
Definition: COFF.h:707
support::ulittle64_t DynamicValueRelocTable
Definition: COFF.h:712
support::ulittle64_t ProcessAffinityMask
Definition: COFF.h:690
support::ulittle64_t DeCommitTotalFreeThreshold
Definition: COFF.h:686
support::ulittle64_t GuardAddressTakenIatEntryCount
Definition: COFF.h:709
support::ulittle64_t GuardEHContinuationCount
Definition: COFF.h:727
support::ulittle64_t GuardRFFailureRoutine
Definition: COFF.h:714
support::ulittle32_t CriticalSectionDefaultTimeout
Definition: COFF.h:684
support::ulittle64_t GuardCFFunctionTable
Definition: COFF.h:702
support::ulittle64_t GuardLongJumpTargetTable
Definition: COFF.h:710
support::ulittle64_t SEHandlerTable
Definition: COFF.h:696
support::ulittle64_t MaximumAllocationSize
Definition: COFF.h:688
support::ulittle64_t SEHandlerCount
Definition: COFF.h:697
support::ulittle64_t GuardCFCheckFunction
Definition: COFF.h:700
support::ulittle32_t Reserved3
Definition: COFF.h:723
support::ulittle32_t HotPatchTableOffset
Definition: COFF.h:720
support::ulittle64_t GuardCFCheckDispatch
Definition: COFF.h:701
support::ulittle64_t GuardXFGTableDispatchFunctionPointer
Definition: COFF.h:730
support::ulittle64_t SecurityCookie
Definition: COFF.h:695
support::ulittle64_t GuardEHContinuationTable
Definition: COFF.h:726
support::ulittle64_t LockPrefixTable
Definition: COFF.h:687
support::ulittle16_t CSDVersion
Definition: COFF.h:692
support::ulittle64_t CastGuardOsDeterminedFailureMode
Definition: COFF.h:731
support::ulittle32_t GlobalFlagsClear
Definition: COFF.h:682
support::ulittle32_t ProcessHeapFlags
Definition: COFF.h:691
support::ulittle16_t DynamicValueRelocTableSection
Definition: COFF.h:717
support::ulittle64_t CHPEMetadataPointer
Definition: COFF.h:713
support::ulittle64_t GuardXFGDispatchFunctionPointer
Definition: COFF.h:729
support::ulittle64_t GuardRFVerifyStackPointerFunctionPointer
Definition: COFF.h:719
support::ulittle64_t GuardLongJumpTargetCount
Definition: COFF.h:711
support::ulittle64_t EnclaveConfigurationPointer
Definition: COFF.h:724
support::ulittle32_t Size
Definition: COFF.h:678
support::ulittle16_t Type
Definition: COFF.h:486
support::ulittle32_t SymbolTableIndex
Definition: COFF.h:485
support::ulittle32_t VirtualAddress
Definition: COFF.h:484
Definition: COFF.h:827
support::ulittle32_t Reserved
Definition: COFF.h:831
support::ulittle32_t DataSize
Definition: COFF.h:829
support::ulittle32_t Codepage
Definition: COFF.h:830
support::ulittle32_t DataRVA
Definition: COFF.h:828
Definition: COFF.h:804
support::ulittle32_t NameOffset
Definition: COFF.h:806
union llvm::object::coff_resource_dir_entry::@371 Identifier
support::ulittle32_t DataEntryOffset
Definition: COFF.h:816
support::ulittle32_t ID
Definition: COFF.h:807
union llvm::object::coff_resource_dir_entry::@372 Offset
support::ulittle32_t SubdirOffset
Definition: COFF.h:817
support::ulittle16_t NumberOfNameEntries
Definition: COFF.h:839
support::ulittle32_t Characteristics
Definition: COFF.h:835
support::ulittle16_t NumberOfIDEntries
Definition: COFF.h:840
support::ulittle32_t TimeDateStamp
Definition: COFF.h:836
support::ulittle16_t MinorVersion
Definition: COFF.h:838
support::ulittle16_t MajorVersion
Definition: COFF.h:837
support::ulittle32_t BeginAddress
Definition: COFF.h:787
support::ulittle32_t UnwindInformation
Definition: COFF.h:789
support::ulittle32_t EndAddress
Definition: COFF.h:788
support::ulittle32_t PointerToRawData
Definition: COFF.h:454
char Name[COFF::NameSize]
Definition: COFF.h:450
support::ulittle32_t VirtualSize
Definition: COFF.h:451
bool hasExtendedRelocations() const
Definition: COFF.h:463
uint32_t getAlignment() const
Definition: COFF.h:468
support::ulittle32_t Characteristics
Definition: COFF.h:459
support::ulittle16_t NumberOfLinenumbers
Definition: COFF.h:458
support::ulittle32_t SizeOfRawData
Definition: COFF.h:453
support::ulittle32_t VirtualAddress
Definition: COFF.h:452
support::ulittle32_t PointerToRelocations
Definition: COFF.h:455
support::ulittle16_t NumberOfRelocations
Definition: COFF.h:457
support::ulittle32_t PointerToLinenumbers
Definition: COFF.h:456
union llvm::object::coff_symbol_generic::@370 Name
support::ulittle32_t Value
Definition: COFF.h:279
StringTableOffset Offset
Definition: COFF.h:277
char ShortName[COFF::NameSize]
Definition: COFF.h:276
union llvm::object::coff_symbol::@369 Name
StringTableOffset Offset
Definition: COFF.h:258
SectionNumberType SectionNumber
Definition: COFF.h:262
support::ulittle32_t Value
Definition: COFF.h:261
char ShortName[COFF::NameSize]
Definition: COFF.h:257
support::ulittle16_t Type
Definition: COFF.h:264
uint8_t NumberOfAuxSymbols
Definition: COFF.h:267
support::ulittle32_t SizeOfZeroFill
Definition: COFF.h:583
uint32_t getAlignment() const
Definition: COFF.h:586
support::ulittle32_t Characteristics
Definition: COFF.h:584
void setAlignment(uint32_t Align)
Definition: COFF.h:594
support::ulittle32_t RelativeVirtualAddress
Definition: COFF.h:178
support::ulittle32_t Size
Definition: COFF.h:179
support::ulittle16_t MajorVersion
Definition: COFF.h:185
support::ulittle32_t SizeOfData
Definition: COFF.h:188
support::ulittle32_t PointerToRawData
Definition: COFF.h:190
support::ulittle32_t AddressOfRawData
Definition: COFF.h:189
support::ulittle32_t TimeDateStamp
Definition: COFF.h:184
support::ulittle32_t Type
Definition: COFF.h:187
support::ulittle32_t Characteristics
Definition: COFF.h:183
support::ulittle16_t MinorVersion
Definition: COFF.h:186
support::ulittle16_t HashAlgorithm
Definition: COFF.h:846
support::ulittle16_t Version
Definition: COFF.h:845
support::ulittle32_t Magic
Definition: COFF.h:844
Definition: COFF.h:215
support::ulittle32_t DelayImportNameTable
Definition: COFF.h:221
support::ulittle32_t DelayImportAddressTable
Definition: COFF.h:220
support::ulittle32_t Name
Definition: COFF.h:218
support::ulittle32_t UnloadDelayImportTable
Definition: COFF.h:223
support::ulittle32_t BoundDelayImportTable
Definition: COFF.h:222
support::ulittle32_t TimeStamp
Definition: COFF.h:224
support::ulittle32_t Attributes
Definition: COFF.h:217
support::ulittle32_t ModuleHandle
Definition: COFF.h:219
The DOS compatible header at the front of all PE/COFF executables.
Definition: COFF.h:58
support::ulittle16_t AddressOfRelocationTable
Definition: COFF.h:71
support::ulittle16_t NumberOfRelocationItems
Definition: COFF.h:62
support::ulittle16_t InitialSP
Definition: COFF.h:67
support::ulittle16_t HeaderSizeInParagraphs
Definition: COFF.h:63
support::ulittle16_t InitialIP
Definition: COFF.h:69
support::ulittle32_t AddressOfNewExeHeader
Definition: COFF.h:77
support::ulittle16_t MaximumExtraParagraphs
Definition: COFF.h:65
support::ulittle16_t InitialRelativeSS
Definition: COFF.h:66
support::ulittle16_t OEMid
Definition: COFF.h:74
support::ulittle16_t OverlayNumber
Definition: COFF.h:72
support::ulittle16_t UsedBytesInTheLastPage
Definition: COFF.h:60
support::ulittle16_t Reserved[4]
Definition: COFF.h:73
support::ulittle16_t Checksum
Definition: COFF.h:68
support::ulittle16_t FileSizeInPages
Definition: COFF.h:61
support::ulittle16_t OEMinfo
Definition: COFF.h:75
support::ulittle16_t InitialRelativeCS
Definition: COFF.h:70
support::ulittle16_t Reserved2[10]
Definition: COFF.h:76
support::ulittle16_t MinimumExtraParagraphs
Definition: COFF.h:64
Definition: COFF.h:227
support::ulittle32_t OrdinalBase
Definition: COFF.h:233
support::ulittle32_t ExportAddressTableRVA
Definition: COFF.h:236
support::ulittle32_t NameRVA
Definition: COFF.h:232
support::ulittle32_t NumberOfNamePointers
Definition: COFF.h:235
support::ulittle32_t NamePointerRVA
Definition: COFF.h:237
support::ulittle32_t ExportFlags
Definition: COFF.h:228
support::ulittle32_t AddressTableEntries
Definition: COFF.h:234
support::ulittle16_t MinorVersion
Definition: COFF.h:231
support::ulittle16_t MajorVersion
Definition: COFF.h:230
support::ulittle32_t TimeDateStamp
Definition: COFF.h:229
support::ulittle32_t OrdinalTableRVA
Definition: COFF.h:238
Definition: COFF.h:194
bool isOrdinal() const
Definition: COFF.h:197
uint32_t getHintNameRVA() const
Definition: COFF.h:204
IntTy Data
Definition: COFF.h:195
uint16_t getOrdinal() const
Definition: COFF.h:199
The 32-bit PE header that follows the COFF header.
Definition: COFF.h:109
support::ulittle16_t MajorImageVersion
Definition: COFF.h:124
support::ulittle16_t Subsystem
Definition: COFF.h:132
support::ulittle16_t MinorImageVersion
Definition: COFF.h:125
support::ulittle16_t DLLCharacteristics
Definition: COFF.h:134
support::ulittle32_t CheckSum
Definition: COFF.h:131
uint8_t MinorLinkerVersion
Definition: COFF.h:112
support::ulittle32_t SizeOfStackCommit
Definition: COFF.h:136
support::ulittle32_t SizeOfStackReserve
Definition: COFF.h:135
support::ulittle32_t NumberOfRvaAndSize
Definition: COFF.h:141
support::ulittle16_t MinorOperatingSystemVersion
Definition: COFF.h:123
support::ulittle32_t SectionAlignment
Definition: COFF.h:120
support::ulittle32_t SizeOfInitializedData
Definition: COFF.h:114
support::ulittle32_t SizeOfHeapCommit
Definition: COFF.h:138
support::ulittle32_t AddressOfEntryPoint
Definition: COFF.h:116
support::ulittle32_t Win32VersionValue
Definition: COFF.h:128
support::ulittle16_t MinorSubsystemVersion
Definition: COFF.h:127
support::ulittle16_t Magic
Definition: COFF.h:110
support::ulittle32_t BaseOfData
Definition: COFF.h:118
support::ulittle32_t SizeOfImage
Definition: COFF.h:129
support::ulittle32_t BaseOfCode
Definition: COFF.h:117
support::ulittle32_t ImageBase
Definition: COFF.h:119
support::ulittle16_t MajorOperatingSystemVersion
Definition: COFF.h:122
support::ulittle32_t SizeOfHeaders
Definition: COFF.h:130
support::ulittle32_t SizeOfUninitializedData
Definition: COFF.h:115
uint8_t MajorLinkerVersion
Definition: COFF.h:111
support::ulittle32_t FileAlignment
Definition: COFF.h:121
support::ulittle16_t MajorSubsystemVersion
Definition: COFF.h:126
support::ulittle32_t SizeOfCode
Definition: COFF.h:113
support::ulittle32_t SizeOfHeapReserve
Definition: COFF.h:137
support::ulittle32_t LoaderFlags
Definition: COFF.h:139
The 64-bit PE header that follows the COFF header.
Definition: COFF.h:145
support::ulittle16_t MinorOperatingSystemVersion
Definition: COFF.h:158
support::ulittle32_t SizeOfImage
Definition: COFF.h:164
support::ulittle32_t SizeOfCode
Definition: COFF.h:149
support::ulittle16_t MajorImageVersion
Definition: COFF.h:159
support::ulittle32_t SizeOfHeaders
Definition: COFF.h:165
support::ulittle32_t CheckSum
Definition: COFF.h:166
support::ulittle64_t SizeOfStackCommit
Definition: COFF.h:170
support::ulittle32_t SizeOfInitializedData
Definition: COFF.h:150
support::ulittle32_t Win32VersionValue
Definition: COFF.h:163
support::ulittle16_t MajorOperatingSystemVersion
Definition: COFF.h:157
support::ulittle16_t MajorSubsystemVersion
Definition: COFF.h:161
support::ulittle32_t LoaderFlags
Definition: COFF.h:173
support::ulittle16_t MinorImageVersion
Definition: COFF.h:160
support::ulittle32_t AddressOfEntryPoint
Definition: COFF.h:152
support::ulittle16_t MinorSubsystemVersion
Definition: COFF.h:162
support::ulittle32_t FileAlignment
Definition: COFF.h:156
support::ulittle64_t ImageBase
Definition: COFF.h:154
support::ulittle16_t Subsystem
Definition: COFF.h:167
support::ulittle16_t Magic
Definition: COFF.h:146
support::ulittle32_t SizeOfUninitializedData
Definition: COFF.h:151
support::ulittle32_t NumberOfRvaAndSize
Definition: COFF.h:174
support::ulittle32_t BaseOfCode
Definition: COFF.h:153
support::ulittle32_t SectionAlignment
Definition: COFF.h:155
support::ulittle64_t SizeOfHeapReserve
Definition: COFF.h:171
support::ulittle64_t SizeOfStackReserve
Definition: COFF.h:169
support::ulittle16_t DLLCharacteristics
Definition: COFF.h:168
support::ulittle64_t SizeOfHeapCommit
Definition: COFF.h:172
Definition: COFF.h:241
support::ulittle32_t ExportRVA
Definition: COFF.h:242
support::ulittle32_t ForwarderRVA
Definition: COFF.h:243