1 //===- RawConstants.h -------------------------------------------*- C++ -*-===//
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
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_DEBUGINFO_PDB_RAW_PDBRAWCONSTANTS_H
10 #define LLVM_DEBUGINFO_PDB_RAW_PDBRAWCONSTANTS_H
12 #include "llvm/ADT/BitmaskEnum.h"
13 #include "llvm/DebugInfo/CodeView/CodeView.h"
19 const uint16_t kInvalidStreamIndex
= 0xFFFF;
21 enum PdbRaw_ImplVer
: uint32_t {
22 PdbImplVC2
= 19941610,
23 PdbImplVC4
= 19950623,
24 PdbImplVC41
= 19950814,
25 PdbImplVC50
= 19960307,
26 PdbImplVC98
= 19970604,
27 PdbImplVC70Dep
= 19990604, // deprecated
28 PdbImplVC70
= 20000404,
29 PdbImplVC80
= 20030901,
30 PdbImplVC110
= 20091201,
31 PdbImplVC140
= 20140508,
34 enum class PdbRaw_SrcHeaderBlockVer
: uint32_t { SrcVerOne
= 19980827 };
36 enum class PdbRaw_FeatureSig
: uint32_t {
39 NoTypeMerge
= 0x4D544F4E,
40 MinimalDebugInfo
= 0x494E494D,
43 enum PdbRaw_Features
: uint32_t {
45 PdbFeatureContainsIdStream
= 0x1,
46 PdbFeatureMinimalDebugInfo
= 0x2,
47 PdbFeatureNoTypeMerging
= 0x4,
48 LLVM_MARK_AS_BITMASK_ENUM(/* LargestValue = */ PdbFeatureNoTypeMerging
)
51 enum PdbRaw_DbiVer
: uint32_t {
59 enum PdbRaw_TpiVer
: uint32_t {
67 enum PdbRaw_DbiSecContribVer
: uint32_t {
68 DbiSecContribVer60
= 0xeffe0000 + 19970605,
69 DbiSecContribV2
= 0xeffe0000 + 20140516
72 enum SpecialStream
: uint32_t {
73 // Stream 0 contains the copy of previous version of the MSF directory.
74 // We are not currently using it, but technically if we find the main
75 // MSF is corrupted, we could fallback to it.
86 enum class DbgHeaderType
: uint16_t {
101 enum class OMFSegDescFlags
: uint16_t {
103 Read
= 1 << 0, // Segment is readable.
104 Write
= 1 << 1, // Segment is writable.
105 Execute
= 1 << 2, // Segment is executable.
106 AddressIs32Bit
= 1 << 3, // Descriptor describes a 32-bit linear address.
107 IsSelector
= 1 << 8, // Frame represents a selector.
108 IsAbsoluteAddress
= 1 << 9, // Frame represents an absolute address.
109 IsGroup
= 1 << 10, // If set, descriptor represents a group.
110 LLVM_MARK_AS_BITMASK_ENUM(/* LargestValue = */ IsGroup
)
113 LLVM_ENABLE_BITMASK_ENUMS_IN_NAMESPACE();
115 } // end namespace pdb
116 } // end namespace llvm
118 #endif // LLVM_DEBUGINFO_PDB_RAW_PDBRAWCONSTANTS_H