aboutsummaryrefslogtreecommitdiff
path: root/ld/pdb.h
diff options
context:
space:
mode:
authorMark Harmstone <mark@harmstone.com>2022-10-31 00:15:54 +0000
committerAlan Modra <amodra@gmail.com>2022-10-31 12:57:26 +1030
commit0882710510059d9bf10d3e2324e0441029b50ce9 (patch)
treeb358e0a0a93cba04e81c5ef8f1af392b1a74d654 /ld/pdb.h
parenta72672224093ca600154b934ba662b677ae10ba8 (diff)
downloadgdb-0882710510059d9bf10d3e2324e0441029b50ce9.zip
gdb-0882710510059d9bf10d3e2324e0441029b50ce9.tar.gz
gdb-0882710510059d9bf10d3e2324e0441029b50ce9.tar.bz2
ld: Add publics stream to PDB files
Diffstat (limited to 'ld/pdb.h')
-rw-r--r--ld/pdb.h47
1 files changed, 47 insertions, 0 deletions
diff --git a/ld/pdb.h b/ld/pdb.h
index e5f53b4..1a80101 100644
--- a/ld/pdb.h
+++ b/ld/pdb.h
@@ -28,6 +28,8 @@
#include "bfd.h"
#include <stdbool.h>
+#define S_PUB32 0x110e
+
/* PDBStream70 in pdb1.h */
struct pdb_stream_70
{
@@ -91,6 +93,51 @@ struct pdb_dbi_stream_header
#define DBI_STREAM_VERSION_70 19990903
+/* PSGSIHDR in gsi.h */
+struct publics_header
+{
+ uint32_t sym_hash_size;
+ uint32_t addr_map_size;
+ uint32_t num_thunks;
+ uint32_t thunks_size;
+ uint32_t thunk_table;
+ uint32_t thunk_table_offset;
+ uint32_t num_sects;
+};
+
+/* GSIHashHdr in gsi.h */
+struct globals_hash_header
+{
+ uint32_t signature;
+ uint32_t version;
+ uint32_t entries_size;
+ uint32_t buckets_size;
+};
+
+/* HRFile in gsi.h */
+struct hash_record
+{
+ uint32_t offset;
+ uint32_t reference;
+};
+
+#define GLOBALS_HASH_SIGNATURE 0xffffffff
+#define GLOBALS_HASH_VERSION_70 0xf12f091a
+
+/* PUBSYM32 in cvinfo.h */
+struct pubsym
+{
+ uint16_t record_length;
+ uint16_t record_type;
+ uint32_t flags;
+ uint32_t offset;
+ uint16_t section;
+ /* followed by null-terminated string */
+} ATTRIBUTE_PACKED;
+
+/* see bitset CV_PUBSYMFLAGS in cvinfo.h */
+#define PUBSYM_FUNCTION 0x2
+
struct optional_dbg_header
{
uint16_t fpo_stream;