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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.target/] [x86_64/] [abi/] [test_passing_integers.c] - Blame information for rev 816

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

Line No. Rev Author Line
1 328 jeremybenn
/* This is an autogenerated file. Do not edit.  */
2
 
3
#include "defines.h"
4
#include "macros.h"
5
#include "args.h"
6
 
7
struct IntegerRegisters iregs;
8
struct FloatRegisters fregs;
9
unsigned int num_iregs, num_fregs;
10
 
11
/* This struct holds values for argument checking.  */
12
struct
13
{
14
  int i0, i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12, i13, i14, i15, i16, i17, i18, i19, i20, i21, i22, i23;
15
} values_int;
16
 
17
struct
18
{
19
  long i0, i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12, i13, i14, i15, i16, i17, i18, i19, i20, i21, i22, i23;
20
} values_long;
21
 
22
void
23
fun_check_int_passing_int6_values (int i0 ATTRIBUTE_UNUSED, int i1 ATTRIBUTE_UNUSED, int i2 ATTRIBUTE_UNUSED, int i3 ATTRIBUTE_UNUSED, int i4 ATTRIBUTE_UNUSED, int i5 ATTRIBUTE_UNUSED)
24
{
25
  /* Check argument values.  */
26
  assert (values_int.i0 == i0);
27
  assert (values_int.i1 == i1);
28
  assert (values_int.i2 == i2);
29
  assert (values_int.i3 == i3);
30
  assert (values_int.i4 == i4);
31
  assert (values_int.i5 == i5);
32
 
33
}
34
 
35
void
36
fun_check_int_passing_int6_regs (int i0 ATTRIBUTE_UNUSED, int i1 ATTRIBUTE_UNUSED, int i2 ATTRIBUTE_UNUSED, int i3 ATTRIBUTE_UNUSED, int i4 ATTRIBUTE_UNUSED, int i5 ATTRIBUTE_UNUSED)
37
{
38
  /* Check register contents.  */
39
  check_int_arguments;
40
}
41
 
42
void
43
fun_check_int_passing_int12_values (int i0 ATTRIBUTE_UNUSED, int i1 ATTRIBUTE_UNUSED, int i2 ATTRIBUTE_UNUSED, int i3 ATTRIBUTE_UNUSED, int i4 ATTRIBUTE_UNUSED, int i5 ATTRIBUTE_UNUSED, int i6 ATTRIBUTE_UNUSED, int i7 ATTRIBUTE_UNUSED, int i8 ATTRIBUTE_UNUSED, int i9 ATTRIBUTE_UNUSED, int i10 ATTRIBUTE_UNUSED, int i11 ATTRIBUTE_UNUSED)
44
{
45
  /* Check argument values.  */
46
  assert (values_int.i0 == i0);
47
  assert (values_int.i1 == i1);
48
  assert (values_int.i2 == i2);
49
  assert (values_int.i3 == i3);
50
  assert (values_int.i4 == i4);
51
  assert (values_int.i5 == i5);
52
  assert (values_int.i6 == i6);
53
  assert (values_int.i7 == i7);
54
  assert (values_int.i8 == i8);
55
  assert (values_int.i9 == i9);
56
  assert (values_int.i10 == i10);
57
  assert (values_int.i11 == i11);
58
 
59
}
60
 
61
void
62
fun_check_int_passing_int12_regs (int i0 ATTRIBUTE_UNUSED, int i1 ATTRIBUTE_UNUSED, int i2 ATTRIBUTE_UNUSED, int i3 ATTRIBUTE_UNUSED, int i4 ATTRIBUTE_UNUSED, int i5 ATTRIBUTE_UNUSED, int i6 ATTRIBUTE_UNUSED, int i7 ATTRIBUTE_UNUSED, int i8 ATTRIBUTE_UNUSED, int i9 ATTRIBUTE_UNUSED, int i10 ATTRIBUTE_UNUSED, int i11 ATTRIBUTE_UNUSED)
63
{
64
  /* Check register contents.  */
65
  check_int_arguments;
66
}
67
 
68
void
69
fun_check_int_passing_long6_values (long i0 ATTRIBUTE_UNUSED, long i1 ATTRIBUTE_UNUSED, long i2 ATTRIBUTE_UNUSED, long i3 ATTRIBUTE_UNUSED, long i4 ATTRIBUTE_UNUSED, long i5 ATTRIBUTE_UNUSED)
70
{
71
  /* Check argument values.  */
72
  assert (values_long.i0 == i0);
73
  assert (values_long.i1 == i1);
74
  assert (values_long.i2 == i2);
75
  assert (values_long.i3 == i3);
76
  assert (values_long.i4 == i4);
77
  assert (values_long.i5 == i5);
78
 
79
}
80
 
81
void
82
fun_check_int_passing_long6_regs (long i0 ATTRIBUTE_UNUSED, long i1 ATTRIBUTE_UNUSED, long i2 ATTRIBUTE_UNUSED, long i3 ATTRIBUTE_UNUSED, long i4 ATTRIBUTE_UNUSED, long i5 ATTRIBUTE_UNUSED)
83
{
84
  /* Check register contents.  */
85
  check_long_arguments;
86
}
87
 
