1RUN: llvm-readobj -mips-plt-got %p/Inputs/got-plt.exe.elf-mipsel | FileCheck %s
2RUN: llvm-readobj -mips-plt-got --elf-output-style=GNU \
3RUN:              %p/Inputs/got-plt.exe.elf-mipsel \
4RUN:   | FileCheck --check-prefix=GNU %s
5
6CHECK:      PLT GOT {
7CHECK-NEXT:   Reserved entries [
8CHECK-NEXT:     Entry {
9CHECK-NEXT:       Address: 0x410814
10CHECK-NEXT:       Initial: 0x0
11CHECK-NEXT:       Purpose: PLT lazy resolver
12CHECK-NEXT:     }
13CHECK-NEXT:     Entry {
14CHECK-NEXT:       Address: 0x410818
15CHECK-NEXT:       Initial: 0x0
16CHECK-NEXT:       Purpose: Module pointer
17CHECK-NEXT:     }
18CHECK-NEXT:   ]
19CHECK-NEXT:   Entries [
20CHECK-NEXT:     Entry {
21CHECK-NEXT:       Address: 0x41081C
22CHECK-NEXT:       Initial: 0x4007C0
23CHECK-NEXT:       Value: 0x0
24CHECK-NEXT:       Type: Function (0x2)
25CHECK-NEXT:       Section: Undefined (0x0)
26CHECK-NEXT:       Name: puts@GLIBC_2.0 (71)
27CHECK-NEXT:     }
28CHECK-NEXT:     Entry {
29CHECK-NEXT:       Address: 0x410820
30CHECK-NEXT:       Initial: 0x4007C0
31CHECK-NEXT:       Value: 0x0
32CHECK-NEXT:       Type: Function (0x2)
33CHECK-NEXT:       Section: Undefined (0x0)
34CHECK-NEXT:       Name: __libc_start_main@GLIBC_2.0 (53)
35CHECK-NEXT:     }
36CHECK-NEXT:   ]
37CHECK-NEXT: }
38
39GNU:      Primary GOT:
40GNU-NEXT:  Canonical gp value: 00418840
41
42GNU:       Reserved entries:
43GNU-NEXT:    Address     Access  Initial Purpose
44GNU-NEXT:   00410850 -32752(gp) 00000000 Lazy resolver
45GNU-NEXT:   00410854 -32748(gp) 80000000 Module pointer (GNU extension)
46
47GNU:       Local entries:
48GNU-NEXT:    Address     Access  Initial
49GNU-NEXT:   00410858 -32744(gp) 004003d4
50GNU-NEXT:   0041085c -32740(gp) 00410800
51GNU-NEXT:   00410860 -32736(gp) 00000000
52
53GNU:       Global entries:
54GNU-NEXT:    Address     Access  Initial Sym.Val. Type    Ndx Name
55GNU-NEXT:   00410864 -32732(gp) 00000000 00000000 FUNC    UND __gmon_start__
56GNU-NEXT: PLT GOT:
57
58GNU:       Reserved entries:
59GNU-NEXT:    Address  Initial Purpose
60GNU-NEXT:   00410814 00000000 PLT lazy resolver
61GNU-NEXT:   00410854 80000000 Module pointer
62
63GNU:       Entries:
64GNU-NEXT:    Address  Initial Sym.Val. Type    Ndx Name
65GNU-NEXT:   0041081c 004007c0 00000000 FUNC    UND puts
66GNU-NEXT:   00410820 004007c0 00000000 FUNC    UND __libc_start_main
67