53
|
1 #include "stdio.h"
|
|
2
|
|
3 struct arg {
|
|
4 int a0;int a1;int a2;int a3;int a4;
|
|
5 };
|
|
6
|
193
|
7 void *exit_env;
|
|
8 code (*exit_code)();
|
|
9
|
55
|
10 code carg1(int arg0,int arg1,int arg2,int arg3,int arg4,code(*exit1)(),void *env)
|
|
11 {
|
427
|
12 printf("#0011:arg1: %d %d %d %d %d : %x %x\n",arg0,arg1,arg2,arg3,arg4,exit1==exit_code,env==exit_env);
|
55
|
13 goto carg2(arg1,arg2,arg3,arg4,arg0,exit1,env);
|
|
14 }
|
|
15
|
|
16 code carg2(int arg0,int arg1,int arg2,int arg3,int arg4,code(*exit1)(),void *env)
|
53
|
17 {
|
|
18 struct arg args0;
|
427
|
19 printf("#0018:arg1: %d %d %d %d %d : %x %x\n",arg0,arg1,arg2,arg3,arg4,exit1==exit_code,env==exit_env );
|
53
|
20 args0.a0 = arg0;
|
|
21 args0.a1 = arg1;
|
|
22 args0.a2 = arg2;
|
|
23 args0.a3 = arg3;
|
|
24 args0.a4 = arg4;
|
55
|
25 goto cargs(args0,exit1,env);
|
53
|
26 }
|
|
27
|
55
|
28 code cargs(struct arg args0,code exit1(),void *env)
|
53
|
29 {
|
427
|
30 printf("#0029:args: %d %d %d %d %d : %x %x\n",
|
53
|
31 args0.a0,args0.a1,args0.a2,args0.a3,args0.a4,
|
193
|
32 exit1==exit_code,env==exit_env);
|
77
|
33 // goto exit1(321),env;
|
172
|
34 goto (*exit1)(0),env;
|
53
|
35 }
|
|
36
|
|
37
|
57
|
38 code carg3(struct arg args0,struct arg args1,int i, int j,int k,int l)
|
|
39 {
|
427
|
40 printf("#0039:args3: %d %d %d %d %d : %x %x %x %x\n",
|
79
|
41 args0.a0,args0.a1,args0.a2,args0.a3,args0.a4,i,j,k,l);
|
427
|
42 printf("#0041:args3: args0 %d %d %d %d %d : args1 %d %d %d %d %d : %x %x %x %x\n",
|
418
|
43 args0.a0,args0.a1,args0.a2,args0.a3,args0.a4,
|
|
44 args1.a0,args1.a1,args1.a2,args1.a3,args1.a4,
|
|
45 i,j,k,l);
|
172
|
46 if (args0.a0==args1.a0) exit(0);
|
57
|
47 goto carg4(args0,args1,j,k,l,i);
|
|
48 }
|
|
49
|
|
50 code carg4(struct arg args0,struct arg args1,int i, int j,int k,int l)
|
|
51 {
|
427
|
52 printf("#0051:args4: %d %d %d %d %d : %x %x %x %x\n",
|
79
|
53 args0.a0,args0.a1,args0.a2,args0.a3,args0.a4,i,j,k,l);
|
57
|
54 goto carg5(args1,args0,j,k,l,i);
|
|
55 }
|
|
56
|
|
57 code carg5(struct arg args0,struct arg args1,int i, int j,int k,int l)
|
|
58 {
|
427
|
59 printf("#0058:args5: %d %d %d %d %d : %x %x %x %x\n",
|
79
|
60 args0.a0,args0.a1,args0.a2,args0.a3,args0.a4,i,j,k,l);
|
57
|
61 goto carg6(i,j,k,l,args0);
|
|
62 }
|
|
63
|
|
64 code carg6(int i, int j,int k,int l,struct arg args0)
|
|
65 {
|
427
|
66 printf("#0065:args6: %d %d %d %d %d : %x %x %x %x\n",
|
79
|
67 args0.a0,args0.a1,args0.a2,args0.a3,args0.a4,i,j,k,l);
|
57
|
68 goto carg3(args0,args0,i,j,k,l);
|
|
69 }
|
|
70
|
54
|
71 int main1(int n)
|
|
72 {
|
193
|
73 goto carg1(0,1,2,3,4,exit_code=return,exit_env=environment);
|
54
|
74 return n;
|
|
75 }
|
|
76
|
79
|
77 struct arg a00;
|
|
78 struct arg a01;
|
|
79
|
53
|
80 int main( int ac, char *av[])
|
|
81 {
|
|
82 int n;
|
54
|
83 n = main1(123);
|
427
|
84 printf("#0083:321=%d\n",n);
|
79
|
85
|
|
86 a00.a0 = 11;
|
|
87 a00.a1 = 22;
|
|
88 a00.a2 = 33;
|
|
89 a00.a3 = 44;
|
|
90 a00.a4 = 55;
|
|
91 a01.a0 = 66;
|
|
92 a01.a1 = 77;
|
|
93 a01.a2 = 88;
|
|
94 a01.a3 = 99;
|
|
95 a01.a4 = 10;
|
|
96 goto carg3(a00,a01,1,2,3,4);
|
53
|
97 }
|
|
98
|