[PATCH] D59186: [llvm-readobj] Separate `Symbol Version` dumpers into `LLVM style` and `GNU style`
Jordan Rupprecht via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 21 11:08:48 PDT 2019
rupprecht accepted this revision.
rupprecht added inline comments.
This revision is now accepted and ready to land.
================
Comment at: test/tools/llvm-readobj/elf-versioninfo.test:6
-CHECK: 0x000000006FFFFFF0 VERSYM 0x24C
-CHECK: 0x000000006FFFFFFC VERDEF 0x25C
-CHECK: 0x000000006FFFFFFD VERDEFNUM 3
-
-CHECK: Version symbols {
-CHECK-NEXT: Section Name: .gnu.version (20)
-CHECK-NEXT: Address: 0x24C
-CHECK-NEXT: Offset: 0x24C
-CHECK-NEXT: Link: 1
-CHECK-NEXT: Symbols [
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 0
-CHECK-NEXT: Name: {{$}}
-CHECK-NEXT: }
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 1
-CHECK-NEXT: Name: _end{{$}}
-CHECK-NEXT: }
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 1
-CHECK-NEXT: Name: _edata{{$}}
-CHECK-NEXT: }
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 3
-CHECK-NEXT: Name: goo@@VERSION2
-CHECK-NEXT: }
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 1
-CHECK-NEXT: Name: __bss_start{{$}}
-CHECK-NEXT: }
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 2
-CHECK-NEXT: Name: foo@@VERSION1
-CHECK-NEXT: }
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 2
-CHECK-NEXT: Name: VERSION1@@VERSION1
-CHECK-NEXT: }
-CHECK-NEXT: Symbol {
-CHECK-NEXT: Version: 3
-CHECK-NEXT: Name: VERSION2@@VERSION2
-CHECK-NEXT: }
-CHECK-NEXT: ]
-CHECK-NEXT: }
-
-CHECK: SHT_GNU_verdef {
-CHECK-NEXT: Definition {
-CHECK-NEXT: Version: 1
-CHECK-NEXT: Flags: Base (0x1)
-CHECK-NEXT: Index: 1
-CHECK-NEXT: Hash: 430712
-CHECK-NEXT: Name: blah
-CHECK-NEXT: }
-CHECK-NEXT: Definition {
-CHECK-NEXT: Version: 1
-CHECK-NEXT: Flags: 0x0
-CHECK-NEXT: Index: 2
-CHECK-NEXT: Hash: 175630257
-CHECK-NEXT: Name: VERSION1
-CHECK-NEXT: }
-CHECK-NEXT: Definition {
-CHECK-NEXT: Version: 1
-CHECK-NEXT: Flags: 0x0
-CHECK-NEXT: Index: 3
-CHECK-NEXT: Hash: 175630258
-CHECK-NEXT: Name: VERSION2
-CHECK-NEXT: Predecessor: VERSION1
-CHECK-NEXT: }
-CHECK-NEXT: }
-
-RUN: llvm-readobj -V %p/Inputs/verneed.elf-x86-64 | FileCheck %s --check-prefix=VERNEED
-
-VERNEED: SHT_GNU_verneed {
-VERNEED-NEXT: Dependency {
-VERNEED-NEXT: Version: 1
-VERNEED-NEXT: Count: 2
-VERNEED-NEXT: FileName: verneed1.so.0
-VERNEED-NEXT: Entry {
-VERNEED-NEXT: Hash: 1938
-VERNEED-NEXT: Flags: 0x0
-VERNEED-NEXT: Index: 3
-VERNEED-NEXT: Name: v2
-VERNEED-NEXT: }
-VERNEED-NEXT: Entry {
-VERNEED-NEXT: Hash: 1939
-VERNEED-NEXT: Flags: 0x0
-VERNEED-NEXT: Index: 2
-VERNEED-NEXT: Name: v3
-VERNEED-NEXT: }
-VERNEED-NEXT: }
-VERNEED-NEXT: Dependency {
-VERNEED-NEXT: Version: 1
-VERNEED-NEXT: Count: 1
-VERNEED-NEXT: FileName: verneed2.so.0
-VERNEED-NEXT: Entry {
-VERNEED-NEXT: Hash: 1937
-VERNEED-NEXT: Flags: 0x0
-VERNEED-NEXT: Index: 4
-VERNEED-NEXT: Name: v1
-VERNEED-NEXT: }
-VERNEED-NEXT: }
-VERNEED-NEXT: }
+LLVM_VERDEF: 0x000000006FFFFFF0 VERSYM 0x24C
+LLVM_VERDEF: 0x000000006FFFFFFC VERDEF 0x25C
----------------
nit: use LLVM-VERDEF/GNU-VERDEF for consistent hyphens (e.g. `LLVM_VERDEF-NEXT` should be `LLVM-VERDEF-NEXT`)
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59186/new/
https://reviews.llvm.org/D59186
More information about the llvm-commits
mailing list