reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced
    1
    2
    3
    4
    5
    6
    7
    8
    9
   10
   11
   12
   13
   14
   15
   16
   17
   18
   19
   20
   21
   22
   23
   24
   25
   26
   27
   28
   29
   30
   31
   32
   33
   34
   35
   36
   37
   38
   39
   40
   41
   42
   43
   44
   45
   46
   47
   48
   49
   50
   51
   52
   53
   54
   55
   56
   57
   58
   59
   60
   61
   62
   63
   64
   65
   66
   67
   68
   69
   70
# RUN: ld64.lld -arch x86_64 -r -print_atoms %s -o %t | FileCheck %s
# RUN: ld64.lld -arch x86_64 -r -print_atoms %t -o %t2 | FileCheck %s


--- !mach-o
arch:            x86_64
file-type:       MH_OBJECT
flags:           [ MH_SUBSECTIONS_VIA_SYMBOLS ]
compat-version:  0.0
current-version: 0.0
has-UUID:        false
OS:              unknown
sections:
  - segment:         __DATA
    section:         __objc_catlist
    type:            S_REGULAR
    attributes:      [ S_ATTR_NO_DEAD_STRIP ]
    alignment:       8
    address:         0x00000000000003F8
    content:         [ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
                       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 ]
    relocations:
      - offset:          0x00000008
        type:            X86_64_RELOC_UNSIGNED
        length:          3
        pc-rel:          false
        extern:          true
        symbol:          0
      - offset:          0x00000000
        type:            X86_64_RELOC_UNSIGNED
        length:          3
        pc-rel:          false
        extern:          true
        symbol:          1
undefined-symbols:
  - name:            __category1
    type:            N_UNDF
    scope:           [ N_EXT ]
    value:           0x0000000000000000
  - name:            __category2
    type:            N_UNDF
    scope:           [ N_EXT ]
    value:           0x0000000000000000
page-size:       0x00000000
...

# Make sure we atomize the category list section by pointer sized atoms.

# CHECK: path:            '<linker-internal>'
# CHECK: defined-atoms:
# CHECK:   - type:            objc-category-list
# CHECK:     content:         [ 00, 00, 00, 00, 00, 00, 00, 00 ]
# CHECK:     merge:           by-content
# CHECK:     alignment:       8
# CHECK:     references:
# CHECK:       - kind:            pointer64
# CHECK:         offset:          0
# CHECK:         target:          __category2
# CHECK:   - type:            objc-category-list
# CHECK:     content:         [ 00, 00, 00, 00, 00, 00, 00, 00 ]
# CHECK:     merge:           by-content
# CHECK:     alignment:       8
# CHECK:     references:
# CHECK:       - kind:            pointer64
# CHECK:         offset:          0
# CHECK:         target:          __category1
# CHECK: undefined-atoms:
# CHECK:   - name:            __category1
# CHECK:   - name:            __category2
# CHECK: ...