@@ -124,7 +124,7 @@ __MUL16NOADD:
124124
125125#line 20 "array.asm"
126126
127- #line 24 "/zbasic /library-asm/array.asm"
127+ #line 24 "/zxbasic /library-asm/array.asm"
128128
129129__ARRAY:
130130 PROC
@@ -147,10 +147,10 @@ __ARRAY:
147147 ld hl , 0 ; BC = Offset "accumulator"
148148
149149LOOP :
150- #line 49 "/zbasic /library-asm/array.asm"
150+ #line 49 "/zxbasic /library-asm/array.asm"
151151 pop bc ; Get next index (Ai) from the stack
152152
153- #line 59 "/zbasic /library-asm/array.asm"
153+ #line 59 "/zxbasic /library-asm/array.asm"
154154
155155 add hl , bc ; Adds current index
156156
@@ -168,7 +168,6 @@ LOOP:
168168 exx
169169 pop de ; DE = Max bound Number (i-th dimension)
170170
171- ;call __MUL16_FAST ; HL *= DE
172171 call __FNMUL
173172 jp LOOP
174173
@@ -180,7 +179,7 @@ ARRAY_END:
180179 push de
181180 exx
182181
183- #line 92 "/zbasic /library-asm/array.asm"
182+ #line 91 "/zxbasic /library-asm/array.asm"
184183 LOCAL ARRAY_SIZE_LOOP
185184
186185 ex de , hl
@@ -191,35 +190,13 @@ ARRAY_SIZE_LOOP:
191190 add hl , de
192191 djnz ARRAY_SIZE_LOOP
193192
194- ;; Even faster
195- ;pop bc
196-
197- ;ld d, h
198- ;ld e, l
199-
200- ;dec c
201- ;jp z, __ARRAY_FIN
202-
203- ;add hl, hl
204- ;dec c
205- ;jp z, __ARRAY_FIN
206-
207- ;add hl, hl
208- ;dec c
209- ;dec c
210- ;jp z, __ARRAY_FIN
211-
212- ;add hl, de
213- ;__ARRAY_FIN:
214- #line 123 "/zbasic/library-asm/array.asm"
193+ #line 102 "/zxbasic/library-asm/array.asm"
215194
216195 pop de
217196 add hl , de ; Adds element start
218197
219198RET_ADDRESS:
220- ld de , 0
221- push de
222- ret ; HL = (Start of Elements + Offset)
199+ jp 0
223200
224201 ;; Performs a faster multiply for little 16bit numbs
225202 LOCAL __FNMUL , __FNMUL2
@@ -229,10 +206,6 @@ __FNMUL:
229206 or d
230207 jp nz , __MUL16_FAST
231208
232- or e
233- ex de , hl
234- ret z
235-
236209 cp 33
237210 jp nc , __MUL16_FAST
238211
0 commit comments