52 lines · plain
1// RUN: not llvm-mc -triple aarch64 -filetype obj < %s -o /dev/null 2>&1 | FileCheck %s2 3// Note: These errors are not always emitted in the order in which the relevant4// source appears, this file is carefully ordered so that that is the case.5 6 .text7// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: symbol 'undef' can not be undefined in a subtraction expression8 .word (0-undef)9 10// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: expected relocatable expression11 .word -undef12 13// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: symbol 'undef' can not be undefined in a subtraction expression14 adr x0, #a-undef15 16// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: Cannot represent a difference across sections17 .word x_a - y_a18 19// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: 1-byte data relocations not supported20 .byte undef21 22// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: 1-byte data relocations not supported23 .byte undef-.24 25// CHECK: :[[@LINE+1]]:16: error: expected relocatable expression26 ldr x0, [x1, :lo12:undef-.]27 28// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: invalid fixup for 8-bit load/store instruction29 ldrb w0, [x1, :gottprel_lo12:undef]30 31// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: invalid fixup for 16-bit load/store instruction32 ldrh w0, [x1, :gottprel_lo12:undef]33 34// CHECK: :[[@LINE+1]]:{{[0-9]+}}: error: 32-bit load/store relocation is not supported in LP6435 ldr w0, [x1, :gottprel_lo12:undef]36 37 38 39w:40 .word 041 .weak w42 43 44 .section sec_x45x_a:46 .word 047 48 49 .section sec_y50y_a:51 .word 052