| 1 |
/* { dg-do assemble } */ |
| 2 |
/* { dg-skip-if "" { ! { clmcpu } } } */ |
| 3 |
/* { dg-options "-O3 -funroll-loops -mno-sdata -mcpu=arc700" } */ |
| 4 |
|
| 5 |
typedef long long a __attribute__((__mode__(__DI__))); |
| 6 |
typedef struct c c; |
| 7 |
|
| 8 |
struct b |
| 9 |
{ |
| 10 |
int d; |
| 11 |
c *e; |
| 12 |
}; |
| 13 |
|
| 14 |
enum { f }; |
| 15 |
|
| 16 |
typedef struct |
| 17 |
{ |
| 18 |
a g; |
| 19 |
a h; |
| 20 |
int i; |
| 21 |
} j; |
| 22 |
|
| 23 |
struct c |
| 24 |
{ |
| 25 |
int count; |
| 26 |
int current; |
| 27 |
}; |
| 28 |
|
| 29 |
int k; |
| 30 |
|
| 31 |
extern void bar (int, long long); |
| 32 |
int foo (struct b *demux, __builtin_va_list args) |
| 33 |
{ |
| 34 |
c m = *demux->e; |
| 35 |
j *n; |
| 36 |
switch (k) |
| 37 |
case f: |
| 38 |
{ |
| 39 |
a o = __builtin_va_arg(args, a); |
| 40 |
m.current = 0; |
| 41 |
while (m.current < m.count) |
| 42 |
{ |
| 43 |
if (n[m.current].h > o) { |
| 44 |
bar (demux->d, 4 + 128LL * n[m.current].i); |
| 45 |
break; |
| 46 |
} |
| 47 |
m.current++; |
| 48 |
} |
| 49 |
return 0; |
| 50 |
} |
| 51 |
} |