source: buchla-68k/alcyon/etwhar.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: 2.8 KB
Line 
1.globl _ebflag
2.globl _ebuf
3.globl _curfet
4.globl _cfetp
5.globl _infetp
6.globl _waveob
7.globl _stccol
8.globl _curwhrm
9.globl _wdbox
10.globl _dspbuf
11.globl _et_whar
12.text
13_et_whar:
14~~et_whar:
15~n=8
16link R14,#-4
17*line 40
18move _curwhrm,(sp)
19add #1,(sp)
20move.l #L2,-(sp)
21move.l #_ebuf,-(sp)
22jsr _sprintf
23addq.l #8,sp
24*line 41
25move #1,_ebflag
26*line 42
27clr R0
28bra L1
29L1:unlk R14
30rts
31.globl _ef_whar
32.text
33_ef_whar:
34~~ef_whar:
35~n=8
36link R14,#0
37movem.l R5-R7,-(sp)
38~i=R7
39~tmpval=R6
40*line 57
41clr.b 2+_ebuf
42*line 58
43clr _ebflag
44*line 60
45clr R6
46*line 62
47clr R7
48bra L6
49L7:
50*line 63
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 62
59add #1,R7
60L6:
61*line 62
62cmp #2,R7
63blt L7
64L4:
65*line 65
66*line 66
67cmp #32,R6
68bgt L10000
69tst R6
70bne L8
71L10000:*line 66
72move #-1,R0
73bra L3
74*line 67
75L8:
76*line 68
77move R6,R0
78sub #1,R0
79move R0,_curwhrm
80*line 69
81jsr _newws
82*line 70
83move #5,(sp)
84jsr _wdswin
85*line 71
86clr R0
87bra L3
88L3:tst.l (sp)+
89movem.l (sp)+,R6-R7
90unlk R14
91rts
92.globl _rd_whar
93.text
94_rd_whar:
95~~rd_whar:
96~nn=8
97link R14,#0
98movem.l R6-R7,-(sp)
99~n=R7
100*line 89
101move 8(R14),R7
102and #255,R7
103*line 90
104move _curwhrm,(sp)
105add #1,(sp)
106move.l #L10,-(sp)
107move.l #_dspbuf,-(sp)
108jsr _sprintf
109addq.l #8,sp
110*line 92
111clr (sp)
112jsr _vbank
113*line 93
114*line 94
115move #14,(sp)
116move.l #_dspbuf,-(sp)
117move R7,R0
118asl #4,R0
119ext.l R0
120move.l R0,R8
121move.l #_wdbox,R9
122move 14(R8,R9.l),-(sp)
123add #10,(sp)
124move R7,R0
125asl #4,R0
126ext.l R0
127move.l R0,R8
128move.l #_wdbox,R9
129move 12(R8,R9.l),-(sp)
130move R7,R0
131asl #4,R0
132ext.l R0
133move.l R0,R8
134move.l #_wdbox,R9
135move 10(R8,R9.l),-(sp)
136move R7,R0
137asl #4,R0
138ext.l R0
139move.l R0,R8
140move.l #_wdbox,R9
141move 8(R8,R9.l),-(sp)
142move #64,-(sp)
143move.l _waveob,-(sp)
144jsr _vcputsv
145adda.l #18,sp
146*line 96
147clr R0
148bra L9
149L9:tst.l (sp)+
150movem.l (sp)+,R7-R7
151unlk R14
152rts
153.globl _nd_whar
154.text
155_nd_whar:
156~~nd_whar:
157~k=R7
158~nn=8
159link R14,#0
160movem.l R4-R7,-(sp)
161~ec=R6
162~n=R5
163*line 112
164move 10(R14),R7
165*line 112
166move 8(R14),R5
167and #255,R5
168*line 113
169move _stccol,R6
170move.l _cfetp,R8
171move 2(R8),R0
172sub R0,R6
173*line 114
174move R7,R0
175add #48,R0
176move R6,R9
177add.l #_ebuf,R9
178move.b R0,(R9)
179*line 115
180clr.b 2+_ebuf
181*line 117
182move R7,R0
183add #48,R0
184move.b R0,_dspbuf
185*line 118
186clr.b 1+_dspbuf
187*line 120
188clr (sp)
189jsr _vbank
190*line 121
191*line 122
192move #14,(sp)
193move.l #_dspbuf,-(sp)
194move _stccol,-(sp)
195move R5,R0
196asl #4,R0
197ext.l R0
198move.l R0,R8
199move.l #_wdbox,R9
200move 12(R8,R9.l),-(sp)
201move R5,R0
202asl #4,R0
203ext.l R0
204move.l R0,R8
205move.l #_wdbox,R9
206move 10(R8,R9.l),-(sp)
207move #12,-(sp)
208move #64,-(sp)
209move.l _waveob,-(sp)
210jsr _vcputsv
211adda.l #18,sp
212*line 124
213jsr _advwcur
214*line 125
215clr R0
216bra L11
217L11:tst.l (sp)+
218movem.l (sp)+,R5-R7
219unlk R14
220rts
221.data
222L2:.dc.b $25,$30,$32,$64,$0
223L10:.dc.b $25,$30,$32,$64,$0
Note: See TracBrowser for help on using the repository browser.