LLVM  9.0.0svn
PDBExtras.h
Go to the documentation of this file.
1 //===- PDBExtras.h - helper functions and classes for PDBs ------*- C++ -*-===//
2 //
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
6 //
7 //===----------------------------------------------------------------------===//
8 
9 #ifndef LLVM_DEBUGINFO_PDB_PDBEXTRAS_H
10 #define LLVM_DEBUGINFO_PDB_PDBEXTRAS_H
11 
15 
16 #include <unordered_map>
17 
18 namespace llvm {
19 
20 class raw_ostream;
21 
22 namespace pdb {
23 
24 using TagStats = std::unordered_map<PDB_SymType, int>;
25 
31  const llvm::codeview::CPURegister &CpuReg);
34 raw_ostream &operator<<(raw_ostream &OS, const PDB_Checksum &Checksum);
35 raw_ostream &operator<<(raw_ostream &OS, const PDB_Lang &Lang);
41  const PDB_SourceCompression &Compression);
42 
46 
47 
48 template <typename T>
49 void dumpSymbolField(raw_ostream &OS, StringRef Name, T Value, int Indent) {
50  OS << "\n";
51  OS.indent(Indent);
52  OS << Name << ": " << Value;
53 }
54 
55 
56 } // end namespace pdb
57 
58 } // end namespace llvm
59 
60 #endif // LLVM_DEBUGINFO_PDB_PDBEXTRAS_H
This class represents lattice values for constants.
Definition: AllocatorList.h:23
amdgpu Simplify well known AMD library false FunctionCallee Value const Twine & Name
PDB_UdtType
These values correspond to the UdtKind enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/wcstk66t.aspx.
Definition: PDBTypes.h:250
raw_ostream & indent(unsigned NumSpaces)
indent - Insert &#39;NumSpaces&#39; spaces.
PDB_Checksum
Specifies the hash algorithm that a source file from a PDB was hashed with.
Definition: PDBTypes.h:117
raw_ostream & operator<<(raw_ostream &OS, const PDB_VariantType &Value)
Definition: PDBExtras.cpp:24
std::unordered_map< PDB_SymType, int > TagStats
Definition: PDBExtras.h:24
block placement Basic Block Placement Stats
COFF::MachineTypes Machine
Definition: COFFYAML.cpp:365
PDB_SymType
These values correspond to the SymTagEnum enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/bkedss5f.aspx.
Definition: PDBTypes.h:183
The instances of the Type class are immutable: once they are created, they are never changed...
Definition: Type.h:45
PDB_DataKind
These values correspond to the DataKind enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/b2x2t313.aspx.
Definition: PDBTypes.h:168
void dumpSymbolField(raw_ostream &OS, StringRef Name, T Value, int Indent)
Definition: PDBExtras.h:49
PDB_SourceCompression
Definition: PDBTypes.h:149
PDB_LocType
These values correspond to the LocationType enumeration, and are documented here: https://msdn...
Definition: PDBTypes.h:232
SourceLanguage
These values correspond to the CV_CFL_LANG enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/bw3aekw6.aspx.
Definition: CodeView.h:143
PDB_VariantType
Definition: PDBTypes.h:333
ThunkOrdinal
These values correspond to the THUNK_ORDINAL enumeration.
Definition: CodeView.h:545
PDB_BuiltinType
These values correspond to the Basictype enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/4szdtzc3.aspx.
Definition: PDBTypes.h:275
LLVM Value Representation.
Definition: Value.h:72
CallingConvention
These values correspond to the CV_call_e enumeration, and are documented at the following locations: ...
Definition: CodeView.h:173
This class implements an extremely fast bulk output stream that can only output to a stream...
Definition: raw_ostream.h:45
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:48
const uint64_t Version
Definition: InstrProf.h:984
PDB_MemberAccess
Definition: PDBTypes.h:324