source: buchla-68k/alcyon/etaprg.s@ 7c5def4

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

Added Alcyon C reference output.

  • Property mode set to 100644
File size: 2.7 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 _prgchan
10.globl _adbox
11.globl _dspbuf
12.globl _et_aprg
13.text
14_et_aprg:
15~~et_aprg:
16~n=8
17link R14,#-4
18*line 45
19move _prgchan,(sp)
20move.l #L2,-(sp)
21move.l #_ebuf,-(sp)
22jsr _sprintf
23addq.l #8,sp
24*line 46
25move #1,_ebflag
26*line 48
27clr R0
28bra L1
29L1:unlk R14
30rts
31.globl _ef_aprg
32.text
33_ef_aprg:
34~~ef_aprg:
35~n=8
36link R14,#0
37movem.l R5-R7,-(sp)
38~i=R7
39~tmpval=R6
40*line 63
41clr.b 2+_ebuf
42*line 64
43clr _ebflag
44*line 65
45clr R6
46*line 67
47clr R7
48bra L6
49L7:
50*line 68
51muls #10,R6
52move.l #_ebuf,R8
53move.b 0(R8,R7),R0
54ext.w R0
55add R0,R6
56add #-48,R6
57L5:
58*line 67
59add #1,R7
60L6:
61*line 67
62cmp #2,R7
63blt L7
64L4:
65*line 76
66*line 77
67tst R6
68beq L10000
69cmp #16,R6
70ble L8
71L10000:*line 77
72move #-1,R0
73bra L3
74*line 78
75L8:
76*line 79
77move R6,_prgchan
78*line 80
79clr R0
80bra L3
81L3:tst.l (sp)+
82movem.l (sp)+,R6-R7
83unlk R14
84rts
85.globl _rd_aprg
86.text
87_rd_aprg:
88~~rd_aprg:
89~nn=8
90link R14,#0
91movem.l R6-R7,-(sp)
92~n=R7
93*line 98
94move 8(R14),R7
95and #255,R7
96*line 99
97move _prgchan,(sp)
98move.l #L10,-(sp)
99move.l #_dspbuf,-(sp)
100jsr _sprintf
101addq.l #8,sp
102*line 101
103clr (sp)
104jsr _vbank
105*line 102
106*line 103
107move #14,(sp)
108move.l #_dspbuf,-(sp)
109move R7,R0
110asl #4,R0
111ext.l R0
112move.l R0,R8
113move.l #_adbox,R9
114move 14(R8,R9.l),-(sp)
115add #8,(sp)
116move R7,R0
117asl #4,R0
118ext.l R0
119move.l R0,R8
120move.l #_adbox,R9
121move 12(R8,R9.l),-(sp)
122move R7,R0
123asl #4,R0
124ext.l R0
125move.l R0,R8
126move.l #_adbox,R9
127move 10(R8,R9.l),-(sp)
128move R7,R0
129asl #4,R0
130ext.l R0
131move.l R0,R8
132move.l #_adbox,R9
133move 8(R8,R9.l),-(sp)
134move #64,-(sp)
135move.l _asgob,-(sp)
136jsr _vcputsv
137adda.l #18,sp
138*line 105
139clr R0
140bra L9
141L9:tst.l (sp)+
142movem.l (sp)+,R7-R7
143unlk R14
144rts
145.globl _nd_aprg
146.text
147_nd_aprg:
148~~nd_aprg:
149~k=R7
150~nn=8
151link R14,#0
152movem.l R4-R7,-(sp)
153~ec=R6
154~n=R5
155*line 121
156move 10(R14),R7
157*line 121
158move 8(R14),R5
159and #255,R5
160*line 123
161move _stccol,R6
162move.l _cfetp,R8
163move 2(R8),R0
164sub R0,R6
165*line 125
166move R7,R0
167add #48,R0
168move R6,R9
169add.l #_ebuf,R9
170move.b R0,(R9)
171*line 126
172clr.b 2+_ebuf
173*line 128
174move R7,R0
175add #48,R0
176move.b R0,_dspbuf
177*line 129
178clr.b 1+_dspbuf
179*line 131
180clr (sp)
181jsr _vbank
182*line 132
183move #14,(sp)
184move.l #_dspbuf,-(sp)
185move _stccol,-(sp)
186move _stcrow,-(sp)
187move R5,R0
188asl #4,R0
189ext.l R0
190move.l R0,R8
191move.l #_adbox,R9
192move 10(R8,R9.l),-(sp)
193move #12,-(sp)
194move #64,-(sp)
195move.l _asgob,-(sp)
196jsr _vcputsv
197adda.l #18,sp
198*line 134
199jsr _advacur
200*line 135
201clr R0
202bra L11
203L11:tst.l (sp)+
204movem.l (sp)+,R5-R7
205unlk R14
206rts
207.data
208L2:.dc.b $25,$30,$32,$64,$0
209L10:.dc.b $25,$30,$32,$2E,$32,$64,$0
Note: See TracBrowser for help on using the repository browser.