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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [vmx/] [varargs-6.c] - Blame information for rev 816

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
#include "harness.h"
2
#include <stdarg.h>
3
 
4
typedef struct n025
5
{
6
  int m1;
7
  double m2;
8
  int m3;
9
  vector signed int m4;
10
}
11
n025;
12
 
13
static void
14
varargsn025(int p1, double p2, ...)
15
{
16
  n025 q;
17
  va_list ap;
18
  va_start(ap, p2);
19
  q.m1 = p1;
20
  q.m2 = p2;
21
  q.m3 = va_arg(ap, int);
22
  q.m4 = va_arg(ap, vector signed int);
23
  va_end(ap);
24
 
25
  check(q.m1 == 1363477585, "q.m1");
26
  check(q.m2 == -8.72e+18, "q.m2");
27
  check(q.m3 == 198652649, "q.m3");
28
  check(vec_all_eq(q.m4, ((vector signed int){323001541, -1353029458, 1756879633, -327031280})),
29
        "q.m4");
30
}
31
 
32
static void test()
33
{
34
  varargsn025(1363477585, -8.72e+18, 198652649, ((vector signed int){323001541, -1353029458, 1756879633, -327031280}));
35
}

powered by: WebSVN 2.1.0

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