[llvm] [GISel] Don't print the opcode twice in LegalityQuery::print. (PR #74232)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Sun Dec 3 00:25:53 PST 2023
https://github.com/topperc created https://github.com/llvm/llvm-project/pull/74232
None
>From 5badd7f3d64f1d75f8ebc9a4f2cf565d340651e3 Mon Sep 17 00:00:00 2001
From: Craig Topper <craig.topper at sifive.com>
Date: Sun, 3 Dec 2023 00:25:08 -0800
Subject: [PATCH] [GISel] Don't print the opcode twice in LegalityQuery::print.
---
llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp b/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
index 9b5f3a4b6fa1d..de9931d1c240f 100644
--- a/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
+++ b/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
@@ -77,13 +77,11 @@ raw_ostream &llvm::operator<<(raw_ostream &OS, LegalizeAction Action) {
}
raw_ostream &LegalityQuery::print(raw_ostream &OS) const {
- OS << Opcode << ", Tys={";
+ OS << "Opcode=" << Opcode << ", Tys={";
for (const auto &Type : Types) {
OS << Type << ", ";
}
- OS << "}, Opcode=";
-
- OS << Opcode << ", MMOs={";
+ OS << "}, MMOs={";
for (const auto &MMODescr : MMODescrs) {
OS << MMODescr.MemoryTy << ", ";
}
More information about the llvm-commits
mailing list