3 !!ORIGIN!! SDCC regression tests
4 !!LICENCE!! GPL, read COPYING.GPL
10 unsigned char success=0;
11 unsigned char failures=0;
12 unsigned char dummy=0;
14 #ifdef SUPPORT_BIT_TYPES
17 unsigned int uint0 = 0;
18 unsigned int uint1 = 0;
19 unsigned char uchar0 = 0;
20 unsigned char uchar1 = 0;
22 void dput(unsigned char val)
35 /* both loops use the loop variable inside the inner loop */
42 for(i = 0; i < 3; i++) {
44 for(j = 0; j < 4; j++) {
56 /* only the outer loop's variable is used inside, inner can be optimized into a repeat-loop */
63 for(i = 0; i < 3; i++) {
65 for(j = 0; j < 4; j++) {
76 /* only the inner loop's variable is used inside */
83 for(i = 0; i < 3; i++) {
85 for(j = 0; j < 4; j++) {
96 /* neither loop variable used inside the loops */
103 for(i = 0; i < 3; i++) {
105 for(j = 0; j < 4; j++) {
117 /* like for1 but different condition in inner loop */
124 for(i = 0; i < 3; i++) {
126 for(j = 10; j >= 5; j--) {
148 printf("failures: %d\n",failures);