The full ALU cell, ALUFIN, is composed of several sub-sections, which are described in more detail below:
Combinational Logic
The majority of the combinational logic for the ALU is contained within the
ALL cell. There are four ALL cells in the ALU--one for each bit. Each ALL cell has to data inputs: x and y. The x input is taken from the
bus, while the y input comes from the Internal Decoder
Many of the control signals for the ALU are generated internally by a
simple decoder. Rather than obtaining control signals from the PLA, the
lower three bits of the opcode for each instruction is input to a decoder
(mpla) which then outputs the control signals to determine what type of
operation is being performed (i.e. control of the ASC and PATH signals) and
which output to propagate to the accumulator. The decoder was designed
using the mpla tool, but the clocks of the resulting pla-decoder are tied
to vdd (and the clock_bars tied to ground), making the decoder purely
combinational. The benefits of operating an internal decoder rather than
taking controls from the PLA are that it minimizes the size of the PLA and
also causes fewer timing complications by removing timing constraints from
the operation of the ALU control signals. The following table summarizes
which 3-bit opcodes specify which ALU instructions, as well as what control
signals are asserted for those instructions.
3-Bit Opcode
Operation
Signals Asserted
000
ADDX
Assig
010
ADDI
Assig
110
ADD
Assig
111
SUBTRACT
Assig Carry
001
AND
Andsig
100
OR
Orsig Carry Path
101
NOT
Notsig Path
011
Shift Right Logical
Srsig
Output Multiplexor
Because the results of the various alu operations are obtained from
different locations within the same circuit, all operations are being
performed at all times (although the results may not be correct since the
control signals ASC and PATH will not be appropriate for all operations).
Thus, we need a multiplexor to choose which of the result signals will be
the official output of the ALU and will be passed to the accumulator. This
is achieved through the use of an array of transmission gates. Each of the
outputs of each ALL cell are sent to a tgate (cell JGATE), and these tgates
are controlled by output signals of the internal decoder. The outputs of
the tgates for all the outputs of each bit (or ALL cell) are connected, and
only one tgate is enabled at any given time. Thus, depending upon the
signal output by the decoder, the output for an ADD, SUBTRACT, AND, OR,
NOT, or SRL is passed through the array of tgates and sent to the
accumulator. Because the decoder controls both the control inputs to the
ALL cells (ASC and PATH) and the control inputs to the tgate array (ANDSIG
ORSIG ASSIG NOTSIG and SRSIG), we can be certain that these signals are
Accumulator Multiplexor
The accumulator multiplexor is simply a 4-bit, 2-input mux. It chooses
whether the values on the bus or the output of the ALU will be sent to the
accumulator to be stored. The accumulator multiplexor is controlled by a
signal called BUS2ACC, which is generated in the main PLA. The BUS2ACC
signal is inverted and connected to the signals that pass the ALU value to
the accumulator. Thus, a high BUS2ACC passes the bus value to the
accumulator, while a low BUS2ACC passes the ALU value to the accumulator.
The accumulator multiplexor aids in the initial loading of
the accumulator. The accumulator is a clearable latch, but without the
accumulator multiplexor, loading a value other than zero into the
accumulator would require a clear of the accumulator followed by an add
immediate of the accumulator and the value to be loaded. With the
accumulator multiplexor in place, the value can simply be written to the
bus and loaded into the accumulator from the bus.