blob: efedd3e6a12c3ccf301c86a70c996e536280f870 [file] [log] [blame]
Eric Christopher9cad53c2013-04-03 18:31:38 +00001RUN: llvm-readobj -t %p/Inputs/trivial.obj.coff-i386 \
2RUN: | FileCheck %s -check-prefix COFF
3RUN: llvm-readobj -t %p/Inputs/trivial.obj.elf-i386 \
4RUN: | FileCheck %s -check-prefix ELF
Sam Clegg135a4b82017-04-14 19:50:44 +00005RUN: llvm-readobj -t %p/Inputs/trivial.obj.wasm \
6RUN: | FileCheck %s -check-prefix WASM
Eric Christopher9cad53c2013-04-03 18:31:38 +00007
8COFF: Symbols [
9COFF-NEXT: Symbol {
Rui Ueyamaf078eff2014-03-18 23:37:53 +000010COFF-NEXT: Name: @comp.id
11COFF-NEXT: Value: 14766605
David Majnemerf4dc4562014-09-20 00:25:06 +000012COFF-NEXT: Section: IMAGE_SYM_ABSOLUTE (-1)
Rui Ueyamaf078eff2014-03-18 23:37:53 +000013COFF-NEXT: BaseType: Null (0x0)
14COFF-NEXT: ComplexType: Null (0x0)
15COFF-NEXT: StorageClass: Static (0x3)
16COFF-NEXT: AuxSymbolCount: 0
17COFF-NEXT: }
18COFF-NEXT: Symbol {
19COFF-NEXT: Name: @feat.00
20COFF-NEXT: Value: 2147484049
David Majnemerf4dc4562014-09-20 00:25:06 +000021COFF-NEXT: Section: IMAGE_SYM_ABSOLUTE (-1)
Rui Ueyamaf078eff2014-03-18 23:37:53 +000022COFF-NEXT: BaseType: Null (0x0)
23COFF-NEXT: ComplexType: Null (0x0)
24COFF-NEXT: StorageClass: Static (0x3)
25COFF-NEXT: AuxSymbolCount: 0
26COFF-NEXT: }
27COFF-NEXT: Symbol {
Eric Christopher9cad53c2013-04-03 18:31:38 +000028COFF-NEXT: Name: .text
29COFF-NEXT: Value: 0
30COFF-NEXT: Section: .text (1)
31COFF-NEXT: BaseType: Null (0x0)
32COFF-NEXT: ComplexType: Null (0x0)
33COFF-NEXT: StorageClass: Static (0x3)
34COFF-NEXT: AuxSymbolCount: 1
35COFF-NEXT: AuxSectionDef {
36COFF-NEXT: Length: 22
37COFF-NEXT: RelocationCount: 3
38COFF-NEXT: LineNumberCount: 0
39COFF-NEXT: Checksum: 0x0
40COFF-NEXT: Number: 1
41COFF-NEXT: Selection: 0x0
Eric Christopher9cad53c2013-04-03 18:31:38 +000042COFF-NEXT: }
43COFF-NEXT: }
44
45ELF: Symbols [
46ELF-NEXT: Symbol {
Rafael Espindola7c346c22013-06-05 20:33:54 +000047ELF-NEXT: Name: (0)
48ELF-NEXT: Value: 0x0
49ELF-NEXT: Size: 0
50ELF-NEXT: Binding: Local (0x0)
51ELF-NEXT: Type: None (0x0)
52ELF-NEXT: Other: 0
Rafael Espindolacfee7ef2014-03-24 05:00:34 +000053ELF-NEXT: Section: Undefined (0x0)
Rafael Espindola7c346c22013-06-05 20:33:54 +000054ELF-NEXT: }
55ELF-NEXT: Symbol {
Eric Christopher9cad53c2013-04-03 18:31:38 +000056ELF-NEXT: Name: trivial.ll (1)
57ELF-NEXT: Value: 0x0
58ELF-NEXT: Size: 0
59ELF-NEXT: Binding: Local (0x0)
60ELF-NEXT: Type: File (0x4)
61ELF-NEXT: Other: 0
Rafael Espindolacfee7ef2014-03-24 05:00:34 +000062ELF-NEXT: Section: Absolute (0xFFF1)
Eric Christopher9cad53c2013-04-03 18:31:38 +000063ELF-NEXT: }
64ELF-NEXT: Symbol {
65ELF-NEXT: Name: .L.str (39)
66ELF-NEXT: Value: 0x0
67ELF-NEXT: Size: 13
68ELF-NEXT: Binding: Local (0x0)
69ELF-NEXT: Type: Object (0x1)
70ELF-NEXT: Other: 0
71ELF-NEXT: Section: .rodata.str1.1 (0x5)
72ELF-NEXT: }
Sam Clegg135a4b82017-04-14 19:50:44 +000073
74WASM: Symbols [
75WASM-NEXT: Symbol {
Sam Clegg8bda5082017-07-10 20:43:26 +000076WASM-NEXT: Name: puts
Sam Clegge7a60702017-09-06 22:05:41 +000077WASM-NEXT: Type: DEBUG_FUNCTION_NAME (0x4)
78WASM-NEXT: Flags: 0x0
79WASM-NEXT: }
80WASM-NEXT: Symbol {
81WASM-NEXT: Name: SomeOtherFunction
82WASM-NEXT: Type: DEBUG_FUNCTION_NAME (0x4)
83WASM-NEXT: Flags: 0x0
84WASM-NEXT: }
85WASM-NEXT: Symbol {
86WASM-NEXT: Name: main
87WASM-NEXT: Type: DEBUG_FUNCTION_NAME (0x4)
88WASM-NEXT: Flags: 0x0
89WASM-NEXT: }
90WASM-NEXT: Symbol {
91WASM-NEXT: Name: puts
Sam Clegg8bda5082017-07-10 20:43:26 +000092WASM-NEXT: Type: FUNCTION_IMPORT (0x0)
Sam Clegg933df262017-06-26 21:01:39 +000093WASM-NEXT: Flags: 0x0
Sam Clegg135a4b82017-04-14 19:50:44 +000094WASM-NEXT: }
95WASM-NEXT: Symbol {
Sam Clegg8bda5082017-07-10 20:43:26 +000096WASM-NEXT: Name: SomeOtherFunction
97WASM-NEXT: Type: FUNCTION_IMPORT (0x0)
Sam Clegg933df262017-06-26 21:01:39 +000098WASM-NEXT: Flags: 0x0
Sam Clegg135a4b82017-04-14 19:50:44 +000099WASM-NEXT: }
100WASM-NEXT: Symbol {
Sam Clegg8bda5082017-07-10 20:43:26 +0000101WASM-NEXT: Name: main
Sam Clegg135a4b82017-04-14 19:50:44 +0000102WASM-NEXT: Type: FUNCTION_EXPORT (0x1)
Sam Clegg933df262017-06-26 21:01:39 +0000103WASM-NEXT: Flags: 0x0
Sam Clegg135a4b82017-04-14 19:50:44 +0000104WASM-NEXT: }
Sam Clegg135a4b82017-04-14 19:50:44 +0000105WASM-NEXT: ]