1 /*
2  * Copyright (C) by Argonne National Laboratory
3  *     See COPYRIGHT in top-level directory
4  *
5  * DO NOT EDIT: AUTOMATICALLY GENERATED FILE !!
6  */
7 
8 #include <string.h>
9 #include <stdint.h>
10 #include <wchar.h>
11 #include "yaksuri_seqi_pup.h"
12 
yaksuri_seqi_pack_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)13 int yaksuri_seqi_pack_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
14 {
15     int rc = YAKSA_SUCCESS;
16     const char *restrict sbuf = (const char *) inbuf;
17     char *restrict dbuf = (char *) outbuf;
18     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
19 
20     int count1 = type->u.contig.count;
21     intptr_t stride1 = type->u.contig.child->extent;
22     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
23 
24     int count2 = type->u.contig.child->u.contig.count;
25     intptr_t stride2 = type->u.contig.child->u.contig.child->extent;
26     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.contig.child->extent;
27 
28     uintptr_t idx = 0;
29     for (int i = 0; i < count; i++) {
30         for (int j1 = 0; j1 < count1; j1++) {
31             for (int j2 = 0; j2 < count2; j2++) {
32                 *((long double *) (void *) (dbuf + idx)) = *((const long double *) (const void *) (sbuf + i * extent + j1 * stride1 + j2 * stride2));
33                 idx += sizeof(long double);
34             }
35         }
36     }
37 
38     return rc;
39 }
40 
yaksuri_seqi_unpack_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)41 int yaksuri_seqi_unpack_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
42 {
43     int rc = YAKSA_SUCCESS;
44     const char *restrict sbuf = (const char *) inbuf;
45     char *restrict dbuf = (char *) outbuf;
46     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
47 
48     int count1 = type->u.contig.count;
49     intptr_t stride1 = type->u.contig.child->extent;
50     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
51 
52     int count2 = type->u.contig.child->u.contig.count;
53     intptr_t stride2 = type->u.contig.child->u.contig.child->extent;
54     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.contig.child->extent;
55 
56     uintptr_t idx = 0;
57     for (int i = 0; i < count; i++) {
58         for (int j1 = 0; j1 < count1; j1++) {
59             for (int j2 = 0; j2 < count2; j2++) {
60                 *((long double *) (void *) (dbuf + i * extent + j1 * stride1 + j2 * stride2)) = *((const long double *) (const void *) (sbuf + idx));
61                 idx += sizeof(long double);
62             }
63         }
64     }
65 
66     return rc;
67 }
68 
yaksuri_seqi_pack_hvector_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)69 int yaksuri_seqi_pack_hvector_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
70 {
71     int rc = YAKSA_SUCCESS;
72     const char *restrict sbuf = (const char *) inbuf;
73     char *restrict dbuf = (char *) outbuf;
74     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
75 
76     int count1 = type->u.hvector.count;
77     int blocklength1 ATTRIBUTE((unused)) = type->u.hvector.blocklength;
78     intptr_t stride1 = type->u.hvector.stride;
79     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
80 
81     int count2 = type->u.hvector.child->u.contig.count;
82     intptr_t stride2 = type->u.hvector.child->u.contig.child->extent;
83     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.hvector.child->extent;
84 
85     int count3 = type->u.hvector.child->u.contig.child->u.contig.count;
86     intptr_t stride3 = type->u.hvector.child->u.contig.child->u.contig.child->extent;
87     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.hvector.child->u.contig.child->extent;
88 
89     uintptr_t idx = 0;
90     for (int i = 0; i < count; i++) {
91         for (int j1 = 0; j1 < count1; j1++) {
92             for (int k1 = 0; k1 < blocklength1; k1++) {
93                 for (int j2 = 0; j2 < count2; j2++) {
94                     for (int j3 = 0; j3 < count3; j3++) {
95                         *((long double *) (void *) (dbuf + idx)) = *((const long double *) (const void *) (sbuf + i * extent + j1 * stride1 + k1 * extent2 + j2 * stride2 + j3 * stride3));
96                         idx += sizeof(long double);
97                     }
98                 }
99             }
100         }
101     }
102 
103     return rc;
104 }
105 
yaksuri_seqi_unpack_hvector_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)106 int yaksuri_seqi_unpack_hvector_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
107 {
108     int rc = YAKSA_SUCCESS;
109     const char *restrict sbuf = (const char *) inbuf;
110     char *restrict dbuf = (char *) outbuf;
111     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
112 
113     int count1 = type->u.hvector.count;
114     int blocklength1 ATTRIBUTE((unused)) = type->u.hvector.blocklength;
115     intptr_t stride1 = type->u.hvector.stride;
116     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
117 
118     int count2 = type->u.hvector.child->u.contig.count;
119     intptr_t stride2 = type->u.hvector.child->u.contig.child->extent;
120     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.hvector.child->extent;
121 
122     int count3 = type->u.hvector.child->u.contig.child->u.contig.count;
123     intptr_t stride3 = type->u.hvector.child->u.contig.child->u.contig.child->extent;
124     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.hvector.child->u.contig.child->extent;
125 
126     uintptr_t idx = 0;
127     for (int i = 0; i < count; i++) {
128         for (int j1 = 0; j1 < count1; j1++) {
129             for (int k1 = 0; k1 < blocklength1; k1++) {
130                 for (int j2 = 0; j2 < count2; j2++) {
131                     for (int j3 = 0; j3 < count3; j3++) {
132                         *((long double *) (void *) (dbuf + i * extent + j1 * stride1 + k1 * extent2 + j2 * stride2 + j3 * stride3)) = *((const long double *) (const void *) (sbuf + idx));
133                         idx += sizeof(long double);
134                     }
135                 }
136             }
137         }
138     }
139 
140     return rc;
141 }
142 
yaksuri_seqi_pack_blkhindx_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)143 int yaksuri_seqi_pack_blkhindx_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
144 {
145     int rc = YAKSA_SUCCESS;
146     const char *restrict sbuf = (const char *) inbuf;
147     char *restrict dbuf = (char *) outbuf;
148     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
149 
150     int count1 = type->u.blkhindx.count;
151     int blocklength1 ATTRIBUTE((unused)) = type->u.blkhindx.blocklength;
152     intptr_t *restrict array_of_displs1 = type->u.blkhindx.array_of_displs;
153     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
154 
155     int count2 = type->u.blkhindx.child->u.contig.count;
156     intptr_t stride2 = type->u.blkhindx.child->u.contig.child->extent;
157     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.blkhindx.child->extent;
158 
159     int count3 = type->u.blkhindx.child->u.contig.child->u.contig.count;
160     intptr_t stride3 = type->u.blkhindx.child->u.contig.child->u.contig.child->extent;
161     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.blkhindx.child->u.contig.child->extent;
162 
163     uintptr_t idx = 0;
164     for (int i = 0; i < count; i++) {
165         for (int j1 = 0; j1 < count1; j1++) {
166             for (int k1 = 0; k1 < blocklength1; k1++) {
167                 for (int j2 = 0; j2 < count2; j2++) {
168                     for (int j3 = 0; j3 < count3; j3++) {
169                         *((long double *) (void *) (dbuf + idx)) = *((const long double *) (const void *) (sbuf + i * extent + array_of_displs1[j1] + k1 * extent2 + j2 * stride2 + j3 * stride3));
170                         idx += sizeof(long double);
171                     }
172                 }
173             }
174         }
175     }
176 
177     return rc;
178 }
179 
yaksuri_seqi_unpack_blkhindx_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)180 int yaksuri_seqi_unpack_blkhindx_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
181 {
182     int rc = YAKSA_SUCCESS;
183     const char *restrict sbuf = (const char *) inbuf;
184     char *restrict dbuf = (char *) outbuf;
185     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
186 
187     int count1 = type->u.blkhindx.count;
188     int blocklength1 ATTRIBUTE((unused)) = type->u.blkhindx.blocklength;
189     intptr_t *restrict array_of_displs1 = type->u.blkhindx.array_of_displs;
190     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
191 
192     int count2 = type->u.blkhindx.child->u.contig.count;
193     intptr_t stride2 = type->u.blkhindx.child->u.contig.child->extent;
194     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.blkhindx.child->extent;
195 
196     int count3 = type->u.blkhindx.child->u.contig.child->u.contig.count;
197     intptr_t stride3 = type->u.blkhindx.child->u.contig.child->u.contig.child->extent;
198     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.blkhindx.child->u.contig.child->extent;
199 
200     uintptr_t idx = 0;
201     for (int i = 0; i < count; i++) {
202         for (int j1 = 0; j1 < count1; j1++) {
203             for (int k1 = 0; k1 < blocklength1; k1++) {
204                 for (int j2 = 0; j2 < count2; j2++) {
205                     for (int j3 = 0; j3 < count3; j3++) {
206                         *((long double *) (void *) (dbuf + i * extent + array_of_displs1[j1] + k1 * extent2 + j2 * stride2 + j3 * stride3)) = *((const long double *) (const void *) (sbuf + idx));
207                         idx += sizeof(long double);
208                     }
209                 }
210             }
211         }
212     }
213 
214     return rc;
215 }
216 
yaksuri_seqi_pack_hindexed_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)217 int yaksuri_seqi_pack_hindexed_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
218 {
219     int rc = YAKSA_SUCCESS;
220     const char *restrict sbuf = (const char *) inbuf;
221     char *restrict dbuf = (char *) outbuf;
222     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
223 
224     int count1 = type->u.hindexed.count;
225     int *restrict array_of_blocklengths1 = type->u.hindexed.array_of_blocklengths;
226     intptr_t *restrict array_of_displs1 = type->u.hindexed.array_of_displs;
227     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
228 
229     int count2 = type->u.hindexed.child->u.contig.count;
230     intptr_t stride2 = type->u.hindexed.child->u.contig.child->extent;
231     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.hindexed.child->extent;
232 
233     int count3 = type->u.hindexed.child->u.contig.child->u.contig.count;
234     intptr_t stride3 = type->u.hindexed.child->u.contig.child->u.contig.child->extent;
235     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.hindexed.child->u.contig.child->extent;
236 
237     uintptr_t idx = 0;
238     for (int i = 0; i < count; i++) {
239         for (int j1 = 0; j1 < count1; j1++) {
240             for (int k1 = 0; k1 < array_of_blocklengths1[j1]; k1++) {
241                 for (int j2 = 0; j2 < count2; j2++) {
242                     for (int j3 = 0; j3 < count3; j3++) {
243                         *((long double *) (void *) (dbuf + idx)) = *((const long double *) (const void *) (sbuf + i * extent + array_of_displs1[j1] + k1 * extent2 + j2 * stride2 + j3 * stride3));
244                         idx += sizeof(long double);
245                     }
246                 }
247             }
248         }
249     }
250 
251     return rc;
252 }
253 
yaksuri_seqi_unpack_hindexed_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)254 int yaksuri_seqi_unpack_hindexed_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
255 {
256     int rc = YAKSA_SUCCESS;
257     const char *restrict sbuf = (const char *) inbuf;
258     char *restrict dbuf = (char *) outbuf;
259     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
260 
261     int count1 = type->u.hindexed.count;
262     int *restrict array_of_blocklengths1 = type->u.hindexed.array_of_blocklengths;
263     intptr_t *restrict array_of_displs1 = type->u.hindexed.array_of_displs;
264     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
265 
266     int count2 = type->u.hindexed.child->u.contig.count;
267     intptr_t stride2 = type->u.hindexed.child->u.contig.child->extent;
268     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.hindexed.child->extent;
269 
270     int count3 = type->u.hindexed.child->u.contig.child->u.contig.count;
271     intptr_t stride3 = type->u.hindexed.child->u.contig.child->u.contig.child->extent;
272     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.hindexed.child->u.contig.child->extent;
273 
274     uintptr_t idx = 0;
275     for (int i = 0; i < count; i++) {
276         for (int j1 = 0; j1 < count1; j1++) {
277             for (int k1 = 0; k1 < array_of_blocklengths1[j1]; k1++) {
278                 for (int j2 = 0; j2 < count2; j2++) {
279                     for (int j3 = 0; j3 < count3; j3++) {
280                         *((long double *) (void *) (dbuf + i * extent + array_of_displs1[j1] + k1 * extent2 + j2 * stride2 + j3 * stride3)) = *((const long double *) (const void *) (sbuf + idx));
281                         idx += sizeof(long double);
282                     }
283                 }
284             }
285         }
286     }
287 
288     return rc;
289 }
290 
yaksuri_seqi_pack_contig_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)291 int yaksuri_seqi_pack_contig_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
292 {
293     int rc = YAKSA_SUCCESS;
294     const char *restrict sbuf = (const char *) inbuf;
295     char *restrict dbuf = (char *) outbuf;
296     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
297 
298     int count1 = type->u.contig.count;
299     intptr_t stride1 = type->u.contig.child->extent;
300     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
301 
302     int count2 = type->u.contig.child->u.contig.count;
303     intptr_t stride2 = type->u.contig.child->u.contig.child->extent;
304     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.contig.child->extent;
305 
306     int count3 = type->u.contig.child->u.contig.child->u.contig.count;
307     intptr_t stride3 = type->u.contig.child->u.contig.child->u.contig.child->extent;
308     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.contig.child->u.contig.child->extent;
309 
310     uintptr_t idx = 0;
311     for (int i = 0; i < count; i++) {
312         for (int j1 = 0; j1 < count1; j1++) {
313             for (int j2 = 0; j2 < count2; j2++) {
314                 for (int j3 = 0; j3 < count3; j3++) {
315                     *((long double *) (void *) (dbuf + idx)) = *((const long double *) (const void *) (sbuf + i * extent + j1 * stride1 + j2 * stride2 + j3 * stride3));
316                     idx += sizeof(long double);
317                 }
318             }
319         }
320     }
321 
322     return rc;
323 }
324 
yaksuri_seqi_unpack_contig_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)325 int yaksuri_seqi_unpack_contig_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
326 {
327     int rc = YAKSA_SUCCESS;
328     const char *restrict sbuf = (const char *) inbuf;
329     char *restrict dbuf = (char *) outbuf;
330     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
331 
332     int count1 = type->u.contig.count;
333     intptr_t stride1 = type->u.contig.child->extent;
334     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
335 
336     int count2 = type->u.contig.child->u.contig.count;
337     intptr_t stride2 = type->u.contig.child->u.contig.child->extent;
338     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.contig.child->extent;
339 
340     int count3 = type->u.contig.child->u.contig.child->u.contig.count;
341     intptr_t stride3 = type->u.contig.child->u.contig.child->u.contig.child->extent;
342     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.contig.child->u.contig.child->extent;
343 
344     uintptr_t idx = 0;
345     for (int i = 0; i < count; i++) {
346         for (int j1 = 0; j1 < count1; j1++) {
347             for (int j2 = 0; j2 < count2; j2++) {
348                 for (int j3 = 0; j3 < count3; j3++) {
349                     *((long double *) (void *) (dbuf + i * extent + j1 * stride1 + j2 * stride2 + j3 * stride3)) = *((const long double *) (const void *) (sbuf + idx));
350                     idx += sizeof(long double);
351                 }
352             }
353         }
354     }
355 
356     return rc;
357 }
358 
yaksuri_seqi_pack_resized_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)359 int yaksuri_seqi_pack_resized_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
360 {
361     int rc = YAKSA_SUCCESS;
362     const char *restrict sbuf = (const char *) inbuf;
363     char *restrict dbuf = (char *) outbuf;
364     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
365 
366     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
367 
368     int count2 = type->u.resized.child->u.contig.count;
369     intptr_t stride2 = type->u.resized.child->u.contig.child->extent;
370     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.resized.child->extent;
371 
372     int count3 = type->u.resized.child->u.contig.child->u.contig.count;
373     intptr_t stride3 = type->u.resized.child->u.contig.child->u.contig.child->extent;
374     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.resized.child->u.contig.child->extent;
375 
376     uintptr_t idx = 0;
377     for (int i = 0; i < count; i++) {
378         for (int j2 = 0; j2 < count2; j2++) {
379             for (int j3 = 0; j3 < count3; j3++) {
380                 *((long double *) (void *) (dbuf + idx)) = *((const long double *) (const void *) (sbuf + i * extent + j2 * stride2 + j3 * stride3));
381                 idx += sizeof(long double);
382             }
383         }
384     }
385 
386     return rc;
387 }
388 
yaksuri_seqi_unpack_resized_contig_contig_long_double(const void * inbuf,void * outbuf,uintptr_t count,yaksi_type_s * type)389 int yaksuri_seqi_unpack_resized_contig_contig_long_double(const void *inbuf, void *outbuf, uintptr_t count, yaksi_type_s * type)
390 {
391     int rc = YAKSA_SUCCESS;
392     const char *restrict sbuf = (const char *) inbuf;
393     char *restrict dbuf = (char *) outbuf;
394     uintptr_t extent ATTRIBUTE((unused)) = type->extent;
395 
396     uintptr_t extent1 ATTRIBUTE((unused)) = type->extent;
397 
398     int count2 = type->u.resized.child->u.contig.count;
399     intptr_t stride2 = type->u.resized.child->u.contig.child->extent;
400     uintptr_t extent2 ATTRIBUTE((unused)) = type->u.resized.child->extent;
401 
402     int count3 = type->u.resized.child->u.contig.child->u.contig.count;
403     intptr_t stride3 = type->u.resized.child->u.contig.child->u.contig.child->extent;
404     uintptr_t extent3 ATTRIBUTE((unused)) = type->u.resized.child->u.contig.child->extent;
405 
406     uintptr_t idx = 0;
407     for (int i = 0; i < count; i++) {
408         for (int j2 = 0; j2 < count2; j2++) {
409             for (int j3 = 0; j3 < count3; j3++) {
410                 *((long double *) (void *) (dbuf + i * extent + j2 * stride2 + j3 * stride3)) = *((const long double *) (const void *) (sbuf + idx));
411                 idx += sizeof(long double);
412             }
413         }
414     }
415 
416     return rc;
417 }
418 
419