LLVM 22.0.0git
DebugSymbolsSubsection.h
Go to the documentation of this file.
1//===- DebugSymbolsSubsection.h --------------------------------*- 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_CODEVIEW_DEBUGSYMBOLSSUBSECTION_H
10#define LLVM_DEBUGINFO_CODEVIEW_DEBUGSYMBOLSSUBSECTION_H
11
15#include "llvm/Support/Error.h"
16
17namespace llvm {
18namespace codeview {
20public:
23
24 static bool classof(const DebugSubsectionRef *S) {
26 }
27
29
30 CVSymbolArray::Iterator begin() const { return Records.begin(); }
31 CVSymbolArray::Iterator end() const { return Records.end(); }
32
33private:
34 CVSymbolArray Records;
35};
36
38public:
40 static bool classof(const DebugSubsection *S) {
41 return S->kind() == DebugSubsectionKind::Symbols;
42 }
43
44 uint32_t calculateSerializedSize() const override;
45 Error commit(BinaryStreamWriter &Writer) const override;
46
47 void addSymbol(CVSymbol Symbol);
48
49private:
50 uint32_t Length = 0;
51 std::vector<CVSymbol> Records;
52};
53}
54}
55
56#endif
#define LLVM_ABI
Definition: Compiler.h:213
static void addSymbol(Object &Obj, const NewSymbolInfo &SymInfo, uint8_t DefaultVisibility)
Definition: ELFObjcopy.cpp:560
Provides read only access to a subclass of BinaryStream.
Provides write only access to a subclass of WritableBinaryStream.
Lightweight error class with error context and mandatory checking.
Definition: Error.h:159
VarStreamArray represents an array of variable length records backed by a stream.
Iterator end() const
Iterator begin(bool *HadError=nullptr) const
CVRecord is a fat pointer (base + size pair) to a symbol or type record.
Definition: CVRecord.h:29
DebugSubsectionKind kind() const
DebugSubsectionKind kind() const
static bool classof(const DebugSubsectionRef *S)
LLVM_ABI Error initialize(BinaryStreamReader Reader)
static bool classof(const DebugSubsection *S)
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
@ Length
Definition: DWP.cpp:477