1 // RUN: llvm-objdump -p %p/Inputs/hello.obj.macho-arm | FileCheck %s
2 // RUN: llvm-objdump -p %p/Inputs/hello.exe.macho-arm \
3 // RUN: | FileCheck %s -check-prefix=EXE
4 // RUN: llvm-objdump -macho -private-headers %p/Inputs/thumb.armv7m \
5 // RUN: | FileCheck %s -check-prefix=THREAD
8 CHECK: magic cputype cpusubtype caps filetype ncmds sizeofcmds flags
9 CHECK: MH_MAGIC ARM V7 0x00 OBJECT 3 568 SUBSECTIONS_VIA_SYMBOLS
14 CHECK: vmaddr 0x00000000
15 CHECK: vmsize 0x00000043
23 CHECK: sectname __text
25 CHECK: addr 0x00000000
26 CHECK: size 0x00000036
32 CHECK: attributes PURE_INSTRUCTIONS SOME_INSTRUCTIONS
36 CHECK: sectname __textcoal_nt
38 CHECK: addr 0x00000036
39 CHECK: size 0x00000000
44 CHECK: type S_COALESCED
45 CHECK: attributes PURE_INSTRUCTIONS
49 CHECK: sectname __const_coal
51 CHECK: addr 0x00000036
52 CHECK: size 0x00000000
57 CHECK: type S_COALESCED
58 CHECK: attributes (none)
62 CHECK: sectname __picsymbolstub4
64 CHECK: addr 0x00000036
65 CHECK: size 0x00000000
70 CHECK: type S_SYMBOL_STUBS
71 CHECK: attributes (none)
72 CHECK: reserved1 0 (index into indirect symbol table)
73 CHECK: reserved2 16 (size of stubs)
75 CHECK: sectname __StaticInit
77 CHECK: addr 0x00000036
78 CHECK: size 0x00000000
84 CHECK: attributes PURE_INSTRUCTIONS
88 CHECK: sectname __cstring
90 CHECK: addr 0x00000036
91 CHECK: size 0x0000000d
96 CHECK: type S_CSTRING_LITERALS
97 CHECK: attributes (none)
100 CHECK: Load command 1
107 CHECK: Load command 2
108 CHECK: cmd LC_DYSYMTAB
120 CHECK: extrefsymoff 0
122 CHECK: indirectsymoff 0
123 CHECK: nindirectsyms 0
130 EXE: magic cputype cpusubtype caps filetype ncmds sizeofcmds flags
131 EXE: MH_MAGIC ARM V7 0x00 EXECUTE 17 1012 NOUNDEFS DYLDLINK TWOLEVEL PIE
135 EXE: segname __PAGEZERO
136 EXE: vmaddr 0x00000000
137 EXE: vmsize 0x00004000
148 EXE: vmaddr 0x00004000
149 EXE: vmsize 0x00008000
166 EXE: attributes PURE_INSTRUCTIONS SOME_INSTRUCTIONS
170 EXE: sectname __stub_helper
179 EXE: attributes PURE_INSTRUCTIONS SOME_INSTRUCTIONS
183 EXE: sectname __cstring
191 EXE: type S_CSTRING_LITERALS
192 EXE: attributes (none)
196 EXE: sectname __symbolstub1
204 EXE: type S_SYMBOL_STUBS
205 EXE: attributes PURE_INSTRUCTIONS SOME_INSTRUCTIONS
206 EXE: reserved1 0 (index into indirect symbol table)
207 EXE: reserved2 4 (size of stubs)
212 EXE: vmaddr 0x0000c000
213 EXE: vmsize 0x00004000
221 EXE: sectname __lazy_symbol
229 EXE: type S_LAZY_SYMBOL_POINTERS
230 EXE: attributes (none)
231 EXE: reserved1 1 (index into indirect symbol table)
234 EXE: sectname __nl_symbol_ptr
242 EXE: type S_NON_LAZY_SYMBOL_POINTERS
243 EXE: attributes (none)
244 EXE: reserved1 2 (index into indirect symbol table)
249 EXE: segname __LINKEDIT
250 EXE: vmaddr 0x00010000
251 EXE: vmsize 0x00004000
259 EXE: cmd LC_DYLD_INFO_ONLY
261 EXE: rebase_off 49152
266 EXE: weak_bind_size 0
267 EXE: lazy_bind_off 49180
268 EXE: lazy_bind_size 16
269 EXE: export_off 49196
293 EXE: indirectsymoff 49324
300 EXE: cmd LC_LOAD_DYLINKER
302 EXE: name /usr/lib/dyld (offset 12)
306 EXE: uuid C2D9351C-1EF1-330B-A2AB-EED6CF7D2C5D
308 EXE: cmd LC_VERSION_MIN_IPHONEOS
313 EXE: cmd LC_SOURCE_VERSION
322 EXE: cmd LC_ENCRYPTION_INFO
328 EXE: cmd LC_LOAD_DYLIB
330 EXE: name /usr/lib/libSystem.B.dylib (offset 24)
331 EXE: current version 1213.0.0
332 EXE: compatibility version 1.0.0
334 EXE: cmd LC_FUNCTION_STARTS
339 EXE: cmd LC_DATA_IN_CODE
344 EXE: cmd LC_DYLIB_CODE_SIGN_DRS
349 THREAD: Load command 6
350 THREAD: cmd LC_UNIXTHREAD
352 THREAD: flavor ARM_THREAD_STATE
353 THREAD: count ARM_THREAD_STATE_COUNT
354 THREAD: r0 0x00000000 r1 0x00000000 r2 0x00000000 r3 0x00000000
355 THREAD: r4 0x00000000 r5 0x00000000 r6 0x00000000 r7 0x00000000
356 THREAD: r8 0x00000000 r9 0x00000000 r10 0x00000000 r11 0x00000000
357 THREAD: r12 0x00000000 sp 0x00000000 lr 0x00000000 pc 0x00001fff
358 THREAD: cpsr 0x00000000