repo.or.cz
/
sdcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
struct / union in initializer, RFE #901.
[sdcc.git]
/
sdcc
/
support
/
regression
/
tests
/
gcc-torture-execute-loop-2d.c
blob
36f5b2a505a3dbcec4639bf83b3915eec379d2c9
1
/*
2
loop-2d.c from the execute part of the gcc torture tests.
3
*/
4
5
#include <testfwk.h>
6
7
#ifdef __SDCC
8
#pragma std_c99
9
#endif
10
11
int
a
[
2
];
12
13
void
f
(
int
b
)
14
{
15
unsigned int
i
;
16
int
*
p
;
17
for
(
p
= &
a
[
b
],
i
=
b
; --
i
< ~
0
; )
18
*--
p
=
i
*
3
+ (
int
)
a
;
19
}
20
21
void
22
testTortureExecute
(
void
)
23
{
24
a
[
0
] =
a
[
1
] =
0
;
25
f
(
2
);
26
if
(
a
[
0
] != (
int
)
a
||
a
[
1
] != (
int
)
a
+
3
)
27
ASSERT
(
0
);
28
return
;
29
}