Skip to content

[NFC][MemProf] Fix typo in type name #140500

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 19, 2025

Conversation

snehasish
Copy link
Contributor

No description provided.

@llvmbot llvmbot added the PGO Profile Guided Optimizations label May 19, 2025
@llvmbot
Copy link
Member

llvmbot commented May 19, 2025

@llvm/pr-subscribers-pgo

Author: Snehasish Kumar (snehasish)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/140500.diff

3 Files Affected:

  • (modified) llvm/include/llvm/ProfileData/MemProf.h (+7-7)
  • (modified) llvm/unittests/ProfileData/InstrProfTest.cpp (+3-3)
  • (modified) llvm/unittests/ProfileData/MemProfTest.cpp (+5-5)
diff --git a/llvm/include/llvm/ProfileData/MemProf.h b/llvm/include/llvm/ProfileData/MemProf.h
index 06d17438fa70f..e713c3807611b 100644
--- a/llvm/include/llvm/ProfileData/MemProf.h
+++ b/llvm/include/llvm/ProfileData/MemProf.h
@@ -1090,18 +1090,18 @@ struct IndexedMemProfData {
 
 // A convenience wrapper around FrameIdConverter and CallStackIdConverter for
 // tests.
-struct IndexedCallstackIdConveter {
-  IndexedCallstackIdConveter() = delete;
-  IndexedCallstackIdConveter(IndexedMemProfData &MemProfData)
+struct IndexedCallstackIdConverter {
+  IndexedCallstackIdConverter() = delete;
+  IndexedCallstackIdConverter(IndexedMemProfData &MemProfData)
       : FrameIdConv(MemProfData.Frames),
         CSIdConv(MemProfData.CallStacks, FrameIdConv) {}
 
   // Delete the copy constructor and copy assignment operator to avoid a
-  // situation where a copy of IndexedCallStackIdConverter gets an error in
+  // situation where a copy of IndexedCallstackIdConverter gets an error in
   // LastUnmappedId while the original instance doesn't.
-  IndexedCallstackIdConveter(const IndexedCallstackIdConveter &) = delete;
-  IndexedCallstackIdConveter &
-  operator=(const IndexedCallstackIdConveter &) = delete;
+  IndexedCallstackIdConverter(const IndexedCallstackIdConverter &) = delete;
+  IndexedCallstackIdConverter &
+  operator=(const IndexedCallstackIdConverter &) = delete;
 
   std::vector<Frame> operator()(CallStackId CSId) { return CSIdConv(CSId); }
 
diff --git a/llvm/unittests/ProfileData/InstrProfTest.cpp b/llvm/unittests/ProfileData/InstrProfTest.cpp
index 34b1187c0b842..a0bd41bccf928 100644
--- a/llvm/unittests/ProfileData/InstrProfTest.cpp
+++ b/llvm/unittests/ProfileData/InstrProfTest.cpp
@@ -457,7 +457,7 @@ TEST_F(InstrProfTest, test_memprof_v2_full_schema) {
   ASSERT_THAT_ERROR(RecordOr.takeError(), Succeeded());
   const memprof::MemProfRecord &Record = RecordOr.get();
 
-  memprof::IndexedCallstackIdConveter CSIdConv(MemProfData);
+  memprof::IndexedCallstackIdConverter CSIdConv(MemProfData);
 
   const ::llvm::memprof::MemProfRecord WantRecord =
       IndexedMR.toMemProfRecord(CSIdConv);
@@ -491,7 +491,7 @@ TEST_F(InstrProfTest, test_memprof_v2_partial_schema) {
   ASSERT_THAT_ERROR(RecordOr.takeError(), Succeeded());
   const memprof::MemProfRecord &Record = RecordOr.get();
 
-  memprof::IndexedCallstackIdConveter CSIdConv(MemProfData);
+  memprof::IndexedCallstackIdConverter CSIdConv(MemProfData);
 
   const ::llvm::memprof::MemProfRecord WantRecord =
       IndexedMR.toMemProfRecord(CSIdConv);
@@ -609,7 +609,7 @@ TEST_F(InstrProfTest, test_memprof_merge) {
 
   std::optional<memprof::FrameId> LastUnmappedFrameId;
 
-  memprof::IndexedCallstackIdConveter CSIdConv(MemProfData);
+  memprof::IndexedCallstackIdConverter CSIdConv(MemProfData);
 
   const ::llvm::memprof::MemProfRecord WantRecord =
       IndexedMR.toMemProfRecord(CSIdConv);
diff --git a/llvm/unittests/ProfileData/MemProfTest.cpp b/llvm/unittests/ProfileData/MemProfTest.cpp
index ea36727df1bee..b1937992ea7f4 100644
--- a/llvm/unittests/ProfileData/MemProfTest.cpp
+++ b/llvm/unittests/ProfileData/MemProfTest.cpp
@@ -554,7 +554,7 @@ TEST(MemProf, IndexedMemProfRecordToMemProfRecord) {
   IndexedRecord.CallSites.push_back(IndexedCallSiteInfo(CS3Id));
   IndexedRecord.CallSites.push_back(IndexedCallSiteInfo(CS4Id));
 
-  IndexedCallstackIdConveter CSIdConv(MemProfData);
+  IndexedCallstackIdConverter CSIdConv(MemProfData);
 
   MemProfRecord Record = IndexedRecord.toMemProfRecord(CSIdConv);
 
@@ -591,7 +591,7 @@ TEST(MemProf, MissingCallStackId) {
 
   // Create empty maps.
   IndexedMemProfData MemProfData;
-  IndexedCallstackIdConveter CSIdConv(MemProfData);
+  IndexedCallstackIdConverter CSIdConv(MemProfData);
 
   // We are only interested in errors, not the return value.
   (void)IndexedMR.toMemProfRecord(CSIdConv);
@@ -609,7 +609,7 @@ TEST(MemProf, MissingFrameId) {
   IndexedMemProfRecord IndexedMR;
   IndexedMR.AllocSites.emplace_back(CSId, makePartialMIB(), getHotColdSchema());
 
-  IndexedCallstackIdConveter CSIdConv(MemProfData);
+  IndexedCallstackIdConverter CSIdConv(MemProfData);
 
   // We are only interested in errors, not the return value.
   (void)IndexedMR.toMemProfRecord(CSIdConv);
@@ -763,7 +763,7 @@ TEST(MemProf, YAMLParser) {
   const auto &[GUID, IndexedRecord] = MemProfData.Records.front();
   EXPECT_EQ(GUID, 0xdeadbeef12345678ULL);
 
-  IndexedCallstackIdConveter CSIdConv(MemProfData);
+  IndexedCallstackIdConverter CSIdConv(MemProfData);
   MemProfRecord Record = IndexedRecord.toMemProfRecord(CSIdConv);
 
   ASSERT_THAT(Record.AllocSites, SizeIs(2));
@@ -814,7 +814,7 @@ TEST(MemProf, YAMLParserGUID) {
   const auto &[GUID, IndexedRecord] = MemProfData.Records.front();
   EXPECT_EQ(GUID, IndexedMemProfRecord::getGUID("_Z3fooi"));
 
-  IndexedCallstackIdConveter CSIdConv(MemProfData);
+  IndexedCallstackIdConverter CSIdConv(MemProfData);
   MemProfRecord Record = IndexedRecord.toMemProfRecord(CSIdConv);
 
   ASSERT_THAT(Record.AllocSites, SizeIs(1));

@snehasish snehasish changed the title Fix typo in type name [NFC][MemProf] Fix typo in type name May 19, 2025
Copy link
Contributor

@kazutakahirata kazutakahirata left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@snehasish snehasish force-pushed the users/snehasish/05-16-fix_typo_in_type_name branch from 52c8c48 to dbf627c Compare May 19, 2025 22:15
Copy link
Contributor Author

snehasish commented May 19, 2025

Merge activity

  • May 19, 7:09 PM EDT: A user started a stack merge that includes this pull request via Graphite.
  • May 19, 7:11 PM EDT: Graphite rebased this pull request as part of a merge.
  • May 19, 7:12 PM EDT: @snehasish merged this pull request with Graphite.

@snehasish snehasish force-pushed the users/snehasish/05-16-fix_typo_in_type_name branch from dbf627c to 785a2f7 Compare May 19, 2025 23:10
@snehasish snehasish merged commit 7268c4e into main May 19, 2025
6 of 9 checks passed
@snehasish snehasish deleted the users/snehasish/05-16-fix_typo_in_type_name branch May 19, 2025 23:13
sivan-shani pushed a commit to sivan-shani/llvm-project that referenced this pull request Jun 3, 2025
ajaden-codes pushed a commit to Jaddyen/llvm-project that referenced this pull request Jun 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PGO Profile Guided Optimizations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants