Annotation of 43BSDTahoe/ucb/lisp/franz/tahoe/hcrt0.s, revision 1.1.1.1

1.1       root        1: # @(#)crt0.s   4.1 (Berkeley) 12/21/80
                      2: # C runtime startoff
                      3: #              TAHOE 3/83
                      4: 
                      5:        .set    exit,1
                      6: .globl _exit
                      7: .globl start
                      8: .globl hstart
                      9: .globl _main
                     10: .globl _environ
                     11: 
                     12: #
                     13: #      C language startup routine
                     14: 
                     15: hstart:
                     16:        .word   0x0000
                     17:        clrl    r1
                     18:        jmp     L0
                     19: start:
                     20:        .word   0x0000
                     21:        movl    $1,r1
                     22: L0:
                     23:        movab   -8(sp),sp
                     24:        movl    8(sp),(sp)  #  argc
                     25:        movab   12(sp),r0
                     26:        movl    r0,4(sp)  #  argv
                     27:        jmp     L3
                     28: L1:
                     29:        addl2   $4,r0
                     30: L3:
                     31:        tstl    (r0)  #  null args term ?
                     32:        jneq    L1
                     33:        addl2   $4,r0
                     34:        cmpl    r0,*4(sp)  #  end of 'env' or 'argv' ?
                     35:        jlss    L2
                     36:        subl2   $4,r0   # envp's are in list
                     37: L2:
                     38:        movl    r0,8(sp)  #  env
                     39:        movl    r0,r10
                     40:        tstl    r1
                     41:        jneq    L4
                     42:        callf   $4,_rlc
                     43: L4:
                     44:        movl    r10,_environ  #  indir is 0 if no env ; not 0 if env
                     45:        callf   $4*3+4,_main
                     46:        pushl   r0
                     47:        callf   $4*1+4,_exit
                     48:        kcall   $exit
                     49: #
                     50:        .data
                     51: _environ:      .space  4

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.