1; RUN: llvm-mc -triple arm64-apple-darwin -filetype=obj -o - %s | llvm-readobj -r - | FileCheck %s
2
3foo:
4  .long 0
5bar:
6  .long 1
7
8baz:
9  .byte foo - bar
10  .short foo - bar
11
12; CHECK: File: <stdin>
13; CHECK: Format: Mach-O arm64
14; CHECK: Arch: aarch64
15; CHECK: AddressSize: 64bit
16; CHECK: Relocations [
17; CHECK:  Section __text {
18; CHECK:    0x9 0 1 1 ARM64_RELOC_SUBTRACTOR 0 bar
19; CHECK:    0x9 0 1 1 ARM64_RELOC_UNSIGNED 0 foo
20; CHECK:    0x8 0 0 1 ARM64_RELOC_SUBTRACTOR 0 bar
21; CHECK:    0x8 0 0 1 ARM64_RELOC_UNSIGNED 0 foo
22; CHECK:  }
23; CHECK: ]
24