mirror of
https://github.com/RPCSX/llvm.git
synced 2026-01-31 01:05:23 +01:00
In preparation for introducing writing capabilities for each of these classes, I would like to adopt a Foo / FooRef naming convention, where Foo indicates that the class can manipulate and serialize Foos, and FooRef indicates that it is an immutable view of an existing Foo. In other words, Foo is a writer and FooRef is a reader. This patch names some existing readers to conform to the FooRef convention, while offering no functional change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@301810 91177308-0d34-0410-b5e6-96231b3b80d8
67 lines
1.8 KiB
C++
67 lines
1.8 KiB
C++
//===- ModuleDebugStream.h - PDB Module Info Stream Access ----------------===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#ifndef LLVM_DEBUGINFO_PDB_RAW_MODULEDEBUGSTREAM_H
|
|
#define LLVM_DEBUGINFO_PDB_RAW_MODULEDEBUGSTREAM_H
|
|
|
|
#include "llvm/ADT/iterator_range.h"
|
|
#include "llvm/DebugInfo/CodeView/CVRecord.h"
|
|
#include "llvm/DebugInfo/CodeView/ModuleDebugFragmentRecord.h"
|
|
#include "llvm/DebugInfo/CodeView/SymbolRecord.h"
|
|
#include "llvm/DebugInfo/MSF/MappedBlockStream.h"
|
|
#include "llvm/Support/BinaryStreamArray.h"
|
|
#include "llvm/Support/BinaryStreamRef.h"
|
|
#include "llvm/Support/Error.h"
|
|
|
|
namespace llvm {
|
|
namespace pdb {
|
|
class PDBFile;
|
|
class DbiModuleDescriptor;
|
|
|
|
class ModuleDebugStreamRef {
|
|
typedef codeview::ModuleDebugFragmentArray::Iterator
|
|
LinesAndChecksumsIterator;
|
|
|
|
public:
|
|
ModuleDebugStreamRef(const DbiModuleDescriptor &Module,
|
|
std::unique_ptr<msf::MappedBlockStream> Stream);
|
|
~ModuleDebugStreamRef();
|
|
|
|
Error reload();
|
|
|
|
uint32_t signature() const { return Signature; }
|
|
|
|
iterator_range<codeview::CVSymbolArray::Iterator>
|
|
symbols(bool *HadError) const;
|
|
|
|
llvm::iterator_range<LinesAndChecksumsIterator> linesAndChecksums() const;
|
|
|
|
bool hasLineInfo() const;
|
|
|
|
Error commit();
|
|
|
|
private:
|
|
const DbiModuleDescriptor &Mod;
|
|
|
|
uint32_t Signature;
|
|
|
|
std::unique_ptr<msf::MappedBlockStream> Stream;
|
|
|
|
codeview::CVSymbolArray SymbolsSubstream;
|
|
BinaryStreamRef C11LinesSubstream;
|
|
BinaryStreamRef C13LinesSubstream;
|
|
BinaryStreamRef GlobalRefsSubstream;
|
|
|
|
codeview::ModuleDebugFragmentArray LinesAndChecksums;
|
|
};
|
|
}
|
|
}
|
|
|
|
#endif
|