Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / llvm / test / MC / AVR / inst-jmp.s
blobc0b7a375ed4509864ce80f7fca153aed60a9ddb5
1 ; RUN: llvm-mc -triple avr -mattr=jmpcall -show-encoding < %s | FileCheck %s
2 ; RUN: llvm-mc -filetype=obj -triple avr -mattr=jmpcall < %s | llvm-objdump --no-print-imm-hex -dr --mattr=jmpcall - | FileCheck -check-prefix=CHECK-INST %s
5 foo:
7 jmp 200
8 jmp -12
9 jmp 80
10 jmp 0
12 jmp foo+1
14 jmp 0x03fffe ; Inst{16-0} or k{16-0}
15 jmp 0x7c0000 ; Inst{24-20} or k{21-17}
16 jmp 0x7ffffe ; all bits set
18 ; CHECK: jmp 200 ; encoding: [0x0c,0x94,0x64,0x00]
19 ; CHECK: jmp -12 ; encoding: [0xfd,0x95,0xfa,0xff]
20 ; CHECK: jmp 80 ; encoding: [0x0c,0x94,0x28,0x00]
21 ; CHECK: jmp 0 ; encoding: [0x0c,0x94,0x00,0x00]
23 ; CHECK: jmp foo+1 ; encoding: [0x0c'A',0x94'A',0b00AAAAAA,0x00]
24 ; CHECK: ; fixup A - offset: 0, value: foo+1, kind: fixup_call
26 ; CHECK: jmp 262142 ; encoding: [0x0d,0x94,0xff,0xff]
27 ; CHECK: jmp 8126464 ; encoding: [0xfc,0x95,0x00,0x00]
28 ; CHECK: jmp 8388606 ; encoding: [0xfd,0x95,0xff,0xff]
31 ; CHECK-INST: jmp 200
32 ; CHECK-INST: jmp 8388596
33 ; CHECK-INST: jmp 80
34 ; CHECK-INST: jmp 0
35 ; CHECK-INST: jmp 0
36 ; CHECK-INST: R_AVR_CALL .text+0x1
37 ; CHECK-INST: jmp 262142
38 ; CHECK-INST: jmp 8126464
39 ; CHECK-INST: jmp 8388606