1# RUN: yaml2obj %s | obj2yaml | FileCheck %s 2 3--- !mach-o 4FileHeader: 5 magic: 0xFEEDFACF 6 cputype: 0x01000007 7 cpusubtype: 0x80000003 8 filetype: 0x00000002 9 ncmds: 16 10 sizeofcmds: 1408 11 flags: 0x00218085 12 reserved: 0x00000000 13LoadCommands: 14 - cmd: LC_SEGMENT_64 15 cmdsize: 72 16 segname: __PAGEZERO 17 vmaddr: 0 18 vmsize: 4294967296 19 fileoff: 0 20 filesize: 0 21 maxprot: 0 22 initprot: 0 23 nsects: 0 24 flags: 0 25 - cmd: LC_SEGMENT_64 26 cmdsize: 552 27 segname: __TEXT 28 vmaddr: 4294967296 29 vmsize: 8192 30 fileoff: 0 31 filesize: 8192 32 maxprot: 7 33 initprot: 5 34 nsects: 6 35 flags: 0 36 - cmd: LC_SEGMENT_64 37 cmdsize: 312 38 segname: __DATA 39 vmaddr: 4294975488 40 vmsize: 4096 41 fileoff: 8192 42 filesize: 4096 43 maxprot: 7 44 initprot: 3 45 nsects: 3 46 flags: 0 47 - cmd: LC_SEGMENT_64 48 cmdsize: 72 49 segname: __LINKEDIT 50 vmaddr: 4294979584 51 vmsize: 4096 52 fileoff: 12288 53 filesize: 2508 54 maxprot: 7 55 initprot: 1 56 nsects: 0 57 flags: 0 58 - cmd: LC_DYLD_INFO_ONLY 59 cmdsize: 48 60 rebase_off: 12288 61 rebase_size: 8 62 bind_off: 12296 63 bind_size: 96 64 weak_bind_off: 0 65 weak_bind_size: 0 66 lazy_bind_off: 12392 67 lazy_bind_size: 624 68 export_off: 13016 69 export_size: 48 70 - cmd: LC_SYMTAB 71 cmdsize: 24 72 symoff: 13080 73 nsyms: 30 74 stroff: 13700 75 strsize: 1096 76 - cmd: LC_DYSYMTAB 77 cmdsize: 80 78 ilocalsym: 0 79 nlocalsym: 9 80 iextdefsym: 9 81 nextdefsym: 2 82 iundefsym: 11 83 nundefsym: 19 84 tocoff: 0 85 ntoc: 0 86 modtaboff: 0 87 nmodtab: 0 88 extrefsymoff: 0 89 nextrefsyms: 0 90 indirectsymoff: 13560 91 nindirectsyms: 35 92 extreloff: 0 93 nextrel: 0 94 locreloff: 0 95 nlocrel: 0 96 - cmd: LC_LOAD_DYLINKER 97 cmdsize: 32 98 name: 12 99 PayloadString: /usr/lib/dyld 100 ZeroPadBytes: 7 101 - cmd: LC_UUID 102 cmdsize: 24 103 uuid: 461A1B28-822F-3F38-B670-645419E636F5 104 - cmd: LC_VERSION_MIN_MACOSX 105 cmdsize: 16 106 version: 658176 107 sdk: 658176 108 - cmd: LC_SOURCE_VERSION 109 cmdsize: 16 110 version: 0 111 - cmd: LC_MAIN 112 cmdsize: 24 113 entryoff: 4448 114 stacksize: 0 115 - cmd: LC_LOAD_DYLIB 116 cmdsize: 48 117 dylib: 118 name: 24 119 timestamp: 2 120 current_version: 7864576 121 compatibility_version: 65536 122 PayloadString: '/usr/lib/libc++.1.dylib' 123 ZeroPadBytes: 1 124 - cmd: LC_LOAD_DYLIB 125 cmdsize: 56 126 dylib: 127 name: 24 128 timestamp: 2 129 current_version: 80349697 130 compatibility_version: 65536 131 PayloadString: /usr/lib/libSystem.B.dylib 132 ZeroPadBytes: 6 133 - cmd: LC_FUNCTION_STARTS 134 cmdsize: 16 135 dataoff: 13064 136 datasize: 16 137 - cmd: LC_DATA_IN_CODE 138 cmdsize: 16 139 dataoff: 13080 140 datasize: 0 141LinkEditData: 142 ExportTrie: 143 TerminalSize: 0 144 NodeOffset: 0 145 Name: '' 146 Flags: 0x0000000000000000 147 Address: 0x0000000000000000 148 Other: 0x0000000000000000 149 ImportName: '' 150 Children: 151 - TerminalSize: 0 152 NodeOffset: 5 153 Name: _ 154 Flags: 0x0000000000000000 155 Address: 0x0000000000000000 156 Other: 0x0000000000000000 157 ImportName: '' 158 Children: 159 - TerminalSize: 2 160 NodeOffset: 33 161 Name: _mh_execute_header 162 Flags: 0x0000000000000000 163 Address: 0x0000000000000000 164 Other: 0x0000000000000000 165 ImportName: '' 166 - TerminalSize: 3 167 NodeOffset: 37 168 Name: main 169 Flags: 0x0000000000000000 170 Address: 0x0000000000001160 171 Other: 0x0000000000000000 172 ImportName: '' 173... 174 175#CHECK: ExportTrie: 176#CHECK: TerminalSize: 0 177#CHECK: NodeOffset: 0 178#CHECK: Name: '' 179#CHECK: Children: 180#CHECK: - TerminalSize: 0 181#CHECK: NodeOffset: 5 182#CHECK: Name: _ 183#CHECK: Children: 184#CHECK: - TerminalSize: 2 185#CHECK: NodeOffset: 33 186#CHECK: Name: _mh_execute_header 187#CHECK: Address: 0x0 188#CHECK: - TerminalSize: 3 189#CHECK: NodeOffset: 37 190#CHECK: Name: main 191#CHECK: Address: 0x1160 192