LLVM  10.0.0svn
CodeViewYAMLDebugSections.h
Go to the documentation of this file.
1 //=- CodeViewYAMLDebugSections.h - CodeView YAMLIO debug sections -*- 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 // This file defines classes for handling the YAML representation of CodeView
10 // Debug Info.
11 //
12 //===----------------------------------------------------------------------===//
13 
14 #ifndef LLVM_OBJECTYAML_CODEVIEWYAMLDEBUGSECTIONS_H
15 #define LLVM_OBJECTYAML_CODEVIEWYAMLDEBUGSECTIONS_H
16 
17 #include "llvm/ADT/ArrayRef.h"
18 #include "llvm/ADT/StringRef.h"
22 #include "llvm/Support/Error.h"
24 #include <cstdint>
25 #include <memory>
26 #include <vector>
27 
28 namespace llvm {
29 
30 namespace codeview {
31 
32 class StringsAndChecksums;
33 class StringsAndChecksumsRef;
34 
35 } // end namespace codeview
36 
37 namespace CodeViewYAML {
38 
39 namespace detail {
40 
41 struct YAMLSubsectionBase;
42 
43 } // end namespace detail
44 
45 struct YAMLFrameData {
55 };
56 
59  std::vector<uint32_t> ImportIds;
60 };
61 
67 };
68 
70  uint16_t StartColumn;
71  uint16_t EndColumn;
72 };
73 
76  std::vector<SourceLineEntry> Lines;
77  std::vector<SourceColumnEntry> Columns;
78 };
79 
81  std::vector<uint8_t> Bytes;
82 };
83 
88 };
89 
95  std::vector<SourceLineBlock> Blocks;
96 };
97 
98 struct InlineeSite {
102  std::vector<StringRef> ExtraFiles;
103 };
104 
105 struct InlineeInfo {
107  std::vector<InlineeSite> Sites;
108 };
109 
112  fromCodeViewSubection(const codeview::StringsAndChecksumsRef &SC,
114 
115  std::shared_ptr<detail::YAMLSubsectionBase> Subsection;
116 };
117 
119 
122  ArrayRef<YAMLDebugSubsection> Subsections,
124 
125 std::vector<YAMLDebugSubsection>
127 
130 
131 } // end namespace CodeViewYAML
132 
133 } // end namespace llvm
134 
135 LLVM_YAML_DECLARE_MAPPING_TRAITS(CodeViewYAML::YAMLDebugSubsection)
136 
137 LLVM_YAML_IS_SEQUENCE_VECTOR(CodeViewYAML::YAMLDebugSubsection)
138 
139 #endif // LLVM_OBJECTYAML_CODEVIEWYAMLDEBUGSECTIONS_H
std::vector< SourceLineEntry > Lines
This class represents lattice values for constants.
Definition: AllocatorList.h:23
std::vector< YAMLDebugSubsection > fromDebugS(ArrayRef< uint8_t > Data, const codeview::StringsAndChecksumsRef &SC)
Tagged union holding either a T or a Error.
Definition: CachePruning.h:22
void initializeStringsAndChecksums(ArrayRef< YAMLDebugSubsection > Sections, codeview::StringsAndChecksums &SC)
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory)...
Definition: APInt.h:32
Allocate memory in an ever growing pool, as if by bump-pointer.
Definition: Allocator.h:140
std::vector< SourceLineBlock > Blocks
std::vector< SourceColumnEntry > Columns
Basic Register Allocator
CHAIN = SC CHAIN, Imm128 - System call.
std::shared_ptr< detail::YAMLSubsectionBase > Subsection
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:48
Expected< std::vector< std::shared_ptr< codeview::DebugSubsection > > > toCodeViewSubsectionList(BumpPtrAllocator &Allocator, ArrayRef< YAMLDebugSubsection > Subsections, const codeview::StringsAndChecksums &SC)