[PATCH] D113825: [llvm-readobj][XCOFF] dump auxiliary symbols.

Xing GUO via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 24 03:19:01 PST 2021


Higuoxing added inline comments.


================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:375-379
+struct XCOFFBlockAuxEnt32 {
+  uint8_t ReservedZeros_1[2];
+  support::ubig16_t LineNum_Hi;
+  support::ubig16_t LineNum_Lo;
+  uint8_t ReservedZeros_2[12];
----------------
It looks that the variables' name are not consistent across this file? Is there any particular reason for that? e.g., Why use `ReservedZeros_1` instead of `ReservedZeros1` and `LineNum_Hi` instead of `LineNumLo`?


================
Comment at: llvm/test/tools/llvm-readobj/XCOFF/symbols-invalid.test:63-66
+# CASE8-NEXT: 00000000 00000001 00020300 00000000
+# CASE8-NEXT: 00fb
+# CASE8-NEXT:   }
+# CASE8-NEXT: ]
----------------
Looks that the indention is broken here?


================
Comment at: llvm/tools/llvm-readobj/XCOFFDumper.cpp:333-334
+                Obj.getSymbolIndex(reinterpret_cast<uintptr_t>(AuxEntPtr)));
+  W.printHex("LineNumber(High 2 Bytes)", AuxEntPtr->LineNum_Hi);
+  W.printHex("LineNumber(Low 2 Bytes)", AuxEntPtr->LineNum_Lo);
+}
----------------
Nit: insert a blank space between the field name and the parenthesis.


================
Comment at: llvm/tools/llvm-readobj/XCOFFDumper.cpp:350
+void XCOFFDumper::printSectAuxEntForDWARF(const T *AuxEntPtr) {
+
+  DictScope SymDs(W, "Sect Auxiliary Entry For DWARF");
----------------
Nit: blank line.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D113825/new/

https://reviews.llvm.org/D113825



More information about the llvm-commits mailing list