Assignment 5, due Feb 21

Part of the homework for 22C:122/55:132, Spring 2003
by Douglas W. Jones
THE UNIVERSITY OF IOWA Department of Computer Science

Always, on every assignment, please write your name legibly as it appears on your University ID and on the class list!

  1. Look at the Minimal CISC paper, Figure 2, and the microcode that follows, and redo the control unit using the following design (borrowed from the notes for Lecture 13:
           ______________________________
          |                       |      |
          |     ______________    |     _|_     /|__ 0
          |    | microprogram |   |    /   \___| |__ conditions tested in
          |    |      ROM     |  _|_  /_0_1_\  | |__ data part of system
          |____|addr          | |+1 |   | |     \|
               |              | |___|   | |     |
               |______________|   |     | |     |
                ______|_______ ___|___  | |     |
      clock ---|>_____________|__µpc__| | |     |
                 |      |  |      |_____| |     |
                 |      |  |______________|     |
                 |      |_______________________|    control signals to
                 |__________________________________ data part of system
    
    This leads to the following microcode format, if we assume minimal changes from the material presented in the Minimal CISC paper:
    uaddr || clocks |bus |  function   | test | branch addr
    ------++--------+----+-------------+------+-------------
          || IAPTSM | AM | I A  P S M  |      |      
          || RCCCPW | CR | R C  C P A  |      |      
          || CCC CR | WE | F F  F F D  |      |
    ------++--------+----+-------------+------+-------------
    
    Assume the test field is encoded as:
       000 no branch
       001 TLZ 1 if t<0
       010 INZ 1 if tr!=0
       011 IR0 test bit 0 of ir (least significant bit)
       100 IR1 test bit 1 of ir
       101 IR2 test bit 2 of ir
       110 unused
       111 always branch
    
    Finish the microcode for the machine, in the style of the last table in the Minimal CISC paper.

  2. In the notes for Lecture 13, there is a comment, in passing, that a microcoded system with microinstructions formatted as follows is essentially a Moore machine:
              ____ ___ ____ ___ _   _ ____ ___ ____ ____________ ____________
      state: |____|___|____|___|_   _|____|___|____|____________|____________|
              Xmux Xck Ymux Yck  ...  Wmux Wck test      A             B     
                                                           next states
    
    The words were "essentially a Moore machine". What would a pure Moore-machine-based microcode based on this idea look like? Give the micro-instruction word format that results.

  3. The documentation for the B5000 (see lecture 11) suggests that there might be a 2-bit stack-state register. Strictly speaking, such a register can be eliminated at the cost of an approximate quadrupling of the size of the microcode for the machine; in effect, the stack-state is encoded by two bits of the microprogram counter. We do this by making 4 copies of the basic microprogram for the machine, where each copy assumes a particular stack state. In each version, operations on the stack will lead to a new stack state, so each such operation ends with a branch into the logic of the appripriate state (if you're in state i and you do a push, you end up in state j; if you're in state j and you do a push, you end up in state l, and so on; it's very deterministic!).

    Under what systems of microprogram execution (given in lecture 13) would you expect this approach to eliminating the stack-state register to lead to performance improvements?