[llvm] [NFC][MIRPrinter] Use `std::move` to avoid copy (PR #157832)
Abhishek Kaushik via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 10 04:02:25 PDT 2025
https://github.com/abhishek-kaushik22 created https://github.com/llvm/llvm-project/pull/157832
None
>From ab36bac54911d503913d2b203a6b2245794708b8 Mon Sep 17 00:00:00 2001
From: Abhishek Kaushik <abhishek.kaushik at intel.com>
Date: Wed, 10 Sep 2025 15:54:11 +0530
Subject: [PATCH] [NFC][MIRPrinter] Use `std::move` to avoid copy
---
llvm/lib/CodeGen/MIRPrinter.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llvm/lib/CodeGen/MIRPrinter.cpp b/llvm/lib/CodeGen/MIRPrinter.cpp
index 7cc91925793a1..91a21a4adf4eb 100644
--- a/llvm/lib/CodeGen/MIRPrinter.cpp
+++ b/llvm/lib/CodeGen/MIRPrinter.cpp
@@ -627,7 +627,7 @@ convertSRPoints(ModuleSlotTracker &MST,
StrOS << printMBBReference(*MBB);
Entry.Point = StrOS.str().str();
Str.clear();
- YamlSRPoints.push_back(Entry);
+ YamlSRPoints.push_back(std::move(Entry));
}
}
More information about the llvm-commits
mailing list