]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/testsuite/gcc.dg/torture/stackalign/nested-2.c
Get rid of dg-skip-if etc. default args
[thirdparty/gcc.git] / gcc / testsuite / gcc.dg / torture / stackalign / nested-2.c
CommitLineData
3b2488ca 1/* { dg-do run } */
4f4b0ab8
RO
2/* { dg-skip-if "Stack alignment is too small" { hppa*-*-hpux* } } */
3/* { dg-skip-if "Stack alignment causes use of alloca" { nvptx-*-* } } */
3b2488ca
L
4
5#include "check.h"
6
7#ifndef ALIGNMENT
8#define ALIGNMENT 64
9#endif
10
11typedef int aligned __attribute__((aligned(ALIGNMENT)));
12
13int global;
14
15void
16foo (void)
17{
18 aligned j;
19
20 __attribute__ ((__noinline__))
21 void bar ()
22 {
23 aligned i;
24
25 if (check_int (&i, __alignof__(i)) != i)
26 abort ();
27
28 if (check_int (&j, __alignof__(j)) != j)
29 abort ();
30
31 j = -20;
32 }
33 bar ();
34
35 if (j != -20)
36 abort ();
37
38 if (check_int (&j, __alignof__(j)) != j)
39 abort ();
40}
41
42int
43main()
44{
45 foo ();
46 return 0;
47}