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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [guality/] [drap.c] - Blame information for rev 689

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 689 jeremybenn
/* { dg-do run { target { i?86-*-* x86_64-*-* } } } */
2
/* { dg-options "-g -mforce-drap" } */
3
 
4
volatile int v;
5
 
6
__attribute__((noinline, noclone)) int
7
bar (int a, int b)
8
{
9
#ifdef __x86_64__
10
  asm volatile ("movq %%rsp, %%r10" : : : "r10");
11
#else
12
  asm volatile ("movl %%esp, %%ecx" : : : "ecx");
13
#endif
14
  return 0;
15
}
16
 
17
__attribute__((noinline, noclone)) int
18
foo (int v0, int v1, int v2, int v3, int v4, int v5, int a, int b)
19
{
20
  __attribute__((aligned (32))) int c = bar (a, b);
21
  v++;               /* { dg-final { gdb-test 21 "a" "5" } } */
22
  return a + b + c;  /* { dg-final { gdb-test 22 "b" "6" } } */
23
}
24
 
25
int
26
main (void)
27
{
28
  foo (0, 0, 0, 0, 0, 0, 5, 6);
29
  return 0;
30
}

powered by: WebSVN 2.1.0

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