annotate lib/kreiderclib/atol.as @ 3226:9749d0dfc4a2

Changed a puls PC to rts to save cycles
author David Ladd <drencor-xeen@users.sourceforge.net>
date Sat, 20 Jan 2018 19:32:22 -0600
parents 1647f1874cdf
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2824
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
1 * Disassembly by Os9disasm of atol.r
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
2
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
3 section code
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
4
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
5 * class D external label equates
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
6
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
7 D0000 equ $0000
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
8 D000a equ $000a
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
9
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
10 atol: pshs u
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
11 ldu 4,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
12 clra
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
13 clrb
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
14 pshs b
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
15 pshs d
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
16 pshs d
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
17 L000c ldb ,u+
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
18 cmpb #$20
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
19 beq L000c
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
20 cmpb #9
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
21 beq L000c
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
22 cmpb #$2d
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
23 bne L001e
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
24 stb 4,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
25 bra L0045
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
26 L001e cmpb #$2b
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
27 bne L0047
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
28 bra L0045
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
29 L0024 ldd 2,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
30 pshs d
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
31 ldd 2,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
32 pshs d
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
33 leax >L006c,pcr
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
34 lbsr _lmul
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
35 ldb -1,u
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
36 clra
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
37 subb #$30
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
38 addd 2,x
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
39 std 2,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
40 ldd #0
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
41 adcb 1,x
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
42 adca ,x
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
43 std ,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
44 L0045 ldb ,u+
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
45 L0047 clra
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
46 leax _chcodes,y
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
47 ldb d,x
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
48 andb #8
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
49 bne L0024
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
50 tst 4,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
51 beq L005d
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
52 leax ,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
53 lbsr _lneg
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
54 bra L005f
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
55 L005d leax ,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
56 L005f leau _flacc,y
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
57 pshs u
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
58 lbsr _lmove
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
59 leas 5,s
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
60 puls u,pc
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
61 L006c neg D0000
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
62 neg D000a
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
63
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
64 endsect
1647f1874cdf Added Kreidier C library
Boisy Pitre <boisy.pitre@nuance.com>
parents:
diff changeset
65