]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - ld/pdb.h
Updated French translations for GOLD and LD
[thirdparty/binutils-gdb.git] / ld / pdb.h
CommitLineData
b41a6533 1/* pdb.h - header file for generating PDB CodeView debugging files.
fd67aa11 2 Copyright (C) 2022-2024 Free Software Foundation, Inc.
b41a6533
MH
3
4 This file is part of the GNU Binutils.
5
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 3 of the License, or
9 (at your option) any later version.
10
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
19 MA 02110-1301, USA. */
20
21/* Header files referred to below can be found in Microsoft's PDB
22 repository: https://github.com/microsoft/microsoft-pdb. */
23
24#ifndef PDB_H
25#define PDB_H
26
27#include "sysdep.h"
28#include "bfd.h"
29#include <stdbool.h>
d5b4c0dd
MH
30#include <stddef.h>
31
32#define LF_VTSHAPE 0x000a
33#define LF_MODIFIER 0x1001
34#define LF_POINTER 0x1002
35#define LF_PROCEDURE 0x1008
36#define LF_MFUNCTION 0x1009
37#define LF_ARGLIST 0x1201
38#define LF_FIELDLIST 0x1203
39#define LF_BITFIELD 0x1205
40#define LF_METHODLIST 0x1206
41#define LF_BCLASS 0x1400
42#define LF_VBCLASS 0x1401
43#define LF_IVBCLASS 0x1402
44#define LF_INDEX 0x1404
45#define LF_VFUNCTAB 0x1409
46#define LF_ENUMERATE 0x1502
47#define LF_ARRAY 0x1503
48#define LF_CLASS 0x1504
49#define LF_STRUCTURE 0x1505
50#define LF_UNION 0x1506
51#define LF_ENUM 0x1507
52#define LF_MEMBER 0x150d
53#define LF_STMEMBER 0x150e
54#define LF_METHOD 0x150f
55#define LF_NESTTYPE 0x1510
56#define LF_ONEMETHOD 0x1511
5c9e42e0 57#define LF_VFTABLE 0x151d
fca9096a
MH
58#define LF_FUNC_ID 0x1601
59#define LF_MFUNC_ID 0x1602
60#define LF_BUILDINFO 0x1603
61#define LF_SUBSTR_LIST 0x1604
62#define LF_STRING_ID 0x1605
81784004
MH
63#define LF_UDT_SRC_LINE 0x1606
64#define LF_UDT_MOD_SRC_LINE 0x1607
d5b4c0dd
MH
65
66#define LF_CHAR 0x8000
67#define LF_SHORT 0x8001
68#define LF_USHORT 0x8002
69#define LF_LONG 0x8003
70#define LF_ULONG 0x8004
71#define LF_QUADWORD 0x8009
72#define LF_UQUADWORD 0x800a
b41a6533 73
81814b6f 74#define S_END 0x0006
5d9c0336
MH
75#define S_FRAMEPROC 0x1012
76#define S_OBJNAME 0x1101
77#define S_THUNK32 0x1102
78#define S_BLOCK32 0x1103
79#define S_LABEL32 0x1105
80#define S_REGISTER 0x1106
81814b6f
MH
81#define S_CONSTANT 0x1107
82#define S_UDT 0x1108
5d9c0336 83#define S_BPREL32 0x110b
81814b6f
MH
84#define S_LDATA32 0x110c
85#define S_GDATA32 0x110d
08827105 86#define S_PUB32 0x110e
81814b6f
MH
87#define S_LPROC32 0x110f
88#define S_GPROC32 0x1110
5d9c0336 89#define S_REGREL32 0x1111
81814b6f
MH
90#define S_LTHREAD32 0x1112
91#define S_GTHREAD32 0x1113
5d9c0336 92#define S_UNAMESPACE 0x1124
81814b6f
MH
93#define S_PROCREF 0x1125
94#define S_LPROCREF 0x1127
5d9c0336
MH
95#define S_FRAMECOOKIE 0x113a
96#define S_COMPILE3 0x113c
8d25f5ef 97#define S_ENVBLOCK 0x113d
5d9c0336
MH
98#define S_LOCAL 0x113e
99#define S_DEFRANGE_REGISTER 0x1141
100#define S_DEFRANGE_FRAMEPOINTER_REL 0x1142
101#define S_DEFRANGE_SUBFIELD_REGISTER 0x1143
102#define S_DEFRANGE_FRAMEPOINTER_REL_FULL_SCOPE 0x1144
103#define S_DEFRANGE_REGISTER_REL 0x1145
81814b6f
MH
104#define S_LPROC32_ID 0x1146
105#define S_GPROC32_ID 0x1147
5d9c0336
MH
106#define S_BUILDINFO 0x114c
107#define S_INLINESITE 0x114d
108#define S_INLINESITE_END 0x114e
81814b6f 109#define S_PROC_ID_END 0x114f
5d9c0336 110#define S_HEAPALLOCSITE 0x115e
08827105 111
b41a6533
MH
112/* PDBStream70 in pdb1.h */
113struct pdb_stream_70
114{
115 uint32_t version;
116 uint32_t signature;
117 uint32_t age;
118 uint8_t guid[16];
119};
120
121#define PDB_STREAM_VERSION_VC70 20000404
122#define PDB_STREAM_VERSION_VC140 20140508
123
124/* HDR in tpi.h */
125struct pdb_tpi_stream_header
126{
127 uint32_t version;
128 uint32_t header_size;
129 uint32_t type_index_begin;
130 uint32_t type_index_end;
131 uint32_t type_record_bytes;
132 uint16_t hash_stream_index;
133 uint16_t hash_aux_stream_index;
134 uint32_t hash_key_size;
135 uint32_t num_hash_buckets;
136 uint32_t hash_value_buffer_offset;
137 uint32_t hash_value_buffer_length;
138 uint32_t index_offset_buffer_offset;
139 uint32_t index_offset_buffer_length;
140 uint32_t hash_adj_buffer_offset;
141 uint32_t hash_adj_buffer_length;
142};
143
144#define TPI_STREAM_VERSION_80 20040203
145
146#define TPI_FIRST_INDEX 0x1000
d5b4c0dd 147#define NUM_TPI_HASH_BUCKETS 0x3ffff
b41a6533 148
81814b6f
MH
149#define NUM_GLOBALS_HASH_BUCKETS 4096
150
b41a6533
MH
151/* NewDBIHdr in dbi.h */
152struct pdb_dbi_stream_header
153{
154 uint32_t version_signature;
155 uint32_t version_header;
156 uint32_t age;
157 uint16_t global_stream_index;
158 uint16_t build_number;
159 uint16_t public_stream_index;
160 uint16_t pdb_dll_version;
161 uint16_t sym_record_stream;
162 uint16_t pdb_dll_rbld;
163 uint32_t mod_info_size;
164 uint32_t section_contribution_size;
165 uint32_t section_map_size;
166 uint32_t source_info_size;
167 uint32_t type_server_map_size;
168 uint32_t mfc_type_server_index;
169 uint32_t optional_dbg_header_size;
170 uint32_t ec_substream_size;
171 uint16_t flags;
172 uint16_t machine;
173 uint32_t padding;
174};
175
176#define DBI_STREAM_VERSION_70 19990903
177
08827105
MH
178/* PSGSIHDR in gsi.h */
179struct publics_header
180{
181 uint32_t sym_hash_size;
182 uint32_t addr_map_size;
183 uint32_t num_thunks;
184 uint32_t thunks_size;
185 uint32_t thunk_table;
186 uint32_t thunk_table_offset;
187 uint32_t num_sects;
188};
189
190/* GSIHashHdr in gsi.h */
191struct globals_hash_header
192{
193 uint32_t signature;
194 uint32_t version;
195 uint32_t entries_size;
196 uint32_t buckets_size;
197};
198
199/* HRFile in gsi.h */
200struct hash_record
201{
202 uint32_t offset;
203 uint32_t reference;
204};
205
206#define GLOBALS_HASH_SIGNATURE 0xffffffff
207#define GLOBALS_HASH_VERSION_70 0xf12f091a
208
209/* PUBSYM32 in cvinfo.h */
210struct pubsym
211{
212 uint16_t record_length;
213 uint16_t record_type;
214 uint32_t flags;
215 uint32_t offset;
216 uint16_t section;
217 /* followed by null-terminated string */
218} ATTRIBUTE_PACKED;
219
220/* see bitset CV_PUBSYMFLAGS in cvinfo.h */
221#define PUBSYM_FUNCTION 0x2
222
b41a6533
MH
223struct optional_dbg_header
224{
225 uint16_t fpo_stream;
226 uint16_t exception_stream;
227 uint16_t fixup_stream;
228 uint16_t omap_to_src_stream;
229 uint16_t omap_from_src_stream;
230 uint16_t section_header_stream;
231 uint16_t token_map_stream;
232 uint16_t xdata_stream;
233 uint16_t pdata_stream;
234 uint16_t new_fpo_stream;
235 uint16_t orig_section_header_stream;
236};
237
5967ca92
MH
238#define CV_SIGNATURE_C13 4
239
81814b6f 240#define DEBUG_S_SYMBOLS 0xf1
598c1ae6 241#define DEBUG_S_LINES 0xf2
f559276d 242#define DEBUG_S_STRINGTABLE 0xf3
803561cb 243#define DEBUG_S_FILECHKSMS 0xf4
f559276d
MH
244
245#define STRING_TABLE_SIGNATURE 0xeffeeffe
246#define STRING_TABLE_VERSION 1
247
248/* VHdr in nmt.h */
249struct string_table_header
250{
251 uint32_t signature;
252 uint32_t version;
253};
254
e2a1b0a0
MH
255#define SECTION_CONTRIB_VERSION_60 0xf12eba2d
256
5967ca92
MH
257/* SC in dbicommon.h */
258struct section_contribution
259{
260 uint16_t section;
261 uint16_t padding1;
262 uint32_t offset;
263 uint32_t size;
264 uint32_t characteristics;
265 uint16_t module_index;
266 uint16_t padding2;
267 uint32_t data_crc;
268 uint32_t reloc_crc;
269};
270
271/* MODI_60_Persist in dbi.h */
272struct module_info
273{
274 uint32_t unused1;
275 struct section_contribution sc;
276 uint16_t flags;
277 uint16_t module_sym_stream;
278 uint32_t sym_byte_size;
279 uint32_t c11_byte_size;
280 uint32_t c13_byte_size;
281 uint16_t source_file_count;
282 uint16_t padding;
283 uint32_t unused2;
284 uint32_t source_file_name_index;
285 uint32_t pdb_file_path_name_index;
286};
287
803561cb
MH
288/* filedata in dumpsym7.cpp */
289struct file_checksum
290{
291 uint32_t file_id;
292 uint8_t checksum_length;
293 uint8_t checksum_type;
294} ATTRIBUTE_PACKED;
295
d5b4c0dd
MH
296/* lfModifier in cvinfo.h */
297struct lf_modifier
298{
299 uint16_t size;
300 uint16_t kind;
301 uint32_t base_type;
302 uint16_t modifier;
303 uint16_t padding;
304} ATTRIBUTE_PACKED;
305
306/* lfPointer in cvinfo.h */
307struct lf_pointer
308{
309 uint16_t size;
310 uint16_t kind;
311 uint32_t base_type;
312 uint32_t attributes;
313} ATTRIBUTE_PACKED;
314
fca9096a 315/* lfArgList in cvinfo.h (used for both LF_ARGLIST and LF_SUBSTR_LIST) */
d5b4c0dd
MH
316struct lf_arglist
317{
318 uint16_t size;
319 uint16_t kind;
320 uint32_t num_entries;
321 uint32_t args[];
322} ATTRIBUTE_PACKED;
323
324/* lfProc in cvinfo.h */
325struct lf_procedure
326{
327 uint16_t size;
328 uint16_t kind;
329 uint32_t return_type;
330 uint8_t calling_convention;
331 uint8_t attributes;
332 uint16_t num_parameters;
333 uint32_t arglist;
334} ATTRIBUTE_PACKED;
335
336/* lfMFunc in cvinfo.h */
337struct lf_mfunction
338{
339 uint16_t size;
340 uint16_t kind;
341 uint32_t return_type;
342 uint32_t containing_class_type;
343 uint32_t this_type;
344 uint8_t calling_convention;
345 uint8_t attributes;
346 uint16_t num_parameters;
347 uint32_t arglist;
348 int32_t this_adjustment;
349} ATTRIBUTE_PACKED;
350
351/* lfArray in cvinfo.h */
352struct lf_array
353{
354 uint16_t size;
355 uint16_t kind;
356 uint32_t element_type;
357 uint32_t index_type;
358 uint16_t length_in_bytes;
359 char name[];
360} ATTRIBUTE_PACKED;
361
362/* lfBitfield in cvinfo.h */
363struct lf_bitfield
364{
365 uint16_t size;
366 uint16_t kind;
367 uint32_t base_type;
368 uint8_t length;
369 uint8_t position;
370} ATTRIBUTE_PACKED;
371
372/* lfMember in cvinfo.h */
373struct lf_member
374{
375 uint16_t kind;
376 uint16_t attributes;
377 uint32_t type;
378 uint16_t offset;
379 char name[];
380} ATTRIBUTE_PACKED;
381
382/* from bitfield structure CV_prop_t in cvinfo.h */
383#define CV_PROP_FORWARD_REF 0x80
384#define CV_PROP_SCOPED 0x100
385#define CV_PROP_HAS_UNIQUE_NAME 0x200
386
387/* lfClass in cvinfo.h */
388struct lf_class
389{
390 uint16_t size;
391 uint16_t kind;
392 uint16_t num_members;
393 uint16_t properties;
394 uint32_t field_list;
395 uint32_t derived_from;
396 uint32_t vshape;
397 uint16_t length;
398 char name[];
399} ATTRIBUTE_PACKED;
400
401/* lfUnion in cvinfo.h */
402struct lf_union
403{
404 uint16_t size;
405 uint16_t kind;
406 uint16_t num_members;
407 uint16_t properties;
408 uint32_t field_list;
409 uint16_t length;
410 char name[];
411} ATTRIBUTE_PACKED;
412
413/* lfEnumerate in cvinfo.h */
414struct lf_enumerate
415{
416 uint16_t kind;
417 uint16_t attributes;
418 uint16_t value;
419 /* then actual value if value >= 0x8000 */
420 char name[];
421} ATTRIBUTE_PACKED;
422
423/* lfEnum in cvinfo.h */
424struct lf_enum
425{
426 uint16_t size;
427 uint16_t kind;
428 uint16_t num_elements;
429 uint16_t properties;
430 uint32_t underlying_type;
431 uint32_t field_list;
432 char name[];
433} ATTRIBUTE_PACKED;
434
435/* lfIndex in cvinfo.h */
436struct lf_index
437{
438 uint16_t kind;
439 uint16_t padding;
440 uint32_t index;
441} ATTRIBUTE_PACKED;
442
443/* lfOneMethod in cvinfo.h */
444struct lf_onemethod
445{
446 uint16_t kind;
447 uint16_t method_attribute;
448 uint32_t method_type;
449 char name[];
450} ATTRIBUTE_PACKED;
451
452/* mlMethod in cvinfo.h */
453struct lf_methodlist_entry
454{
455 uint16_t method_attribute;
456 uint16_t padding;
457 uint32_t method_type;
458} ATTRIBUTE_PACKED;
459
460/* lfMethodList in cvinfo.h */
461struct lf_methodlist
462{
463 uint16_t size;
464 uint16_t kind;
465 struct lf_methodlist_entry entries[];
466} ATTRIBUTE_PACKED;
467
468/* lfMethod in cvinfo.h */
469struct lf_method
470{
471 uint16_t kind;
472 uint16_t count;
473 uint32_t method_list;
474 char name[];
475} ATTRIBUTE_PACKED;
476
477/* lfBClass in cvinfo.h */
478struct lf_bclass
479{
480 uint16_t kind;
481 uint16_t attributes;
482 uint32_t base_class_type;
483 uint16_t offset;
d5b4c0dd
MH
484} ATTRIBUTE_PACKED;
485
486/* lfVFuncTab in cvinfo.h */
487struct lf_vfunctab
488{
489 uint16_t kind;
490 uint16_t padding;
491 uint32_t type;
492} ATTRIBUTE_PACKED;
493
494/* lfVBClass in cvinfo.h */
495struct lf_vbclass
496{
497 uint16_t kind;
498 uint16_t attributes;
499 uint32_t base_class_type;
500 uint32_t virtual_base_pointer_type;
501 uint16_t virtual_base_pointer_offset;
502 uint16_t virtual_base_vbtable_offset;
503} ATTRIBUTE_PACKED;
504
505/* lfSTMember in cvinfo.h */
506struct lf_static_member
507{
508 uint16_t kind;
509 uint16_t attributes;
510 uint32_t type;
511 char name[];
512} ATTRIBUTE_PACKED;
513
514/* lfNestType in cvinfo.h */
515struct lf_nest_type
516{
517 uint16_t kind;
518 uint16_t padding;
519 uint32_t type;
520 char name[];
521} ATTRIBUTE_PACKED;
522
fca9096a
MH
523/* lfStringId in cvinfo.h */
524struct lf_string_id
525{
526 uint16_t size;
527 uint16_t kind;
528 uint32_t substring;
529 char string[];
530} ATTRIBUTE_PACKED;
531
532/* lfBuildInfo in cvinfo.h */
533struct lf_build_info
534{
535 uint16_t size;
536 uint16_t kind;
537 uint16_t count;
538 uint32_t strings[];
539} ATTRIBUTE_PACKED;
540
541/* lfFuncId in cvinfo.h */
542struct lf_func_id
543{
544 uint16_t size;
545 uint16_t kind;
546 uint32_t parent_scope;
547 uint32_t function_type;
548 char name[];
549} ATTRIBUTE_PACKED;
550
551/* lfMFuncId in cvinfo.h */
552struct lf_mfunc_id
553{
554 uint16_t size;
555 uint16_t kind;
556 uint32_t parent_type;
557 uint32_t function_type;
558 char name[];
559} ATTRIBUTE_PACKED;
560
81784004
MH
561/* lfUdtSrcLine in cvinfo.h */
562struct lf_udt_src_line
563{
564 uint16_t size;
565 uint16_t kind;
566 uint32_t type;
567 uint32_t source_file_type;
568 uint32_t line_no;
569} ATTRIBUTE_PACKED;
570
571/* lfUdtModSrcLine in cvinfo.h */
572struct lf_udt_mod_src_line
573{
574 uint16_t size;
575 uint16_t kind;
576 uint32_t type;
577 uint32_t source_file_string;
578 uint32_t line_no;
579 uint16_t module_no;
580} ATTRIBUTE_PACKED;
581
5c9e42e0
MH
582/* lfVftable in cvinfo.h */
583struct lf_vftable
584{
585 uint16_t size;
586 uint16_t kind;
587 uint32_t type;
588 uint32_t base_vftable;
589 uint32_t offset;
590 uint32_t names_len;
591 char names[];
592} ATTRIBUTE_PACKED;
593
81814b6f
MH
594/* DATASYM32 in cvinfo.h */
595struct datasym
596{
597 uint16_t size;
598 uint16_t kind;
599 uint32_t type;
600 uint32_t offset;
601 uint16_t section;
602 char name[];
603} ATTRIBUTE_PACKED;
604
605/* PROCSYM32 in cvinfo.h */
606struct procsym
607{
608 uint16_t size;
609 uint16_t kind;
610 uint32_t parent;
611 uint32_t end;
612 uint32_t next;
613 uint32_t proc_len;
614 uint32_t debug_start;
615 uint32_t debug_end;
616 uint32_t type;
617 uint32_t offset;
618 uint16_t section;
619 uint8_t flags;
620 char name[];
621} ATTRIBUTE_PACKED;
622
623/* REFSYM2 in cvinfo.h */
624struct refsym
625{
626 uint16_t size;
627 uint16_t kind;
628 uint32_t sum_name;
629 uint32_t symbol_offset;
630 uint16_t mod;
631 char name[];
632} ATTRIBUTE_PACKED;
633
634/* UDTSYM in cvinfo.h */
635struct udtsym
636{
637 uint16_t size;
638 uint16_t kind;
639 uint32_t type;
640 char name[];
641} ATTRIBUTE_PACKED;
642
643/* CONSTSYM in cvinfo.h */
644struct constsym
645{
646 uint16_t size;
647 uint16_t kind;
648 uint32_t type;
649 uint16_t value;
650 /* then actual value if value >= 0x8000 */
651 char name[];
652} ATTRIBUTE_PACKED;
653
5d9c0336
MH
654/* BUILDINFOSYM in cvinfo.h */
655struct buildinfosym
656{
657 uint16_t size;
658 uint16_t kind;
659 uint32_t type;
660} ATTRIBUTE_PACKED;
661
662/* BLOCKSYM32 in cvinfo.h */
663struct blocksym
664{
665 uint16_t size;
666 uint16_t kind;
667 uint32_t parent;
668 uint32_t end;
669 uint32_t len;
670 uint32_t offset;
671 uint16_t section;
672 char name[];
673} ATTRIBUTE_PACKED;
674
675/* BPRELSYM32 in cvinfo.h */
676struct bprelsym
677{
678 uint16_t size;
679 uint16_t kind;
680 uint32_t bp_offset;
681 uint32_t type;
682 char name[];
683} ATTRIBUTE_PACKED;
684
685/* REGSYM in cvinfo.h */
686struct regsym
687{
688 uint16_t size;
689 uint16_t kind;
690 uint32_t type;
691 uint16_t reg;
692 char name[];
693} ATTRIBUTE_PACKED;
694
695/* REGREL32 in cvinfo.h */
696struct regrel
697{
698 uint16_t size;
699 uint16_t kind;
700 uint32_t offset;
701 uint32_t type;
702 uint16_t reg;
703 char name[];
704} ATTRIBUTE_PACKED;
705
706/* LOCALSYM in cvinfo.h */
707struct localsym
708{
709 uint16_t size;
710 uint16_t kind;
711 uint32_t type;
712 uint16_t flags;
713 char name[];
714} ATTRIBUTE_PACKED;
715
716/* CV_LVAR_ADDR_RANGE in cvinfo.h */
717struct lvar_addr_range
718{
719 uint32_t offset;
720 uint16_t section;
721 uint16_t length;
722} ATTRIBUTE_PACKED;
723
724/* CV_LVAR_ADDR_GAP in cvinfo.h */
725struct lvar_addr_gap {
726 uint16_t offset;
727 uint16_t length;
728} ATTRIBUTE_PACKED;
729
730/* DEFRANGESYMREGISTERREL in cvinfo.h */
731struct defrange_register_rel
732{
733 uint16_t size;
734 uint16_t kind;
735 uint16_t reg;
736 uint16_t offset_parent;
737 uint32_t offset_register;
738 struct lvar_addr_range range;
739 struct lvar_addr_gap gaps[];
740} ATTRIBUTE_PACKED;
741
742/* DEFRANGESYMFRAMEPOINTERREL in cvinfo.h */
743struct defrange_framepointer_rel
744{
745 uint16_t size;
746 uint16_t kind;
747 uint32_t offset;
748 struct lvar_addr_range range;
749 struct lvar_addr_gap gaps[];
750} ATTRIBUTE_PACKED;
751
752/* DEFRANGESYMSUBFIELDREGISTER in cvinfo.h */
753struct defrange_subfield_register
754{
755 uint16_t size;
756 uint16_t kind;
757 uint16_t reg;
758 uint16_t attributes;
759 uint32_t offset_parent;
760 struct lvar_addr_range range;
761 struct lvar_addr_gap gaps[];
762} ATTRIBUTE_PACKED;
763
764/* DEFRANGESYMREGISTER in cvinfo.h */
765struct defrange_register
766{
767 uint16_t size;
768 uint16_t kind;
769 uint16_t reg;
770 uint16_t attributes;
771 struct lvar_addr_range range;
772 struct lvar_addr_gap gaps[];
773} ATTRIBUTE_PACKED;
774
775/* INLINESITESYM in cvinfo.h */
776struct inline_site
777{
778 uint16_t size;
779 uint16_t kind;
780 uint32_t parent;
781 uint32_t end;
782 uint32_t inlinee;
783 uint8_t binary_annotations[];
784} ATTRIBUTE_PACKED;
785
786/* THUNKSYM32 in cvinfo.h */
787struct thunk
788{
789 uint16_t size;
790 uint16_t kind;
791 uint32_t parent;
792 uint32_t end;
793 uint32_t next;
794 uint32_t offset;
795 uint16_t section;
796 uint16_t length;
797 uint8_t thunk_type;
798 char name[];
799} ATTRIBUTE_PACKED;
800
801/* HEAPALLOCSITE in cvinfo.h */
802struct heap_alloc_site
803{
804 uint16_t size;
805 uint16_t kind;
806 uint32_t offset;
807 uint16_t section;
808 uint16_t length;
809 uint32_t type;
810} ATTRIBUTE_PACKED;
811
8d25f5ef
MH
812/* OBJNAMESYM in cvinfo.h */
813struct objname
814{
815 uint16_t size;
816 uint16_t kind;
817 uint32_t signature;
818 char name[];
819} ATTRIBUTE_PACKED;
820
821#define CV_CFL_80386 0x03
822#define CV_CFL_X64 0xD0
9a02fbd1 823#define CV_CFL_ARM64 0xF6
8d25f5ef
MH
824
825#define CV_CFL_LINK 0x07
826
827/* COMPILESYM3 in cvinfo.h */
828struct compile3
829{
830 uint16_t size;
831 uint16_t kind;
832 uint32_t flags;
833 uint16_t machine;
834 uint16_t frontend_major;
835 uint16_t frontend_minor;
836 uint16_t frontend_build;
837 uint16_t frontend_qfe;
838 uint16_t backend_major;
839 uint16_t backend_minor;
840 uint16_t backend_build;
841 uint16_t backend_qfe;
842 char compiler[];
843} ATTRIBUTE_PACKED;
844
845/* ENVBLOCKSYM in cvinfo.h */
846struct envblock
847{
848 uint16_t size;
849 uint16_t kind;
850 uint8_t flags;
851 char strings[];
852} ATTRIBUTE_PACKED;
853
b41a6533
MH
854extern bool create_pdb_file (bfd *, const char *, const unsigned char *);
855
856#endif