[llvm] e9c8514 - [MC] Remove unnecessary isVerboseAsm from createAsmTargetStreamer
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Sun Jul 21 10:33:55 PDT 2024
Author: Fangrui Song
Date: 2024-07-21T10:33:50-07:00
New Revision: e9c851484bfeb270368bc71e9d7a4bec986f91e7
URL: https://github.com/llvm/llvm-project/commit/e9c851484bfeb270368bc71e9d7a4bec986f91e7
DIFF: https://github.com/llvm/llvm-project/commit/e9c851484bfeb270368bc71e9d7a4bec986f91e7.diff
LOG: [MC] Remove unnecessary isVerboseAsm from createAsmTargetStreamer
Added:
Modified:
llvm/include/llvm/MC/TargetRegistry.h
llvm/lib/MC/TargetRegistry.cpp
llvm/tools/llvm-exegesis/lib/SnippetFile.cpp
llvm/tools/llvm-mca/CodeRegionGenerator.cpp
Removed:
################################################################################
diff --git a/llvm/include/llvm/MC/TargetRegistry.h b/llvm/include/llvm/MC/TargetRegistry.h
index fdfbfb45bf86d..42d510c17bce3 100644
--- a/llvm/include/llvm/MC/TargetRegistry.h
+++ b/llvm/include/llvm/MC/TargetRegistry.h
@@ -552,8 +552,7 @@ class Target {
MCTargetStreamer *createAsmTargetStreamer(MCStreamer &S,
formatted_raw_ostream &OS,
- MCInstPrinter *InstPrint,
- bool IsVerboseAsm) const {
+ MCInstPrinter *InstPrint) const {
if (AsmTargetStreamerCtorFn)
return AsmTargetStreamerCtorFn(S, OS, InstPrint);
return nullptr;
diff --git a/llvm/lib/MC/TargetRegistry.cpp b/llvm/lib/MC/TargetRegistry.cpp
index b6b1a9b2eda9e..3be6f1d463499 100644
--- a/llvm/lib/MC/TargetRegistry.cpp
+++ b/llvm/lib/MC/TargetRegistry.cpp
@@ -95,7 +95,7 @@ MCStreamer *Target::createAsmStreamer(MCContext &Ctx,
formatted_raw_ostream &OSRef = *OS;
MCStreamer *S = llvm::createAsmStreamer(Ctx, std::move(OS), IP,
std::move(CE), std::move(TAB));
- createAsmTargetStreamer(*S, OSRef, IP, /*ignore=*/false);
+ createAsmTargetStreamer(*S, OSRef, IP);
return S;
}
diff --git a/llvm/tools/llvm-exegesis/lib/SnippetFile.cpp b/llvm/tools/llvm-exegesis/lib/SnippetFile.cpp
index 431d99c72b808..08da04cc62d9c 100644
--- a/llvm/tools/llvm-exegesis/lib/SnippetFile.cpp
+++ b/llvm/tools/llvm-exegesis/lib/SnippetFile.cpp
@@ -260,8 +260,7 @@ Expected<std::vector<BenchmarkCode>> readSnippets(const LLVMState &State,
*TM.getMCAsmInfo(), *TM.getMCInstrInfo(), *TM.getMCRegisterInfo()));
// The following call will take care of calling Streamer.setTargetStreamer.
TM.getTarget().createAsmTargetStreamer(Streamer, InstPrinterOStream,
- InstPrinter.get(),
- TM.Options.MCOptions.AsmVerbose);
+ InstPrinter.get());
if (!Streamer.getTargetStreamer())
return make_error<Failure>("cannot create target asm streamer");
diff --git a/llvm/tools/llvm-mca/CodeRegionGenerator.cpp b/llvm/tools/llvm-mca/CodeRegionGenerator.cpp
index 863766cd777d0..d9b8c6edb0ec9 100644
--- a/llvm/tools/llvm-mca/CodeRegionGenerator.cpp
+++ b/llvm/tools/llvm-mca/CodeRegionGenerator.cpp
@@ -41,8 +41,7 @@ Expected<const CodeRegions &> AsmCodeRegionGenerator::parseCodeRegions(
// doesn't show up in the llvm-mca output.
raw_ostream &OSRef = nulls();
formatted_raw_ostream FOSRef(OSRef);
- TheTarget.createAsmTargetStreamer(*Str, FOSRef, IP.get(),
- /*IsVerboseAsm=*/true);
+ TheTarget.createAsmTargetStreamer(*Str, FOSRef, IP.get());
// Create a MCAsmParser and setup the lexer to recognize llvm-mca ASM
// comments.
More information about the llvm-commits
mailing list