1 // Licensed to the .NET Foundation under one or more agreements.
2 // The .NET Foundation licenses this file to you under the MIT license.
3 // See the LICENSE file in the project root for more information.
4 // ===========================================================================
8 // ===========================================================================
17 struct SymLexicalScope;
19 struct SymUsingNamespace;
25 extern "C" const GUID ILDB_VERSION_GUID_FSR;
26 extern "C" const GUID ILDB_VERSION_GUID;
28 #define ILDB_MINOR_VERSION_NUMBER 0
29 #define ILDB_SIGNATURE "_ildb_signature"
30 #define ILDB_SIGNATURE_SIZE (16)
32 typedef struct PDBInfo {
34 // Entry point of the PE
35 mdMethodDef m_userEntryPoint;
37 UINT32 m_CountOfMethods;
38 UINT32 m_CountOfScopes;
40 UINT32 m_CountOfUsing;
41 UINT32 m_CountOfConstants;
42 UINT32 m_CountOfDocuments;
43 UINT32 m_CountOfSequencePoints;
44 UINT32 m_CountOfBytes;
45 UINT32 m_CountOfStringBytes;
50 memset(this, 0, sizeof(PDBInfo));
51 // Make sure m_userEntryPoint initialized correctly
52 _ASSERTE(mdTokenNil == 0);
56 void ConvertEndianness() {
57 m_userEntryPoint = VAL32(m_userEntryPoint);
58 m_CountOfMethods = VAL32(m_CountOfMethods);
59 m_CountOfScopes = VAL32(m_CountOfScopes);
60 m_CountOfVars = VAL32(m_CountOfVars);
61 m_CountOfUsing = VAL32(m_CountOfUsing);
62 m_CountOfConstants = VAL32(m_CountOfConstants);
63 m_CountOfSequencePoints = VAL32(m_CountOfSequencePoints);
64 m_CountOfDocuments = VAL32(m_CountOfDocuments);
65 m_CountOfBytes = VAL32(m_CountOfBytes);
66 m_CountOfStringBytes = VAL32(m_CountOfStringBytes);
69 void ConvertEndianness() {}
74 // The signature, Guid version + PDBInfo data
75 #define ILDB_HEADER_SIZE (ILDB_SIGNATURE_SIZE + sizeof(GUID) + sizeof(PDBInfo) )
77 typedef struct PDBDataPointers
79 SymMethodInfo * m_pMethods; // Method information
80 SymLexicalScope *m_pScopes; // Scopes
81 SymVariable *m_pVars; // Local Variables
82 SymUsingNamespace *m_pUsings; // list of using/imports
83 SymConstant *m_pConstants; // Constants
84 DocumentInfo *m_pDocuments; // Documents
85 SequencePoint *m_pSequencePoints; // Sequence Points
86 // Array of various bytes (variable signature, etc)
89 BYTE *m_pStringsBytes;
92 #endif /* PDBDATA_H_ */