summaryrefslogtreecommitdiffstats
path: root/llvm/lib/DebugInfo/PDB/Native
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/DebugInfo/PDB/Native')
-rw-r--r--llvm/lib/DebugInfo/PDB/Native/DbiModuleList.cpp11
-rw-r--r--llvm/lib/DebugInfo/PDB/Native/Hash.cpp2
-rw-r--r--llvm/lib/DebugInfo/PDB/Native/HashTable.cpp16
-rw-r--r--llvm/lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp6
-rw-r--r--llvm/lib/DebugInfo/PDB/Native/ModuleDebugStreamBuilder.cpp0
-rw-r--r--llvm/lib/DebugInfo/PDB/Native/NamedStreamMap.cpp9
-rw-r--r--llvm/lib/DebugInfo/PDB/Native/NativeRawSymbol.cpp29
7 files changed, 40 insertions, 33 deletions
diff --git a/llvm/lib/DebugInfo/PDB/Native/DbiModuleList.cpp b/llvm/lib/DebugInfo/PDB/Native/DbiModuleList.cpp
index 434f775097e..eea70b229c6 100644
--- a/llvm/lib/DebugInfo/PDB/Native/DbiModuleList.cpp
+++ b/llvm/lib/DebugInfo/PDB/Native/DbiModuleList.cpp
@@ -1,4 +1,4 @@
-//===- DbiModuleList.cpp - PDB module information list ----------*- C++ -*-===//
+//===- DbiModuleList.cpp - PDB module information list --------------------===//
//
// The LLVM Compiler Infrastructure
//
@@ -6,10 +6,17 @@
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
-#include "llvm/DebugInfo/PDB/Native/DbiModuleList.h"
+#include "llvm/DebugInfo/PDB/Native/DbiModuleList.h"
+#include "llvm/ADT/StringRef.h"
+#include "llvm/ADT/iterator_range.h"
#include "llvm/DebugInfo/PDB/Native/RawError.h"
+#include "llvm/Support/BinaryStreamReader.h"
#include "llvm/Support/Error.h"
+#include <algorithm>
+#include <cassert>
+#include <cstddef>
+#include <cstdint>
using namespace llvm;
using namespace llvm::pdb;
diff --git a/llvm/lib/DebugInfo/PDB/Native/Hash.cpp b/llvm/lib/DebugInfo/PDB/Native/Hash.cpp
index 2ad3f55dc5c..61188ece2dc 100644
--- a/llvm/lib/DebugInfo/PDB/Native/Hash.cpp
+++ b/llvm/lib/DebugInfo/PDB/Native/Hash.cpp
@@ -8,10 +8,10 @@
//===----------------------------------------------------------------------===//
#include "llvm/DebugInfo/PDB/Native/Hash.h"
-
#include "llvm/ADT/ArrayRef.h"
#include "llvm/Support/Endian.h"
#include "llvm/Support/JamCRC.h"
+#include <cstdint>
using namespace llvm;
using namespace llvm::support;
diff --git a/llvm/lib/DebugInfo/PDB/Native/HashTable.cpp b/llvm/lib/DebugInfo/PDB/Native/HashTable.cpp
index ebf8c9c04db..439217f91d0 100644
--- a/llvm/lib/DebugInfo/PDB/Native/HashTable.cpp
+++ b/llvm/lib/DebugInfo/PDB/Native/HashTable.cpp
@@ -1,4 +1,4 @@
-//===- HashTable.cpp - PDB Hash Table ---------------------------*- C++ -*-===//
+//===- HashTable.cpp - PDB Hash Table -------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
@@ -8,12 +8,16 @@
//===----------------------------------------------------------------------===//
#include "llvm/DebugInfo/PDB/Native/HashTable.h"
-
#include "llvm/ADT/Optional.h"
-#include "llvm/ADT/SparseBitVector.h"
#include "llvm/DebugInfo/PDB/Native/RawError.h"
-
-#include <assert.h>
+#include "llvm/Support/BinaryStreamReader.h"
+#include "llvm/Support/BinaryStreamWriter.h"
+#include "llvm/Support/Error.h"
+#include "llvm/Support/MathExtras.h"
+#include <algorithm>
+#include <cassert>
+#include <cstdint>
+#include <utility>
using namespace llvm;
using namespace llvm::pdb;
@@ -106,9 +110,11 @@ void HashTable::clear() {
}
uint32_t HashTable::capacity() const { return Buckets.size(); }
+
uint32_t HashTable::size() const { return Present.count(); }
HashTableIterator HashTable::begin() const { return HashTableIterator(*this); }
+
HashTableIterator HashTable::end() const {
return HashTableIterator(*this, 0, true);
}
diff --git a/llvm/lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp b/llvm/lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp
index 83c56574a16..2e1f61c7a25 100644
--- a/llvm/lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp
+++ b/llvm/lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp
@@ -9,11 +9,11 @@
#include "llvm/DebugInfo/PDB/Native/ModuleDebugStream.h"
#include "llvm/ADT/iterator_range.h"
+#include "llvm/DebugInfo/CodeView/CodeView.h"
+#include "llvm/DebugInfo/CodeView/DebugChecksumsSubsection.h"
#include "llvm/DebugInfo/CodeView/SymbolRecord.h"
#include "llvm/DebugInfo/PDB/Native/DbiModuleDescriptor.h"
-#include "llvm/DebugInfo/PDB/Native/PDBFile.h"
#include "llvm/DebugInfo/PDB/Native/RawError.h"
-#include "llvm/DebugInfo/PDB/Native/RawTypes.h"
#include "llvm/Support/BinaryStreamReader.h"
#include "llvm/Support/BinaryStreamRef.h"
#include "llvm/Support/Error.h"
@@ -97,7 +97,7 @@ ModuleDebugStreamRef::symbols(bool *HadError) const {
return make_range(SymbolArray.begin(HadError), SymbolArray.end());
}
-llvm::iterator_range<ModuleDebugStreamRef::DebugSubsectionIterator>
+iterator_range<ModuleDebugStreamRef::DebugSubsectionIterator>
ModuleDebugStreamRef::subsections() const {
return make_range(Subsections.begin(), Subsections.end());
}
diff --git a/llvm/lib/DebugInfo/PDB/Native/ModuleDebugStreamBuilder.cpp b/llvm/lib/DebugInfo/PDB/Native/ModuleDebugStreamBuilder.cpp
deleted file mode 100644
index e69de29bb2d..00000000000
--- a/llvm/lib/DebugInfo/PDB/Native/ModuleDebugStreamBuilder.cpp
+++ /dev/null
diff --git a/llvm/lib/DebugInfo/PDB/Native/NamedStreamMap.cpp b/llvm/lib/DebugInfo/PDB/Native/NamedStreamMap.cpp
index 4f90cd9cd8a..354b8c0e07f 100644
--- a/llvm/lib/DebugInfo/PDB/Native/NamedStreamMap.cpp
+++ b/llvm/lib/DebugInfo/PDB/Native/NamedStreamMap.cpp
@@ -1,4 +1,4 @@
-//===- NamedStreamMap.cpp - PDB Named Stream Map ----------------*- C++ -*-===//
+//===- NamedStreamMap.cpp - PDB Named Stream Map --------------------------===//
//
// The LLVM Compiler Infrastructure
//
@@ -8,17 +8,20 @@
//===----------------------------------------------------------------------===//
#include "llvm/DebugInfo/PDB/Native/NamedStreamMap.h"
-
-#include "llvm/ADT/SparseBitVector.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/iterator_range.h"
#include "llvm/DebugInfo/PDB/Native/HashTable.h"
#include "llvm/DebugInfo/PDB/Native/RawError.h"
#include "llvm/Support/BinaryStreamReader.h"
+#include "llvm/Support/BinaryStreamRef.h"
+#include "llvm/Support/BinaryStreamWriter.h"
+#include "llvm/Support/Endian.h"
#include "llvm/Support/Error.h"
#include <algorithm>
+#include <cassert>
#include <cstdint>
+#include <tuple>
using namespace llvm;
using namespace llvm::pdb;
diff --git a/llvm/lib/DebugInfo/PDB/Native/NativeRawSymbol.cpp b/llvm/lib/DebugInfo/PDB/Native/NativeRawSymbol.cpp
index ed6db63edba..b4f5c96ce66 100644
--- a/llvm/lib/DebugInfo/PDB/Native/NativeRawSymbol.cpp
+++ b/llvm/lib/DebugInfo/PDB/Native/NativeRawSymbol.cpp
@@ -1,4 +1,4 @@
-//===- NativeRawSymbol.cpp - Native implementation of IPDBRawSymbol -*- C++ -*-===//
+//===- NativeRawSymbol.cpp - Native implementation of IPDBRawSymbol -------===//
//
// The LLVM Compiler Infrastructure
//
@@ -8,16 +8,7 @@
//===----------------------------------------------------------------------===//
#include "llvm/DebugInfo/PDB/Native/NativeRawSymbol.h"
-#include "llvm/ADT/ArrayRef.h"
-#include "llvm/ADT/STLExtras.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/Native/NativeSession.h"
-#include "llvm/DebugInfo/PDB/PDBExtras.h"
#include "llvm/DebugInfo/PDB/PDBSymbolTypeBuiltin.h"
-#include "llvm/DebugInfo/PDB/PDBSymbolTypeVTable.h"
-#include "llvm/DebugInfo/PDB/PDBSymbolTypeVTableShape.h"
-#include "llvm/Support/ConvertUTF.h"
-#include "llvm/Support/raw_ostream.h"
using namespace llvm;
using namespace llvm::pdb;
@@ -49,7 +40,7 @@ NativeRawSymbol::findInlineFramesByRVA(uint32_t RVA) const {
return nullptr;
}
-void NativeRawSymbol::getDataBytes(llvm::SmallVector<uint8_t, 32> &bytes) const {
+void NativeRawSymbol::getDataBytes(SmallVector<uint8_t, 32> &bytes) const {
bytes.clear();
}
@@ -109,7 +100,7 @@ uint32_t NativeRawSymbol::getClassParentId() const {
}
std::string NativeRawSymbol::getCompilerName() const {
- return 0;
+ return {};
}
uint32_t NativeRawSymbol::getCount() const {
@@ -136,7 +127,7 @@ uint32_t NativeRawSymbol::getLexicalParentId() const {
}
std::string NativeRawSymbol::getLibraryName() const {
- return "";
+ return {};
}
uint32_t NativeRawSymbol::getLiveRangeStartAddressOffset() const {
@@ -164,7 +155,7 @@ uint32_t NativeRawSymbol::getMemorySpaceKind() const {
}
std::string NativeRawSymbol::getName() const {
- return 0;
+ return {};
}
uint32_t NativeRawSymbol::getNumberOfAcceleratorPointerTags() const {
@@ -188,7 +179,7 @@ uint32_t NativeRawSymbol::getNumberOfRows() const {
}
std::string NativeRawSymbol::getObjectFileName() const {
- return "";
+ return {};
}
uint32_t NativeRawSymbol::getOemId() const {
@@ -240,7 +231,7 @@ uint32_t NativeRawSymbol::getSlot() const {
}
std::string NativeRawSymbol::getSourceFileName() const {
- return 0;
+ return {};
}
uint32_t NativeRawSymbol::getStride() const {
@@ -251,7 +242,7 @@ uint32_t NativeRawSymbol::getSubTypeId() const {
return 0;
}
-std::string NativeRawSymbol::getSymbolsFileName() const { return ""; }
+std::string NativeRawSymbol::getSymbolsFileName() const { return {}; }
uint32_t NativeRawSymbol::getSymIndexId() const { return SymbolId; }
@@ -292,7 +283,7 @@ uint32_t NativeRawSymbol::getUavSlot() const {
}
std::string NativeRawSymbol::getUndecoratedName() const {
- return 0;
+ return {};
}
uint32_t NativeRawSymbol::getUnmodifiedTypeId() const {
@@ -701,5 +692,5 @@ bool NativeRawSymbol::wasInlined() const {
}
std::string NativeRawSymbol::getUnused() const {
- return "";
+ return {};
}
OpenPOWER on IntegriCloud