[llvm] [GISel] Don't print the opcode twice in LegalityQuery::print. (PR #74232)
via llvm-commits
llvm-commits at lists.llvm.org
Sun Dec 3 00:26:23 PST 2023
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-llvm-globalisel
Author: Craig Topper (topperc)
<details>
<summary>Changes</summary>
---
Full diff: https://github.com/llvm/llvm-project/pull/74232.diff
1 Files Affected:
- (modified) llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp (+2-4)
``````````diff
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 << ", ";
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/74232
More information about the llvm-commits
mailing list