Annotation of cci/sys/tahoe/Adivl2.c, revision 1.1

1.1     ! root        1: #include "../machine/alignment.h" 
        !             2: divl2(infop)   process_info *infop;
        !             3: /*
        !             4: /*     Arithmetic division, 2 operands.
        !             5: /*
        !             6: /**************************************/
        !             7: {
        !             8:        register        long    Register_12;    /* Has to be first reg ! */
        !             9:        register        long    divident, divisor, result;
        !            10: 
        !            11:        divisor = operand(infop,0)->data;
        !            12:        divident = operand(infop,1)->data;
        !            13:        if (divisor == 0) {
        !            14:                exception (infop, ARITHMETIC, 2);
        !            15:        } else {
        !            16:                Register_12=psl;
        !            17:                Set_psl(r12);   /* restore the user psl */
        !            18:                result = divident / divisor;
        !            19:                asm ("  movpsl  r12");
        !            20:                New_cc (Register_12);
        !            21:        }
        !            22:        write_back (infop,result, operand(infop,1));
        !            23: }
        !            24: 
        !            25: 

unix.superglobalmegacorp.com

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