aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/interrupt-2.c
blob: 3899d529a5f4353784791e575c8029b541b4c279 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* { dg-do compile } */
/* { dg-options "-O2 -mgeneral-regs-only -mno-cld -Wall -g" } */

void
__attribute__((interrupt))
fn (void *frame)
{
}

typedef void (*fn_t) (void *) __attribute__((interrupt));

fn_t fns[] =
{
  fn,
};

/* { dg-final { scan-assembler-not "add(l|q)\[\\t \]*\\$\[0-9\]*,\[\\t \]*%\[re\]?sp" } } */
/* { dg-final { scan-assembler-times "iret" 1 { target ia32 } } } */
/* { dg-final { scan-assembler-times "iretq" 1 { target { ! ia32 } } } } */
/* { dg-final { scan-assembler-not "\tcld" } } */