88
void
89
fun_check_int_passing_long12_values (long i0 ATTRIBUTE_UNUSED, long i1 ATTRIBUTE_UNUSED, long i2 ATTRIBUTE_UNUSED, long i3 ATTRIBUTE_UNUSED, long i4 ATTRIBUTE_UNUSED, long i5 ATTRIBUTE_UNUSED, long i6 ATTRIBUTE_UNUSED, long i7 ATTRIBUTE_UNUSED, long i8 ATTRIBUTE_UNUSED, long i9 ATTRIBUTE_UNUSED, long i10 ATTRIBUTE_UNUSED, long i11 ATTRIBUTE_UNUSED)
90
{
91
  /* Check argument values.  */
92
  assert (values_long.i0 == i0);
93
  assert (values_long.i1 == i1);
94
  assert (values_long.i2 == i2);
95
  assert (values_long.i3 == i3);
96
  assert (values_long.i4 == i4);
97
  assert (values_long.i5 == i5);
98
  assert (values_long.i6 == i6);
99
  assert (values_long.i7 == i7);
100
  assert (values_long.i8 == i8);
101
  assert (values_long.i9 == i9);
102
  assert (values_long.i10 == i10);
103
  assert (values_long.i11 == i11);
104
 
105
}
106
 
107
void
108
fun_check_int_passing_long12_regs (long i0 ATTRIBUTE_UNUSED, long i1 ATTRIBUTE_UNUSED, long i2 ATTRIBUTE_UNUSED, long i3 ATTRIBUTE_UNUSED, long i4 ATTRIBUTE_UNUSED, long i5 ATTRIBUTE_UNUSED, long i6 ATTRIBUTE_UNUSED, long i7 ATTRIBUTE_UNUSED, long i8 ATTRIBUTE_UNUSED, long i9 ATTRIBUTE_UNUSED, long i10 ATTRIBUTE_UNUSED, long i11 ATTRIBUTE_UNUSED)
109
{
110
  /* Check register contents.  */
111
  check_long_arguments;
112
}
113
 
114
#define def_check_int_passing6(_i0, _i1, _i2, _i3, _i4, _i5, _func1, _func2, TYPE) \
115
  values_ ## TYPE .i0 = _i0; \
116
  values_ ## TYPE .i1 = _i1; \
117
  values_ ## TYPE .i2 = _i2; \
118
  values_ ## TYPE .i3 = _i3; \
119
  values_ ## TYPE .i4 = _i4; \
120
  values_ ## TYPE .i5 = _i5; \
121
  WRAP_CALL(_func1) (_i0, _i1, _i2, _i3, _i4, _i5); \
122
  \
123
  clear_int_registers; \
124
  iregs.I0 = _i0; \
125
  iregs.I1 = _i1; \
126
  iregs.I2 = _i2; \
127
  iregs.I3 = _i3; \
128
  iregs.I4 = _i4; \
129
  iregs.I5 = _i5; \
130
  num_iregs = 6; \
131
  WRAP_CALL(_func2) (_i0, _i1, _i2, _i3, _i4, _i5);
132
 
133
#define def_check_int_passing12(_i0, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8, _i9, _i10, _i11, _func1, _func2, TYPE) \
134
  values_ ## TYPE .i0 = _i0; \
135
  values_ ## TYPE .i1 = _i1; \
136
  values_ ## TYPE .i2 = _i2; \
137
  values_ ## TYPE .i3 = _i3; \
138
  values_ ## TYPE .i4 = _i4; \
139
  values_ ## TYPE .i5 = _i5; \
140
  values_ ## TYPE .i6 = _i6; \
141
  values_ ## TYPE .i7 = _i7; \
142
  values_ ## TYPE .i8 = _i8; \
143
  values_ ## TYPE .i9 = _i9; \
144
  values_ ## TYPE .i10 = _i10; \
145
  values_ ## TYPE .i11 = _i11; \
146
  WRAP_CALL(_func1) (_i0, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8, _i9, _i10, _i11); \
147
  \
148
  clear_int_registers; \
149
  iregs.I0 = _i0; \
150
  iregs.I1 = _i1; \
151
  iregs.I2 = _i2; \
152
  iregs.I3 = _i3; \
153
  iregs.I4 = _i4; \
154
  iregs.I5 = _i5; \
155
  num_iregs = 6; \
156
  WRAP_CALL(_func2) (_i0, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8, _i9, _i10, _i11);
157
 
158
void
159
test_ints_on_stack ()
160
{
161
  def_check_int_passing6(32, 33, 34, 35, 36, 37, fun_check_int_passing_int6_values, fun_check_int_passing_int6_regs, int);
162
}
163
 
164
void
165
test_too_many_ints ()
166
{
167
  def_check_int_passing12(32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, fun_check_int_passing_int12_values, fun_check_int_passing_int12_regs, int);
168
}
169
 
170
void
171
test_longs_on_stack ()
172
{
173
  def_check_int_passing6(32, 33, 34, 35, 36, 37, fun_check_int_passing_long6_values, fun_check_int_passing_long6_regs, long);
174
}
175
 
176
void
177
test_too_many_longs ()
178
{
179
  def_check_int_passing12(32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, fun_check_int_passing_long12_values, fun_check_int_passing_long12_regs, long);
180
}
181
 
182
void
183
test_int128s_on_stack ()
184
{
185
}
186
 
187
void
188
test_too_many_int128s ()
189
{
190
}
191
 
192
 
193
int
194
main (void)
195
{
196
  test_ints_on_stack ();
197
  test_too_many_ints ();
198
  test_longs_on_stack ();
199
  test_too_many_longs ();
200
  test_int128s_on_stack ();
201
  test_too_many_int128s ();
202
  return 0;
203
}

powered by: WebSVN 2.1.0

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