source: buchla-68k/alcyon/etagch.s@ fe7b401

Last change on this file since fe7b401 was 7bf3856, checked in by Thomas Lopatic <thomas@…>, 7 years ago

Added Alcyon C reference output.

  • Property mode set to 100644
File size: 3.2 KB
Line 
1.globl _ebflag
2.globl _ebuf
3.globl _curfet
4.globl _cfetp
5.globl _infetp
6.globl _asgob
7.globl _stcrow
8.globl _stccol
9.globl _adbox
10.globl _dspbuf
11.globl _grp2prt
12.globl _et_agch
13.text
14_et_agch:
15~~et_agch:
16~n=8
17link R14,#-4
18movem.l R6-R7,-(sp)
19~grp=R7
20~buf=-4
21*line 47
22move 8(R14),R7
23asr #8,R7
24and #255,R7
25*line 49
26move R7,R8
27add.l R8,R8
28add.l R8,R8
29move.l #_grp2prt,R9
30move 2(R8,R9.l),(sp)
31move.l #_ebuf,-(sp)
32jsr _numblk
33addq.l #4,sp
34*line 50
35move #1,_ebflag
36*line 52
37clr R0
38bra L1
39L1:tst.l (sp)+
40movem.l (sp)+,R7-R7
41unlk R14
42rts
43.globl _ef_agch
44.text
45_ef_agch:
46~~ef_agch:
47~n=8
48link R14,#0
49movem.l R4-R7,-(sp)
50~tmpval=R7
51~grp=R6
52~i=R5
53*line 67
54move 8(R14),R6
55asr #8,R6
56and #255,R6
57*line 69
58clr.b 2+_ebuf
59*line 70
60clr _ebflag
61*line 71
62clr R7
63*line 73
64*line 73
65cmp.b #32,_ebuf
66bne L3
67cmp.b #32,1+_ebuf
68bne L3
69*line 74
70*line 75
71move #-1,R7
72*line 76
73bra L4
74L3:
75*line 77
76*line 78
77*line 79
78clr R5
79bra L7
80L8:
81*line 80
82*line 81
83*line 82
84move R5,R8
85add.l #_ebuf,R8
86cmp.b #32,(R8)
87bne L9
88*line 82
89move R5,R8
90add.l #_ebuf,R8
91move.b #48,(R8)
92*line 83
93L9:
94*line 84
95muls #10,R7
96move.l #_ebuf,R8
97move.b 0(R8,R5),R0
98ext.w R0
99add R0,R7
100add #-48,R7
101L6:
102*line 79
103add #1,R5
104L7:
105*line 79
106cmp #2,R5
107blt L8
108L5:
109*line 85
110*line 86
111*line 87
112*line 88
113tst R7
114beq L10000
115cmp #16,R7
116ble L10
117L10000:*line 88
118move #-1,R0
119bra L2
120L10:L4:
121*line 91
122move R6,R8
123add.l R8,R8
124add.l R8,R8
125add.l #_grp2prt,R8
126move R7,2(R8)
127*line 93
128jsr _modasg
129*line 94
130clr R0
131bra L2
132L2:tst.l (sp)+
133movem.l (sp)+,R5-R7
134unlk R14
135rts
136.globl _rd_agch
137.text
138_rd_agch:
139~~rd_agch:
140~nn=8
141link R14,#-4
142movem.l R5-R7,-(sp)
143~n=R7
144~grp=R6
145~buf=-4
146*line 113
147move 8(R14),R7
148and #255,R7
149*line 114
150move 8(R14),R6
151asr #8,R6
152and #255,R6
153*line 116
154clr (sp)
155jsr _vbank
156*line 117
157*line 118
158move #14,(sp)
159move R6,R8
160add.l R8,R8
161add.l R8,R8
162move.l #_grp2prt,R9
163move 2(R8,R9.l),-(sp)
164move.l R14,-(sp)
165sub.l #4,(sp)
166jsr _numblk
167addq.l #6,sp
168move.l R0,-(sp)
169move.l _cfetp,R8
170move 2(R8),-(sp)
171move.l _cfetp,R8
172move (R8),-(sp)
173move R7,R0
174asl #4,R0
175ext.l R0
176move.l R0,R8
177move.l #_adbox,R9
178move 10(R8,R9.l),-(sp)
179move R7,R0
180asl #4,R0
181ext.l R0
182move.l R0,R8
183move.l #_adbox,R9
184move 8(R8,R9.l),-(sp)
185move #64,-(sp)
186move.l _asgob,-(sp)
187jsr _vcputsv
188adda.l #18,sp
189*line 120
190clr R0
191bra L11
192L11:tst.l (sp)+
193movem.l (sp)+,R6-R7
194unlk R14
195rts
196.globl _nd_agch
197.text
198_nd_agch:
199~~nd_agch:
200~k=R7
201~nn=8
202link R14,#0
203movem.l R5-R7,-(sp)
204~n=R6
205*line 136
206move 10(R14),R7
207*line 136
208move 8(R14),R6
209and #255,R6
210*line 137
211move R7,R0
212add #48,R0
213move _stccol,R9
214move.l _cfetp,R10
215move 2(R10),R10
216sub R10,R9
217add.l #_ebuf,R9
218move.b R0,(R9)
219*line 138
220clr.b 2+_ebuf
221*line 140
222move R7,R0
223add #48,R0
224move.b R0,_dspbuf
225*line 141
226clr.b 1+_dspbuf
227*line 143
228clr (sp)
229jsr _vbank
230*line 144
231*line 145
232move #14,(sp)
233move.l #_dspbuf,-(sp)
234move _stccol,-(sp)
235move _stcrow,-(sp)
236move R6,R0
237asl #4,R0
238ext.l R0
239move.l R0,R8
240move.l #_adbox,R9
241move 10(R8,R9.l),-(sp)
242move #12,-(sp)
243move #64,-(sp)
244move.l _asgob,-(sp)
245jsr _vcputsv
246adda.l #18,sp
247*line 147
248jsr _advacur
249*line 148
250clr R0
251bra L12
252L12:tst.l (sp)+
253movem.l (sp)+,R6-R7
254unlk R14
255rts
256.data
Note: See TracBrowser for help on using the repository browser.