invalid-relocation-aarch64.test 902 Bytes
# REQUIRES: aarch64
# RUN: yaml2obj %s -o %t.o
# RUN: not ld.lld %t.o -o /dev/null 2>&1 | FileCheck %s
# CHECK: error: unknown relocation (1024) against symbol foo
# CHECK: error: unknown relocation (1025) against symbol foo

!ELF
FileHeader:
  Class:           ELFCLASS64
  Data:            ELFDATA2LSB
  Type:            ET_REL
  Machine:         EM_AARCH64
Sections:
  - Name:            .text
    Type:            SHT_PROGBITS
    Flags:           [ SHF_ALLOC ]
  - Name:            .rela.text
    Type:            SHT_RELA
    Link:            .symtab
    Info:            .text
    Relocations:
      - Offset:          0x0000000000000000
        Symbol:          foo
        Type:            0x400
      - Offset:          0x0000000000000000
        Symbol:          foo
        Type:            0x401
Symbols:
  - Name:            foo
    Section:         .text
    Binding:         STB_GLOBAL