source: buchla-68k/alcyon/strspn.s@ 4b63bf3

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

Added Alcyon C reference output.

  • Property mode set to 100644
File size: 662 bytes
Line 
1.globl _strspn
2.text
3_strspn:
4~~strspn:
5~charset=R13
6~string=8
7link R14,#0
8movem.l R6-R7/R11-R13,-(sp)
9~p=R12
10~q=R11
11~n=R7
12*line 17
13clr R7
14*line 19
15move.l 12(R14),R13
16*line 19
17move.l 8(R14),R11
18bra L4
19L5:
20*line 20
21*line 21
22move.l R13,R12
23bra L8
24L9:L7:
25*line 21
26add.l #1,R12
27L8:
28*line 21
29tst.b (R12)
30beq L10000
31move.b (R12),R0
32ext.w R0
33cmp.b (R11),R0
34bne L9
35L10000:L6:
36*line 22
37*line 23
38*line 24
39*line 25
40tst.b (R12)
41beq L2
42*line 26
43*line 27
44add #1,R7
45L3:
46*line 19
47add.l #1,R11
48L4:
49*line 19
50tst.b (R11)
51bne L5
52L2:
53*line 30
54move R7,R0
55bra L1
56L1:tst.l (sp)+
57movem.l (sp)+,R7-R7/R11-R13
58unlk R14
59rts
60.data
Note: See TracBrowser for help on using the repository browser.