#CHECK: DynamicSymbols [
#CHECK-NEXT: Symbol {
-#CHECK-NEXT: Name: @ (0)
+#CHECK-NEXT: Name: (0)
#CHECK-NEXT: Value: 0x0
#CHECK-NEXT: Size: 0
#CHECK-NEXT: Binding: Local
#CHECK-NEXT: Section: Undefined (0x0)
#CHECK-NEXT: }
#CHECK-NEXT: Symbol {
-#CHECK-NEXT: Name: bang@ (1)
+#CHECK-NEXT: Name: bang (1)
#CHECK-NEXT: Value: 0x4000
#CHECK-NEXT: Size: 8
#CHECK-NEXT: Binding: Global (0x1)
#CHECK-NEXT: Section: .bss (0x7)
#CHECK-NEXT: }
#CHECK-NEXT: Symbol {
-#CHECK-NEXT: Name: bar@ (6)
+#CHECK-NEXT: Name: bar (6)
#CHECK-NEXT: Value: 0x1001
#CHECK-NEXT: Size: 0
#CHECK-NEXT: Binding: Global (0x1)
#CHECK-NEXT: Section: .text (0x4)
#CHECK-NEXT: }
#CHECK-NEXT: Symbol {
-#CHECK-NEXT: Name: baz@ (10)
+#CHECK-NEXT: Name: baz (10)
#CHECK-NEXT: Value: 0x2000
#CHECK-NEXT: Size: 0
#CHECK-NEXT: Binding: Global (0x1)
#CHECK-NEXT: Section: .data (0x5)
#CHECK-NEXT: }
#CHECK-NEXT: Symbol {
-#CHECK-NEXT: Name: foo@ (14)
+#CHECK-NEXT: Name: foo (14)
#CHECK-NEXT: Value: 0x1000
#CHECK-NEXT: Size: 0
#CHECK-NEXT: Binding: Global (0x1)
CHECK-NEXT: Symbols [
CHECK-NEXT: Symbol {
CHECK-NEXT: Version: 0
-CHECK-NEXT: Name: @
+CHECK-NEXT: Name: {{$}}
CHECK-NEXT: }
CHECK-NEXT: Symbol {
CHECK-NEXT: Version: 1
-CHECK-NEXT: Name: _end@
+CHECK-NEXT: Name: _end{{$}}
CHECK-NEXT: }
CHECK-NEXT: Symbol {
CHECK-NEXT: Version: 1
-CHECK-NEXT: Name: _edata@
+CHECK-NEXT: Name: _edata{{$}}
CHECK-NEXT: }
CHECK-NEXT: Symbol {
CHECK-NEXT: Version: 3
CHECK-NEXT: }
CHECK-NEXT: Symbol {
CHECK-NEXT: Version: 1
-CHECK-NEXT: Name: __bss_start@
+CHECK-NEXT: Name: __bss_start{{$}}
CHECK-NEXT: }
CHECK-NEXT: Symbol {
CHECK-NEXT: Version: 2
HASH: Symbol table of .hash for image:
HASH-NEXT: Num Buc: Value Size Type Bind Vis Ndx Name
HASH-NEXT: 9 0: 00000000 0 FUNC GLOBAL DEFAULT UND __gxx_personality_v0@CXXABI_1.3
-HASH-NEXT: 13 0: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS _edata@
+HASH-NEXT: 13 0: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS _edata{{$}}
HASH-NEXT: 7 0: 00000000 0 FUNC GLOBAL DEFAULT UND _ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode@GLIBCXX_3.4
-HASH-NEXT: 2 0: 00000000 0 NOTYPE WEAK DEFAULT UND _Jv_RegisterClasses@
-HASH-NEXT: 1 0: 00000000 0 NOTYPE WEAK DEFAULT UND __gmon_start__@
-HASH-NEXT: 16 1: 00000850 81 FUNC GLOBAL DEFAULT 14 main@
+HASH-NEXT: 2 0: 00000000 0 NOTYPE WEAK DEFAULT UND _Jv_RegisterClasses{{$}}
+HASH-NEXT: 1 0: 00000000 0 NOTYPE WEAK DEFAULT UND __gmon_start__{{$}}
+HASH-NEXT: 16 1: 00000850 81 FUNC GLOBAL DEFAULT 14 main{{$}}
HASH-NEXT: 10 1: 00000000 0 FUNC GLOBAL DEFAULT UND _Unwind_Resume@GCC_3.0
HASH-NEXT: 8 1: 00000000 0 FUNC GLOBAL DEFAULT UND puts@GLIBC_2.0
-HASH-NEXT: 12 1: 00001b68 0 NOTYPE GLOBAL DEFAULT ABS _end@
+HASH-NEXT: 12 1: 00001b68 0 NOTYPE GLOBAL DEFAULT ABS _end{{$}}
HASH-NEXT: 6 1: 00000000 0 FUNC GLOBAL DEFAULT UND _ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev@GLIBCXX_3.4
-HASH-NEXT: 5 1: 00000000 0 NOTYPE WEAK DEFAULT UND _ITM_registerTMCloneTable@
-HASH-NEXT: 4 1: 00000000 0 NOTYPE WEAK DEFAULT UND _ITM_deregisterTMCloneTable@
+HASH-NEXT: 5 1: 00000000 0 NOTYPE WEAK DEFAULT UND _ITM_registerTMCloneTable{{$}}
+HASH-NEXT: 4 1: 00000000 0 NOTYPE WEAK DEFAULT UND _ITM_deregisterTMCloneTable{{$}}
HASH-NEXT: 3 1: 00000000 0 FUNC GLOBAL DEFAULT UND __libc_start_main@GLIBC_2.0
HASH-NEXT: 11 2: 00000000 0 FUNC WEAK DEFAULT UND __cxa_finalize@GLIBC_2.1.3
-HASH-NEXT: 15 2: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS __bss_start@
-HASH-NEXT: 14 2: 0000093c 4 OBJECT GLOBAL DEFAULT 16 _IO_stdin_used@
+HASH-NEXT: 15 2: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS __bss_start{{$}}
+HASH-NEXT: 14 2: 0000093c 4 OBJECT GLOBAL DEFAULT 16 _IO_stdin_used{{$}}
HASH: Symbol table of .gnu.hash for image:
HASH-NEXT: Num Buc: Value Size Type Bind Vis Ndx Name
-HASH-NEXT: 12 0: 00001b68 0 NOTYPE GLOBAL DEFAULT ABS _end@
-HASH-NEXT: 13 0: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS _edata@
-HASH-NEXT: 14 1: 0000093c 4 OBJECT GLOBAL DEFAULT 16 _IO_stdin_used@
-HASH-NEXT: 15 1: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS __bss_start@
-HASH-NEXT: 16 1: 00000850 81 FUNC GLOBAL DEFAULT 14 main@
+HASH-NEXT: 12 0: 00001b68 0 NOTYPE GLOBAL DEFAULT ABS _end{{$}}
+HASH-NEXT: 13 0: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS _edata{{$}}
+HASH-NEXT: 14 1: 0000093c 4 OBJECT GLOBAL DEFAULT 16 _IO_stdin_used{{$}}
+HASH-NEXT: 15 1: 00001b64 0 NOTYPE GLOBAL DEFAULT ABS __bss_start{{$}}
+HASH-NEXT: 16 1: 00000850 81 FUNC GLOBAL DEFAULT 14 main{{$}}
GOT-EXE-NEXT: Value: 0x0
GOT-EXE-NEXT: Type: Function (0x2)
GOT-EXE-NEXT: Section: Undefined (0x0)
-GOT-EXE-NEXT: Name: __gmon_start__@ (1)
+GOT-EXE-NEXT: Name: __gmon_start__ (1)
GOT-EXE-NEXT: }
GOT-EXE-NEXT: ]
GOT-EXE-NEXT: Number of TLS and multi-GOT entries: 0
GOT-SO-NEXT: Value: 0x0
GOT-SO-NEXT: Type: None (0x0)
GOT-SO-NEXT: Section: Undefined (0x0)
-GOT-SO-NEXT: Name: _ITM_registerTMCloneTable@ (87)
+GOT-SO-NEXT: Name: _ITM_registerTMCloneTable (87)
GOT-SO-NEXT: }
GOT-SO-NEXT: Entry {
GOT-SO-NEXT: Address: 0x1090C
GOT-SO-NEXT: Value: 0x0
GOT-SO-NEXT: Type: None (0x0)
GOT-SO-NEXT: Section: Undefined (0x0)
-GOT-SO-NEXT: Name: _Jv_RegisterClasses@ (128)
+GOT-SO-NEXT: Name: _Jv_RegisterClasses (128)
GOT-SO-NEXT: }
GOT-SO-NEXT: Entry {
GOT-SO-NEXT: Address: 0x10910
GOT-SO-NEXT: Value: 0x0
GOT-SO-NEXT: Type: Function (0x2)
GOT-SO-NEXT: Section: Undefined (0x0)
-GOT-SO-NEXT: Name: __gmon_start__@ (23)
+GOT-SO-NEXT: Name: __gmon_start__ (23)
GOT-SO-NEXT: }
GOT-SO-NEXT: Entry {
GOT-SO-NEXT: Address: 0x10914
GOT-SO-NEXT: Value: 0x0
GOT-SO-NEXT: Type: None (0x0)
GOT-SO-NEXT: Section: Undefined (0x0)
-GOT-SO-NEXT: Name: _ITM_deregisterTMCloneTable@ (59)
+GOT-SO-NEXT: Name: _ITM_deregisterTMCloneTable (59)
GOT-SO-NEXT: }
GOT-SO-NEXT: Entry {
GOT-SO-NEXT: Address: 0x1091C
GOT-TLS-NEXT: Value: 0x0
GOT-TLS-NEXT: Type: None (0x0)
GOT-TLS-NEXT: Section: Undefined (0x0)
-GOT-TLS-NEXT: Name: _ITM_registerTMCloneTable@ (78)
+GOT-TLS-NEXT: Name: _ITM_registerTMCloneTable (78)
GOT-TLS-NEXT: }
GOT-TLS-NEXT: Entry {
GOT-TLS-NEXT: Address: 0x10C70
GOT-TLS-NEXT: Value: 0x0
GOT-TLS-NEXT: Type: None (0x0)
GOT-TLS-NEXT: Section: Undefined (0x0)
-GOT-TLS-NEXT: Name: _Jv_RegisterClasses@ (119)
+GOT-TLS-NEXT: Name: _Jv_RegisterClasses (119)
GOT-TLS-NEXT: }
GOT-TLS-NEXT: Entry {
GOT-TLS-NEXT: Address: 0x10C78
GOT-TLS-NEXT: Value: 0x0
GOT-TLS-NEXT: Type: Function (0x2)
GOT-TLS-NEXT: Section: Undefined (0x0)
-GOT-TLS-NEXT: Name: __gmon_start__@ (23)
+GOT-TLS-NEXT: Name: __gmon_start__ (23)
GOT-TLS-NEXT: }
GOT-TLS-NEXT: Entry {
GOT-TLS-NEXT: Address: 0x10C80
GOT-TLS-NEXT: Value: 0x0
GOT-TLS-NEXT: Type: None (0x0)
GOT-TLS-NEXT: Section: Undefined (0x0)
-GOT-TLS-NEXT: Name: _ITM_deregisterTMCloneTable@ (50)
+GOT-TLS-NEXT: Name: _ITM_deregisterTMCloneTable (50)
GOT-TLS-NEXT: }
GOT-TLS-NEXT: Entry {
GOT-TLS-NEXT: Address: 0x10C90
bool IsDefault;
StringRef Version = getSymbolVersion(StrTable, &*Symbol, IsDefault);
- FullSymbolName += (IsDefault ? "@@" : "@");
- FullSymbolName += Version;
+ if (!Version.empty()) {
+ FullSymbolName += (IsDefault ? "@@" : "@");
+ FullSymbolName += Version;
+ }
return FullSymbolName;
}