source: buchla-68k/alcyon/itcpos.s@ 9519422

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

Added Alcyon C reference output.

  • Property mode set to 100644
File size: 3.6 KB
Line 
1.globl _v_obtab
2.globl _v_curob
3.globl _v_nobj
4.globl _v_obpri
5.globl _io_time
6.globl _io_lcd
7.globl _io_ser
8.globl _io_midi
9.globl _io_disk
10.globl _io_tone
11.globl _io_leds
12.globl _io_kbrd
13.globl _lcd_a0
14.globl _lcd_a1
15.globl _io_vreg
16.globl _io_vraw
17.globl _io_vram
18.globl _io_fpu
19.globl _v_regs
20.globl _v_odtab
21.globl _v_actab
22.globl _v_ct0
23.globl _v_gt1
24.globl _v_score
25.globl _v_cgtab
26.globl _v_curs0
27.globl _v_curs1
28.globl _v_curs2
29.globl _v_curs3
30.globl _v_curs4
31.globl _v_curs5
32.globl _v_curs6
33.globl _v_curs7
34.globl _v_tcur
35.globl _v_kbobj
36.globl _v_lnobj
37.globl _v_win0
38.globl _v_cur
39.globl _fc_sw
40.globl _fc_val
41.globl _ebflag
42.globl _ebuf
43.globl _curfet
44.globl _cfetp
45.globl _infetp
46.globl _stcrow
47.globl _stccol
48.globl _obj0
49.data
50L1:.dc.w $0
51.dc.w $0
52.dc.w $0
53.dc.w $0
54.dc.w $0
55.dc.w $0
56.dc.w $0
57.dc.w $0
58.dc.w $0
59.dc.w $0
60.dc.w $0
61.dc.w $0
62.dc.w $0
63.dc.w $0
64.dc.w $0
65.dc.w $0
66.dc.w $0
67.dc.w $0
68.dc.w $0
69.dc.w $0
70.dc.w $0
71.dc.w $0
72.dc.w $0
73.dc.w $0
74.dc.w $0
75.dc.w $0
76.dc.w $0
77.dc.w $0
78.dc.w $0
79.dc.w $0
80.dc.w $0
81.dc.w $0
82.dc.w $0
83.dc.w $0
84.dc.w $0
85.dc.w $0
86.dc.w $0
87.dc.w $0
88.dc.w $0
89.dc.w $0
90.dc.w $0
91.dc.w $0
92.dc.w $0
93.dc.w $0
94.dc.w $0
95.dc.w $0
96.dc.w $0
97.dc.w $0
98.dc.w $FFFF
99.dc.w $FFFF
100.dc.w $0
101.dc.w $0
102.dc.w $0
103.dc.w $0
104.dc.w $0
105.dc.w $0
106.dc.w $0
107.dc.w $0
108.dc.w $0
109.dc.w $0
110.dc.w $0
111.dc.w $0
112.dc.w $0
113.dc.w $0
114.text
115.globl _itcini
116.text
117_itcini:
118~~itcini:
119~color=8
120link R14,#-4
121*line 64
122*line 65
123clr R0
124move 10+_v_regs,R0
125and #384,R0
126cmp #256,R0
127beq L3
128*line 65
129move #1,(sp)
130jsr _vbank
131*line 66
132L3:
133*line 67
134move #64,(sp)
135move 8(R14),-(sp)
136jsr _exp_c
137addq.l #2,sp
138move R0,-(sp)
139move.l #L1,-(sp)
140move.l #_v_cur,-(sp)
141jsr _andcopy
142adda.l #10,sp
143L2:unlk R14
144rts
145.globl _itcpos
146.text
147_itcpos:
148~~itcpos:
149~row=R7
150~col=R6
151link R14,#0
152movem.l R3-R7/R13-R13,-(sp)
153~yrow=R5
154~xcol=R4
155~op=R13
156*line 85
157move 8(R14),R7
158*line 85
159move 10(R14),R6
160*line 85
161*line 86
162clr R0
163move 10+_v_regs,R0
164and #384,R0
165beq L5
166*line 86
167clr (sp)
168jsr _vbank
169*line 87
170L5:
171*line 88
172move R7,R5
173muls #14,R5
174*line 89
175move R6,R4
176asl #3,R4
177*line 91
178move.l #_v_obtab,R13
179*line 92
180move #1,(sp)
181jsr _setipl
182*line 93
183and #-17,120+_v_odtab
184*line 94
185move #15,(sp)
186jsr _objclr
187*line 96
188move R4,4(R13)
189*line 97
190move R5,6(R13)
191*line 98
192move.l #_v_cur,8(R13)
193*line 99
194move R4,R0
195asr #1,R0
196and #1023,R0
197or #1024,R0
198move R0,16(R13)
199*line 101
200move #15,(sp)
201clr -(sp)
202jsr _SetPri
203addq.l #2,sp
204*line 103
205move R7,_stcrow
206*line 104
207move R6,_stccol
208L4:tst.l (sp)+
209movem.l (sp)+,R4-R7/R13-R13
210unlk R14
211rts
212.globl _advicur
213.text
214_advicur:
215~~advicur:
216link R14,#0
217movem.l R6-R7,-(sp)
218~newcol=R7
219*line 120
220*line 121
221move.l _curfet,(sp)
222move _stccol,-(sp)
223move _stcrow,-(sp)
224jsr _infield
225addq.l #4,sp
226tst R0
227beq L7
228*line 121
229move.l _infetp,_cfetp
230*line 122
231bra L8
232L7:bra L6
233L8:
234*line 125
235move _stccol,R7
236add #1,R7
237*line 127
238*line 128
239move.l _cfetp,R8
240cmp 4(R8),R7
241bgt L9
242*line 128
243move R7,(sp)
244move _stcrow,-(sp)
245jsr _itcpos
246addq.l #2,sp
247L9:L6:tst.l (sp)+
248movem.l (sp)+,R7-R7
249unlk R14
250rts
251.globl _bspicur
252.text
253_bspicur:
254~~bspicur:
255link R14,#0
256movem.l R6-R7,-(sp)
257~newcol=R7
258*line 141
259*line 142
260move.l _curfet,(sp)
261move _stccol,-(sp)
262move _stcrow,-(sp)
263jsr _infield
264addq.l #4,sp
265tst R0
266beq L11
267*line 142
268move.l _infetp,_cfetp
269*line 143
270bra L12
271L11:bra L10
272L12:
273*line 146
274move _stccol,R7
275sub #1,R7
276*line 148
277*line 149
278move.l _cfetp,R8
279cmp 2(R8),R7
280blt L13
281*line 149
282move R7,(sp)
283move _stcrow,-(sp)
284jsr _itcpos
285addq.l #2,sp
286L13:L10:tst.l (sp)+
287movem.l (sp)+,R7-R7
288unlk R14
289rts
290.data
Note: See TracBrowser for help on using the repository browser.