[llvm] [llvm-readelf] Add --extra-sym-info (PR #65580)
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 8 20:19:48 PDT 2023
================
@@ -52,19 +54,44 @@
# SYMBOLS-LLVM-NEXT: Other: 0
# SYMBOLS-LLVM-NEXT: Section: Undefined (0x0)
# SYMBOLS-LLVM-NEXT: }
+# SYMBOLS-LLVM-NEXT: Symbol {
+# SYMBOLS-LLVM-NEXT: Name: data (9)
+# SYMBOLS-LLVM-NEXT: Value: 0x3
+# SYMBOLS-LLVM-NEXT: Size: 0
+# SYMBOLS-LLVM-NEXT: Binding: Global (0x1)
+# SYMBOLS-LLVM-NEXT: Type: None (0x0)
+# SYMBOLS-LLVM-NEXT: Other: 0
+# SYMBOLS-LLVM-NEXT: Section: .data (0x2)
+# SYMBOLS-LLVM-NEXT: }
# SYMBOLS-LLVM-NEXT:]
-# SYMBOLS-GNU64:Symbol table '.symtab' contains 3 entries:
+# SYMBOLS-GNU64:Symbol table '.symtab' contains 4 entries:
# SYMBOLS-GNU64-NEXT: Num: Value Size Type Bind Vis Ndx Name
# SYMBOLS-GNU64-NEXT: 0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND
-# SYMBOLS-GNU64-NEXT: 1: 0000000000000001 0 NOTYPE LOCAL DEFAULT UND foo
+# SYMBOLS-GNU64-NEXT: 1: 0000000000000001 0 NOTYPE LOCAL DEFAULT 1 foo
# SYMBOLS-GNU64-NEXT: 2: 0000000000000002 0 NOTYPE LOCAL DEFAULT UND bar
+# SYMBOLS-GNU64-NEXT: 3: 0000000000000003 0 NOTYPE GLOBAL DEFAULT 2 data
-# SYMBOLS-GNU32:Symbol table '.symtab' contains 3 entries:
+# SYMBOLS-GNU64X:Symbol table '.symtab' contains 4 entries:
+#SYMBOLS-GNU64X-NEXT: Num: Value Size Type Bind Vis+Other Ndx(SecName) Name [+ Version Info]
+#SYMBOLS-GNU64X-NEXT: 0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND
+#SYMBOLS-GNU64X-NEXT: 1: 0000000000000001 0 NOTYPE LOCAL DEFAULT 1 (.text) foo
+#SYMBOLS-GNU64X-NEXT: 2: 0000000000000002 0 NOTYPE LOCAL DEFAULT UND bar
+#SYMBOLS-GNU64X-NEXT: 3: 0000000000000003 0 NOTYPE GLOBAL DEFAULT 2 (.data) data
+
+# SYMBOLS-GNU32:Symbol table '.symtab' contains 4 entries:
# SYMBOLS-GNU32-NEXT: Num: Value Size Type Bind Vis Ndx Name
# SYMBOLS-GNU32-NEXT: 0: 00000000 0 NOTYPE LOCAL DEFAULT UND
-# SYMBOLS-GNU32-NEXT: 1: 00000001 0 NOTYPE LOCAL DEFAULT UND foo
+# SYMBOLS-GNU32-NEXT: 1: 00000001 0 NOTYPE LOCAL DEFAULT 1 foo
# SYMBOLS-GNU32-NEXT: 2: 00000002 0 NOTYPE LOCAL DEFAULT UND bar
+# SYMBOLS-GNU32-NEXT: 3: 00000003 0 NOTYPE GLOBAL DEFAULT 2 data
+
+# SYMBOLS-GNU32X:Symbol table '.symtab' contains 4 entries:
+#SYMBOLS-GNU32X-NEXT: Num: Value Size Type Bind Vis+Other Ndx(SecName) Name [+ Version Info]
----------------
MaskRay wrote:
This is to align with `SYMBOLS-GNU32` above. Happy to indent by 1 if you feel strongly.
https://github.com/llvm/llvm-project/pull/65580
More information about the llvm-commits
mailing list