[llvm] [DebugNames] Implement per-entry abbreviation support (PR #76731)

via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 2 08:08:36 PST 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff 80aeb622117f6411e65bff42be5231720e8b8cef 3c9ea1ef6120116e1e65e8518b672b4826a9f80b -- llvm/include/llvm/CodeGen/AccelTable.h llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp llvm/lib/DWARFLinker/DWARFStreamer.cpp llvm/lib/DWARFLinkerParallel/DWARFEmitterImpl.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp b/llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp
index 6d4959e9c7..0fbebc207a 100644
--- a/llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/AccelTable.cpp
@@ -281,9 +281,7 @@ struct AbbreviationContents {
 };
 
 struct AbbreviationContentsInfo {
-  static AbbreviationContents getEmptyKey() {
-    return AbbreviationContents(0);
-  };
+  static AbbreviationContents getEmptyKey() { return AbbreviationContents(0); };
   static AbbreviationContents getTombstoneKey() {
     return AbbreviationContents(~0);
   };
@@ -601,7 +599,8 @@ void Dwarf5AccelTableWriter::emitAbbrevs() const {
 void Dwarf5AccelTableWriter::emitEntry(
     const DWARF5AccelTableData &Entry) const {
   std::optional<DWARF5AccelTable::UnitIndex> EntryRet = getIndexForEntry(Entry);
-  auto AbbrevContents = constructAbbreviationContents(Entry.getDieTag(), EntryRet);
+  auto AbbrevContents =
+      constructAbbreviationContents(Entry.getDieTag(), EntryRet);
   assert(Abbreviations.contains(AbbrevContents) &&
          "Why wasn't this abbrev generated?");
   Asm->emitULEB128(AbbrevContents.getUniqueCode(), "Abbreviation code");

``````````

</details>


https://github.com/llvm/llvm-project/pull/76731


More information about the llvm-commits mailing list