d28a86ee319e077848191f940363339c740832e7
[pdp8.git] / sw / f4 / FRTSRC / dmin1.ra
1 /
2 / VERSION 5A 4/26/77 MH
3 /
4 SECT DMIN1
5 BASE 0
6 DPCHK
7 DPMIN, SETX XR
8 MINCOM, STARTD
9 FLDA 0 /ADDRESS OF JA .+2+2*N
10 FSTA 3
11 FLDA 30 /RETURN ADDRESS
12 FSTA RETN
13 FLDA% 3 / JA .+2+2*N
14 FSUB 0 /-JA .
15 FSUB TWO /- 2
16 LDX 1,1
17 ALN 1 /DIVIDE BY TWO
18 FNEG /-N
19 ATX 1
20 LDX 0,2 /FOR ARG PICKUP
21 FLDA% 0,2+ /ADDRESS OF FIRST ARG
22 FSTA 3
23 STARTE
24 NEW, FLDA% 3 /SAVE NEW MIN
25 FSTA MIN
26 SAME, JXN MORMIN,1+
27 FLDA MIN
28 RETN, JA .
29 MORMIN, STARTD /NEXT ARG ADDRESS
30 FLDA% 0,2+
31 FSTA 3
32 STARTE
33 FLDA MIN /COMPARE
34 FSUB% 3
35 JLE SAME /SAME MIN
36 JA NEW /NEW MIN
37 TWO, 0;2
38 MIN, 0;0;0
39 0;0;0
40 XR, 0;0;0;0;0;0;0;0
41 END
42 \f