OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.target/] [arm/] [interrupt-2.c] - Blame information for rev 378

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 313 jeremybenn
/* Verify that prologue and epilogue are correct for functions with
2
   __attribute__ ((interrupt)).  */
3
/* { dg-do compile } */
4
/* { dg-options "-O1" } */
5
 
6
/* This test is not valid when -mthum.  We just cheat.  */
7
#ifndef __thumb__
8
extern void bar (int);
9
extern void test (void) __attribute__((__interrupt__));
10
 
11
int foo;
12
void test()
13
{
14
  funcptrs(foo);
15
  foo = 0;
16
}
17
#else
18
void test ()
19
{
20
  asm ("stmfd\tsp!, {r0, r1, r2, r3, r4, r5, ip, lr}");
21
  asm ("ldmfd\tsp!, {r0, r1, r2, r3, r4, r5, ip, pc}^");
22
}
23
#endif
24
 
25
/* { dg-final { scan-assembler "stmfd\tsp!, {r0, r1, r2, r3, r4, r5, ip, lr}" } } */
26
/* { dg-final { scan-assembler "ldmfd\tsp!, {r0, r1, r2, r3, r4, r5, ip, pc}\\^" } } */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.