1; RUN: llvm-mc -triple avr -show-encoding < %s | FileCheck %s
2; RUN: llvm-mc -filetype=obj -triple avr < %s | llvm-objdump -d - | FileCheck -check-prefix=CHECK-INST %s
3
4
5foo:
6
7  out 4,  r2
8  out 6,  r9
9  out 32, r5
10  out 0,  r0
11  out 0,  r31
12  out 63, r0
13  out 63, r31
14
15  out bar-8, r29
16
17; CHECK: out 4,  r2                  ; encoding: [0x24,0xb8]
18; CHECK: out 6,  r9                  ; encoding: [0x96,0xb8]
19; CHECK: out 32, r5                  ; encoding: [0x50,0xbc]
20; CHECK: out 0,  r0                  ; encoding: [0x00,0xb8]
21; CHECK: out 0,  r31                 ; encoding: [0xf0,0xb9]
22; CHECK: out 63, r0                  ; encoding: [0x0f,0xbe]
23; CHECK: out 63, r31                 ; encoding: [0xff,0xbf]
24
25; CHECK: out bar-8, r29              ; encoding: [0xd0'A',0xb9'A']
26; CHECK:                             ;   fixup A - offset: 0, value: bar-8, kind: fixup_port6
27
28; CHECK-INST: out 4,  r2
29; CHECK-INST: out 6,  r9
30; CHECK-INST: out 32, r5
31; CHECK-INST: out 0,  r0
32; CHECK-INST: out 0,  r31
33; CHECK-INST: out 63, r0
34; CHECK-INST: out 63, r31
35
36; CHECK-INST: out 0, r29
37