1: /
   2: /
   3: 
   4: / a3 -- pdp-11 assembler pass 1
   5: 
   6: assem:
   7:         jsr     pc,readop
   8:         jsr     pc,checkeos
   9:                 br ealoop
  10:         tst     ifflg
  11:         beq     3f
  12:         cmp     r4,$200
  13:         blos    assem
  14:         cmpb    (r4),$21        /if
  15:         bne     2f
  16:         inc     ifflg
  17: 2:
  18:         cmpb    (r4),$22   /endif
  19:         bne     assem
  20:         dec     ifflg
  21:         br      assem
  22: 3:
  23:         mov     r4,-(sp)
  24:         jsr     pc,readop
  25:         cmp     r4,$'=
  26:         beq     4f
  27:         cmp     r4,$':
  28:         beq     1f
  29:         mov     r4,savop
  30:         mov     (sp)+,r4
  31:         jsr     pc,opline
  32:         br      ealoop
  33: 1:
  34:         mov     (sp)+,r4
  35:         cmp     r4,$200
  36:         bhis    1f
  37:         cmp     r4,$1           / digit
  38:         beq     3f
  39:         jsr     r5,error; 'x
  40:         br      assem
  41: 1:
  42:         bitb    $37,(r4)
  43:         beq     1f
  44:         jsr     r5,error; 'm
  45: 1:
  46:         bisb    dot-2,(r4)
  47:         mov     dot,2(r4)
  48:         br      assem
  49: 3:
  50:         mov     numval,r0
  51:         jsr     pc,fbcheck
  52:         movb    dotrel,curfbr(r0)
  53:         asl     r0
  54:         movb    dotrel,nxtfb
  55:         mov     dot,nxtfb+2
  56:         movb    r0,nxtfb+1
  57:         mov     dot,curfb(r0)
  58:         movb    fbfil,r0
  59:         sys     write; nxtfb; 4
  60:         br      assem
  61: 4:
  62:         jsr     pc,readop
  63:         jsr     pc,expres
  64:         mov     (sp)+,r1
  65:         cmp     r1,$200
  66:         bhis    1f
  67:         jsr     r5,error; 'x
  68:         br      ealoop
  69: 1:
  70:         cmp     r1,$dotrel
  71:         bne     2f
  72:         bic     $40,r3
  73:         cmp     r3,dotrel
  74:         bne     1f
  75: 2:
  76:         bicb    $37,(r1)
  77:         bic     $!37,r3
  78:         bne     2f
  79:         clr     r2
  80: 2:
  81:         bisb    r3,(r1)
  82:         mov     r2,2(r1)
  83:         br      ealoop
  84: 1:
  85:         jsr     r5,error; '.
  86:         movb    $2,dotrel
  87: ealoop:
  88:         cmp     r4,$';
  89:         beq     assem1
  90:         cmp     r4,$'\n
  91:         bne     1f
  92:         inc     line
  93:         br      assem1
  94: 1:
  95:         cmp     r4,$'\e
  96:         bne     2f
  97:         tst     ifflg
  98:         beq     1f
  99:         jsr     r5,error; 'x
 100: 1:
 101:         rts     pc
 102: 2:
 103:         jsr     r5,error; 'x
 104: 2:
 105:         jsr     pc,checkeos
 106:                 br assem1
 107:         jsr     pc,readop
 108:         br      2b
 109: assem1:
 110:         jmp     assem
 111: 
 112: fbcheck:
 113:         cmp     r0,$9.
 114:         bhi     1f
 115:         rts     pc
 116: 1:
 117:         jsr     r5,error; 'f
 118:         clr     r0
 119:         rts     pc
 120: 
 121: checkeos:
 122:         cmp     r4,$'\n
 123:         beq     1f
 124:         cmp     r4,$';
 125:         beq     1f
 126:         cmp     r4,$'\e
 127:         beq     1f
 128:         add     $2,(sp)
 129: 1:
 130:         rts     pc

Defined functions

assem defined in line 6; used 7 times
assem1 defined in line 109; used 3 times
checkeos defined in line 121; used 2 times
ealoop defined in line 87; used 4 times
fbcheck defined in line 112; used 1 times
  • in line 51
Last modified: 1975-07-17
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 413
Valid CSS Valid XHTML 1.0 Strict