[llvm] [PseudoProbe] use print to emit function name (PR #147873)
Haohai Wen via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 9 19:08:57 PDT 2025
https://github.com/HaohaiWen created https://github.com/llvm/llvm-project/pull/147873
This PR is part of #123870.
For COFF Asm, function name should be wrapped in quotes.
MCSymbol::print will automatically do that.
>From 23d2e950d5d525be80ae3f5add40b068651f45e9 Mon Sep 17 00:00:00 2001
From: Haohai Wen <haohai.wen at intel.com>
Date: Thu, 10 Jul 2025 10:00:15 +0800
Subject: [PATCH] [PseudoProbe] use print to emit function name
This PR is part of #123870.
For COFF Asm, function name should be wrapped in quotes.
MCSymbol::print will automatically do that.
---
llvm/lib/MC/MCAsmStreamer.cpp | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/llvm/lib/MC/MCAsmStreamer.cpp b/llvm/lib/MC/MCAsmStreamer.cpp
index aae02652564d3..7eaad409a2eda 100644
--- a/llvm/lib/MC/MCAsmStreamer.cpp
+++ b/llvm/lib/MC/MCAsmStreamer.cpp
@@ -2466,7 +2466,8 @@ void MCAsmStreamer::emitPseudoProbe(uint64_t Guid, uint64_t Index,
for (const auto &Site : InlineStack)
OS << " @ " << std::get<0>(Site) << ":" << std::get<1>(Site);
- OS << " " << FnSym->getName();
+ OS << " ";
+ FnSym->print(OS, MAI);
EmitEOL();
}
More information about the llvm-commits
mailing list