Commit 9a74d2b6 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

include: Use stream to denote MSF stream/file.

Try to apply consistent naming: - file refers to (PDB) file - stream refers to a stream/file inside the PDB stream at MSF level (we were also using file for the later, which isn't very simple to follow). Signed-off-by: 's avatarEric Pouech <eric.pouech@gmail.com>
parent 26f89d84
...@@ -43,30 +43,29 @@ ...@@ -43,30 +43,29 @@
* *
* Regarding PDB files: * Regarding PDB files:
* ------------------- * -------------------
* They are implemented as a set of internal files (as a small file * They are implemented as a set of internal streams (as a small file
* system). The file is split into blocks, an internal file is made * system). The file is split into blocks, an internal stream is made of a set
* of a set of blocks. Internal files are accessed through * of blocks, that can be non continuous. The table of contents gives the set of
* numbers. For example, * blocks for a given stream.
* 1/ is the ROOT (basic information on the file) * Some internal streams are accessed through numbers. For example,
* 2/ is the Symbol information (global symbols, local variables...) * #1 is the ROOT (basic information on the file)
* 3/ is the Type internal file (each the symbols can have type * #2 is the Symbol information (global symbols, local variables...)
* #3 is the Type internal stream (each the symbols can have type
* information associated with it). * information associated with it).
* *
* Over the years, three formats existed for the PDB: * Over the years, three formats existed for the PDB:
* - ?? was rather linked to 16 bit code (our support shall be rather * - ?? was rather linked to 16 bit code (our support shall be rather bad)
* bad) * - JG: it's the signature embedded in the file header. This format has been
* - JG: it's the signature embedded in the file header. This format * used in MSVC 2.0 => 5.0.
* has been used in MSVC 2.0 => 5.0. * - DS: it's the signature embedded in the file header. It's the current format
* - DS: it's the signature embedded in the file header. It's the * supported my MS.
* current format supported my MS.
* *
* Types internal stream * Types internal stream (aka TPI)
* --------------------- * ---------------------
* Types (from the Type internal file) have existed in three flavors * Types (from the Type internal stream) have existed in three flavors (note
* (note that those flavors came as historical evolution, but there * that those flavors came as historical evolution, but there isn't a one to one
* isn't a one to one link between types evolution and PDB formats' * link between types evolution and PDB formats' evolutions:
* evolutions: * - the first flavor (suffixed by V1 in mscvpdb.h), where the types
* - the first flavor (suffixed by V1 in this file), where the types
* and subtypes are 16 bit entities; and where strings are in Pascal * and subtypes are 16 bit entities; and where strings are in Pascal
* format (first char is their length and are not 0 terminated) * format (first char is their length and are not 0 terminated)
* - the second flavor (suffixed by V2) differs from first flavor with * - the second flavor (suffixed by V2) differs from first flavor with
...@@ -2376,7 +2375,7 @@ struct startend ...@@ -2376,7 +2375,7 @@ struct startend
* ======================================== */ * ======================================== */
struct PDB_FILE struct PDB_JG_STREAM
{ {
unsigned int size; unsigned int size;
unsigned int unknown; unsigned int unknown;
...@@ -2389,7 +2388,7 @@ struct PDB_JG_HEADER ...@@ -2389,7 +2388,7 @@ struct PDB_JG_HEADER
unsigned int block_size; unsigned int block_size;
unsigned short free_list_block; unsigned short free_list_block;
unsigned short total_alloc; unsigned short total_alloc;
struct PDB_FILE toc; struct PDB_JG_STREAM toc;
unsigned short toc_block[1]; unsigned short toc_block[1];
}; };
...@@ -2406,14 +2405,14 @@ struct PDB_DS_HEADER ...@@ -2406,14 +2405,14 @@ struct PDB_DS_HEADER
struct PDB_JG_TOC struct PDB_JG_TOC
{ {
unsigned int num_files; unsigned int num_streams;
struct PDB_FILE file[1]; struct PDB_JG_STREAM streams[1];
}; };
struct PDB_DS_TOC struct PDB_DS_TOC
{ {
unsigned int num_files; unsigned int num_streams;
unsigned int file_size[1]; unsigned int stream_size[1];
}; };
struct PDB_JG_ROOT struct PDB_JG_ROOT
...@@ -2441,7 +2440,7 @@ typedef struct _PDB_TYPES_OLD ...@@ -2441,7 +2440,7 @@ typedef struct _PDB_TYPES_OLD
unsigned short first_index; unsigned short first_index;
unsigned short last_index; unsigned short last_index;
unsigned int type_size; unsigned int type_size;
unsigned short hash_file; unsigned short hash_stream;
unsigned short pad; unsigned short pad;
} PDB_TYPES_OLD, *PPDB_TYPES_OLD; } PDB_TYPES_OLD, *PPDB_TYPES_OLD;
...@@ -2452,7 +2451,7 @@ typedef struct _PDB_TYPES ...@@ -2452,7 +2451,7 @@ typedef struct _PDB_TYPES
unsigned int first_index; unsigned int first_index;
unsigned int last_index; unsigned int last_index;
unsigned int type_size; unsigned int type_size;
unsigned short hash_file; unsigned short hash_stream;
unsigned short pad; unsigned short pad;
unsigned int hash_value_size; unsigned int hash_value_size;
unsigned int hash_num_buckets; unsigned int hash_num_buckets;
...@@ -2493,7 +2492,7 @@ typedef struct _PDB_SYMBOL_FILE ...@@ -2493,7 +2492,7 @@ typedef struct _PDB_SYMBOL_FILE
unsigned int unknown1; unsigned int unknown1;
PDB_SYMBOL_RANGE range; PDB_SYMBOL_RANGE range;
unsigned short flag; unsigned short flag;
unsigned short file; unsigned short stream;
unsigned int symbol_size; unsigned int symbol_size;
unsigned int lineno_size; unsigned int lineno_size;
unsigned int lineno2_size; unsigned int lineno2_size;
...@@ -2507,7 +2506,7 @@ typedef struct _PDB_SYMBOL_FILE_EX ...@@ -2507,7 +2506,7 @@ typedef struct _PDB_SYMBOL_FILE_EX
unsigned int unknown1; unsigned int unknown1;
PDB_SYMBOL_RANGE_EX range; PDB_SYMBOL_RANGE_EX range;
unsigned short flag; unsigned short flag;
unsigned short file; unsigned short stream;
unsigned int symbol_size; unsigned int symbol_size;
unsigned int lineno_size; unsigned int lineno_size;
unsigned int lineno2_size; unsigned int lineno2_size;
...@@ -2535,9 +2534,9 @@ typedef struct _PDB_SYMBOL_IMPORT ...@@ -2535,9 +2534,9 @@ typedef struct _PDB_SYMBOL_IMPORT
typedef struct _PDB_SYMBOLS_OLD typedef struct _PDB_SYMBOLS_OLD
{ {
unsigned short global_hash_file; unsigned short global_hash_stream;
unsigned short public_file; unsigned short public_stream;
unsigned short gsym_file; unsigned short gsym_stream;
unsigned short pad; unsigned short pad;
unsigned int module_size; unsigned int module_size;
unsigned int offset_size; unsigned int offset_size;
...@@ -2550,11 +2549,11 @@ typedef struct _PDB_SYMBOLS ...@@ -2550,11 +2549,11 @@ typedef struct _PDB_SYMBOLS
unsigned int signature; unsigned int signature;
unsigned int version; unsigned int version;
unsigned int age; unsigned int age;
unsigned short global_hash_file; unsigned short global_hash_stream;
unsigned short flags; unsigned short flags;
unsigned short public_file; unsigned short public_stream;
unsigned short bldVer; unsigned short bldVer;
unsigned short gsym_file; unsigned short gsym_stream;
unsigned short rbldVer; unsigned short rbldVer;
unsigned int module_size; unsigned int module_size;
unsigned int offset_size; unsigned int offset_size;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment