source: buchla-68k/alcyon/etloc.s@ f7c91fc

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

Added Alcyon C reference output.

  • Property mode set to 100644
File size: 6.5 KB
Line 
1.globl _ebflag
2.globl _ebuf
3.globl _curfet
4.globl _cfetp
5.globl _infetp
6.globl _io_time
7.globl _io_lcd
8.globl _io_ser
9.globl _io_midi
10.globl _io_disk
11.globl _io_tone
12.globl _io_leds
13.globl _io_kbrd
14.globl _lcd_a0
15.globl _lcd_a1
16.globl _io_vreg
17.globl _io_vraw
18.globl _io_vram
19.globl _io_fpu
20.globl _v_regs
21.globl _v_odtab
22.globl _v_actab
23.globl _v_ct0
24.globl _v_gt1
25.globl _v_score
26.globl _v_cgtab
27.globl _v_curs0
28.globl _v_curs1
29.globl _v_curs2
30.globl _v_curs3
31.globl _v_curs4
32.globl _v_curs5
33.globl _v_curs6
34.globl _v_curs7
35.globl _v_tcur
36.globl _v_kbobj
37.globl _v_lnobj
38.globl _v_win0
39.globl _v_cur
40.globl _fc_sw
41.globl _fc_val
42.globl _ac_code
43.globl _scname
44.globl _se_chg
45.globl _curscor
46.globl _cursect
47.globl _se1_cnt
48.globl _se2_cnt
49.globl _se3_cnt
50.globl _spool
51.globl _pspool
52.globl _spcount
53.globl _frags
54.globl _t_bak
55.globl _t_cur
56.globl _t_ctr
57.globl _t_fwd
58.globl _size1
59.globl _size2
60.globl _size3
61.globl _scores
62.globl _scp
63.globl _seclist
64.globl _hplist
65.globl _p_bak
66.globl _p_cur
67.globl _p_ctr
68.globl _p_fwd
69.globl _obj8
70.globl _curintp
71.globl _ctrsw
72.globl _timemlt
73.globl _recsw
74.globl _stccol
75.globl _grploc
76.globl _grpmode
77.globl _grpstat
78.globl _loctab
79.globl _vce2grp
80.globl _expbit
81.globl _gdstbc
82.globl _vbufs
83.globl _et_loc
84.text
85_et_loc:
86~~et_loc:
87~n=8
88link R14,#-4
89*line 58
90move 8(R14),R8
91add.l R8,R8
92move.l #_grploc,R9
93move 0(R8,R9.l),R0
94add #49,R0
95move.b R0,_ebuf
96*line 59
97clr.b 1+_ebuf
98*line 60
99move #1,_ebflag
100*line 61
101clr R0
102bra L1
103L1:unlk R14
104rts
105.globl _setloc
106.text
107_setloc:
108~~setloc:
109~grp=8
110~loc=10
111link R14,#-8
112movem.l R3-R7/R12-R13,-(sp)
113~g=R7
114~i=R6
115~val=R5
116~ltmp=R4
117~fpu=R13
118~fp=R12
119~fpmant=-2
120~fpexp=-4
121~oldsr=-6
122~nop=-8
123*line 84
124move 8(R14),R8
125add.l R8,R8
126add.l #_grploc,R8
127move 10(R14),(R8)
128*line 85
129move 10(R14),R8
130add.l R8,R8
131add.l #_loctab,R8
132move (R8),R5
133asl R5
134eor #-32768,R5
135*line 86
136move 8(R14),R7
137add #1,R7
138*line 88
139*line 89
140move _timemlt,R0
141ext.l R0
142and.l #$ffff,R0
143move.l R0,-(sp)
144clr.l R0
145move _curintp,R0
146and.l #$fff0,R0
147move.l R0,-(sp)
148jsr lmul
149addq.l #8,sp
150move.l #$f,R1
151asr.l R1,R0
152move R0,-2(R14)
153*line 91
154clr R0
155move _curintp,R0
156and #15,R0
157lsl #1,R0
158swap R0
159clr R0
160swap R0
161add.l #_expbit,R0
162move.l R0,R8
163move (R8),-4(R14)
164*line 95
165clr R6
166bra L5
167L6:
168*line 96
169*line 96
170move R6,R8
171add.l R8,R8
172add.l #_vce2grp,R8
173cmp (R8),R7
174bne L7
175*line 97
176*line 98
177move R6,R0
178muls #3938,R0
179move.l R0,R12
180add.l #_vbufs,R12
181add.l #134,R12
182*line 99
183move R6,R0
184asl #8,R0
185asl #1,R0
186ext.l R0
187move.l R0,R13
188add.l #_io_fpu,R13
189add.l #$4080,R13
190*line 100
191*line 101
192move #8704,(sp)
193jsr _setsr
194move R0,-6(R14)
195*line 102
196*line 103
197*line 104
198*line 105
199eor.b #24,7(R12)
200*line 106
201*line 107
202move.l R13,R8
203add.l #$14,R8
204move -2(R14),(R8)
205*line 108
206add #1,-8(R14)
207*line 108
208add #1,-8(R14)
209*line 108
210add #1,-8(R14)
211*line 109
212move.l R13,R8
213add.l #$16,R8
214move -4(R14),(R8)
215*line 110
216add #1,-8(R14)
217*line 110
218add #1,-8(R14)
219*line 110
220add #1,-8(R14)
221*line 111
222*line 112
223*line 113
224btst #3,7(R12)
225beq L8
226*line 113
227move.l R13,R8
228add.l #$1c,R8
229move R5,(R8)
230*line 114
231bra L9
232L8:
233*line 115
234move.l R13,R8
235add.l #$2,R8
236move R5,(R8)
237L9:
238*line 116
239*line 117
240add #1,-8(R14)
241*line 117
242add #1,-8(R14)
243*line 117
244add #1,-8(R14)
245*line 118
246*line 119
247*line 120
248move.b 7(R12),R0
249ext.w R0
250and #28,R0
251or #1,R0
252move R0,(R13)
253*line 121
254*line 122
255move -6(R14),(sp)
256jsr _setsr
257*line 123
258*line 124
259*line 125
260*line 126
261L7:L4:
262*line 95
263add #1,R6
264L5:
265*line 95
266cmp #12,R6
267blt L6
268L3:L2:tst.l (sp)+
269movem.l (sp)+,R4-R7/R12-R13
270unlk R14
271rts
272.globl _ef_loc
273.text
274_ef_loc:
275~~ef_loc:
276~n=8
277link R14,#0
278movem.l R6-R7/R13-R13,-(sp)
279~ival=R7
280~ep=R13
281*line 145
282clr.b 1+_ebuf
283*line 146
284move.b _ebuf,R7
285ext.w R7
286add #-48,R7
287*line 147
288clr _ebflag
289*line 149
290*line 150
291tst R7
292bne L11
293*line 150
294move #-1,R0
295bra L10
296*line 151
297L11:
298*line 152
299sub #1,R7
300*line 154
301move R7,(sp)
302move 8(R14),-(sp)
303jsr _setloc
304addq.l #2,sp
305*line 156
306*line 156
307tst _recsw
308beq L12
309move 8(R14),R8
310add.l R8,R8
311move.l #_grpstat,R9
312tst 0(R8,R9.l)
313beq L12
314move 8(R14),R8
315add.l R8,R8
316add.l #_grpmode,R8
317cmp #2,(R8)
318bne L12
319*line 157
320*line 158
321*line 158
322move #-1,(sp)
323move 8(R14),-(sp)
324move #12,-(sp)
325move.l _t_cur,-(sp)
326move.l _p_cur,-(sp)
327jsr _findev
328adda.l #12,sp
329move.l R0,R13
330move.l R13,R0
331beq L13
332*line 159
333*line 160
334move.b R7,7(R13)
335*line 161
336bra L14
337L13:
338*line 162
339*line 162
340move #6,(sp)
341jsr _e_alc
342move.l R0,R13
343move.l R13,R0
344beq L15
345*line 163
346*line 164
347move.b #12,5(R13)
348*line 165
349move 8(R14),R0
350move.b R0,6(R13)
351*line 166
352move.b R7,7(R13)
353*line 167
354move.l _t_cur,(R13)
355*line 168
356move.l _t_cur,(sp)
357clr -(sp)
358move.l _p_cur,-(sp)
359jsr _ep_adj
360addq.l #6,sp
361move.l R0,(sp)
362move.l R13,-(sp)
363jsr _e_ins
364addq.l #4,sp
365move.l R0,R8
366move.l 12(R8),_p_cur
367*line 169
368move #2,(sp)
369move.l R13,-(sp)
370jsr _eh_ins
371addq.l #4,sp
372*line 170
373move #1,_ctrsw
374*line 171
375move #1,(sp)
376move.l #_gdstbc,-(sp)
377clr -(sp)
378move.l R13,-(sp)
379jsr _se_disp
380adda.l #10,sp
381*line 172
382jsr _scupd
383*line 173
384L15:L14:
385*line 174
386*line 175
387L12:
388*line 176
389clr R0
390bra L10
391L10:tst.l (sp)+
392movem.l (sp)+,R7-R7/R13-R13
393unlk R14
394rts
395.globl _rd_loc
396.text
397_rd_loc:
398~~rd_loc:
399~n=8
400link R14,#-4
401*line 192
402*line 193
403clr R0
404move 10+_v_regs,R0
405and #384,R0
406beq L17
407*line 193
408clr (sp)
409jsr _vbank
410*line 194
411L17:
412*line 195
413move #18,(sp)
414move 8(R14),R8
415add.l R8,R8
416move.l #_grploc,R9
417move 0(R8,R9.l),-(sp)
418add #49,(sp)
419move 8(R14),R0
420muls #5,R0
421move R0,-(sp)
422add #8,(sp)
423move #4,-(sp)
424move.l _obj8,-(sp)
425jsr _vputc
426adda.l #10,sp
427*line 197
428clr R0
429bra L16
430L16:unlk R14
431rts
432.globl _ds_loc
433.text
434_ds_loc:
435~~ds_loc:
436link R14,#0
437movem.l R6-R7,-(sp)
438~i=R7
439*line 210
440clr R7
441bra L21
442L22:
443*line 211
444move R7,(sp)
445jsr _rd_loc
446L20:
447*line 210
448add #1,R7
449L21:
450*line 210
451cmp #12,R7
452blt L22
453L19:L18:tst.l (sp)+
454movem.l (sp)+,R7-R7
455unlk R14
456rts
457.globl _nd_loc
458.text
459_nd_loc:
460~~nd_loc:
461~n=R7
462~k=R6
463link R14,#0
464movem.l R5-R7,-(sp)
465*line 227
466move 8(R14),R7
467*line 227
468move 10(R14),R6
469*line 227
470move R6,R0
471add #48,R0
472move.b R0,_ebuf
473*line 229
474*line 230
475clr R0
476move 10+_v_regs,R0
477and #384,R0
478beq L24
479*line 230
480clr (sp)
481jsr _vbank
482*line 231
483L24:
484*line 232
485move #98,(sp)
486move R6,-(sp)
487add #48,(sp)
488move _stccol,-(sp)
489move #4,-(sp)
490move.l _obj8,-(sp)
491jsr _vputc
492adda.l #10,sp
493*line 233
494jsr _advscur
495*line 235
496clr R0
497bra L23
498L23:tst.l (sp)+
499movem.l (sp)+,R6-R7
500unlk R14
501rts
502.data
Note: See TracBrowser for help on using the repository browser.