1; RUN: llc < %s -march=avr | FileCheck %s
2
3define avr_intrcc void @interrupt_handler() {
4; CHECK-LABEL: interrupt_handler:
5; CHECK: sei
6; CHECK-NEXT: push r0
7; CHECK-NEXT: push r1
8; CHECK-NEXT: in r0, 63
9; CHECK-NEXT: push r0
10; CHECK: clr r0
11; CHECK: pop r0
12; CHECK-NEXT: out 63, r0
13; CHECK-NEXT: pop r1
14; CHECK-NEXT: pop r0
15; CHECK-NEXT: reti
16  ret void
17}
18
19define avr_signalcc void @signal_handler() {
20; CHECK-LABEL: signal_handler:
21; CHECK-NOT: sei
22; CHECK: push r0
23; CHECK-NEXT: push r1
24; CHECK-NEXT: in r0, 63
25; CHECK-NEXT: push r0
26; CHECK: clr r0
27; CHECK: pop r0
28; CHECK-NEXT: out 63, r0
29; CHECK-NEXT: pop r1
30; CHECK-NEXT: pop r0
31; CHECK-NEXT: reti
32  ret void
33}
34