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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [torture/] [stackalign/] [alloca-6.c] - Blame information for rev 698

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

Line No. Rev Author Line
1 689 jeremybenn
/* PR middle-end/45234 */
2
/* { dg-do run { target { { i?86-*-* x86_64-*-* } && ia32 } } } */
3
/* { dg-options "-mincoming-stack-boundary=2 -mpreferred-stack-boundary=2" } */
4
 
5
#include "check.h"
6
 
7
void
8
__attribute__ ((noinline))
9
bar (__float128 f)
10
{
11
  check (&f, __alignof__(f));
12
}
13
 
14
volatile int z = 6;
15
 
16
int
17
main (void)
18
{
19
  char *p = __builtin_alloca (z);
20
 
21
  bar (0);
22
 
23
  __builtin_strncpy (p, "good", 5);
24
  if (__builtin_strncmp (p, "good", 5) != 0)
25
    {
26
#ifdef DEBUG
27
      p[z - 1] = '\0';
28
      printf ("Failed: %s != good\n", p);
29
#endif
30
     abort ();
31
    }
32
 
33
  return 0;
34
}

powered by: WebSVN 2.1.0

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