Skip to content

Commit 377f507

Browse files
committed
[StackMaps] Remove format version from the class name [NFC]
Motivation is to reduce silly diffs when we change the format. For instance, this causes most of D59020 to disappear. llvm-svn: 358322
1 parent 7d46945 commit 377f507

File tree

4 files changed

+14
-13
lines changed

4 files changed

+14
-13
lines changed

llvm/include/llvm/Object/StackMapParser.h

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,9 @@
1919

2020
namespace llvm {
2121

22+
/// A parser for the latest stackmap format. At the moment, latest=V2.
2223
template <support::endianness Endianness>
23-
class StackMapV2Parser {
24+
class StackMapParser {
2425
public:
2526
template <typename AccessorT>
2627
class AccessorIterator {
@@ -49,7 +50,7 @@ class StackMapV2Parser {
4950

5051
/// Accessor for function records.
5152
class FunctionAccessor {
52-
friend class StackMapV2Parser;
53+
friend class StackMapParser;
5354

5455
public:
5556
/// Get the function address.
@@ -81,7 +82,7 @@ class StackMapV2Parser {
8182

8283
/// Accessor for constants.
8384
class ConstantAccessor {
84-
friend class StackMapV2Parser;
85+
friend class StackMapParser;
8586

8687
public:
8788
/// Return the value of this constant.
@@ -105,7 +106,7 @@ class StackMapV2Parser {
105106

106107
/// Accessor for location records.
107108
class LocationAccessor {
108-
friend class StackMapV2Parser;
109+
friend class StackMapParser;
109110
friend class RecordAccessor;
110111

111112
public:
@@ -164,7 +165,7 @@ class StackMapV2Parser {
164165

165166
/// Accessor for stackmap live-out fields.
166167
class LiveOutAccessor {
167-
friend class StackMapV2Parser;
168+
friend class StackMapParser;
168169
friend class RecordAccessor;
169170

170171
public:
@@ -195,7 +196,7 @@ class StackMapV2Parser {
195196

196197
/// Accessor for stackmap records.
197198
class RecordAccessor {
198-
friend class StackMapV2Parser;
199+
friend class StackMapParser;
199200

200201
public:
201202
using location_iterator = AccessorIterator<LocationAccessor>;
@@ -299,12 +300,12 @@ class StackMapV2Parser {
299300

300301
/// Construct a parser for a version-2 stackmap. StackMap data will be read
301302
/// from the given array.
302-
StackMapV2Parser(ArrayRef<uint8_t> StackMapSection)
303+
StackMapParser(ArrayRef<uint8_t> StackMapSection)
303304
: StackMapSection(StackMapSection) {
304305
ConstantsListOffset = FunctionListOffset + getNumFunctions() * FunctionSize;
305306

306307
assert(StackMapSection[0] == 2 &&
307-
"StackMapV2Parser can only parse version 2 stackmaps");
308+
"StackMapParser can only parse version 2 stackmaps");
308309

309310
unsigned CurrentRecordOffset =
310311
ConstantsListOffset + getNumConstants() * ConstantSize;

llvm/tools/llvm-readobj/COFFDumper.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1867,10 +1867,10 @@ void COFFDumper::printStackMap() const {
18671867

18681868
if (Obj->isLittleEndian())
18691869
prettyPrintStackMap(
1870-
W, StackMapV2Parser<support::little>(StackMapContentsArray));
1870+
W, StackMapParser<support::little>(StackMapContentsArray));
18711871
else
18721872
prettyPrintStackMap(W,
1873-
StackMapV2Parser<support::big>(StackMapContentsArray));
1873+
StackMapParser<support::big>(StackMapContentsArray));
18741874
}
18751875

18761876
void COFFDumper::printAddrsig() {

llvm/tools/llvm-readobj/ELFDumper.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2407,7 +2407,7 @@ template <class ELFT> void ELFDumper<ELFT>::printStackMap() const {
24072407
unwrapOrError(Obj->getSectionContents(StackMapSection));
24082408

24092409
prettyPrintStackMap(
2410-
W, StackMapV2Parser<ELFT::TargetEndianness>(StackMapContentsArray));
2410+
W, StackMapParser<ELFT::TargetEndianness>(StackMapContentsArray));
24112411
}
24122412

24132413
template <class ELFT> void ELFDumper<ELFT>::printGroupSections() {

llvm/tools/llvm-readobj/MachODumper.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -667,10 +667,10 @@ void MachODumper::printStackMap() const {
667667

668668
if (Obj->isLittleEndian())
669669
prettyPrintStackMap(
670-
W, StackMapV2Parser<support::little>(StackMapContentsArray));
670+
W, StackMapParser<support::little>(StackMapContentsArray));
671671
else
672672
prettyPrintStackMap(W,
673-
StackMapV2Parser<support::big>(StackMapContentsArray));
673+
StackMapParser<support::big>(StackMapContentsArray));
674674
}
675675

676676
void MachODumper::printNeededLibraries() {

0 commit comments

Comments
 (0)