1. Gyanastra
  2. Computer Organisation and Architecture
  3. Hardwired Control Unit
  4. Sequence Counter for Timing Signals
Free lesson, no account needed 5 min read 9 practice questions after it
Asked in past papers1 time
  • GATE CSE2006

Computer Organisation and Architecture · Hardwired Control Unit

Sequence Counter for Timing Signals

Overview

In a hardwired control unit, the timing signals T0, T1, T2, … are produced by a sequence counter, while the control signals themselves are built from logic gates and the bus is built from a multiplexer.
The counter defines the time steps of one instruction, and clearing it lets the next instruction start again at T0.

Key concepts

  • Sequence counter: a counter used in the hardwired control unit to generate the timing signals T0, T1, T2, … of the control unit.
  • Control signals: generated and designed using logic gates.
  • Bus: implemented and designed using a multiplexer (MUX) as the building block.
  • Timing signals: the successive count values of the sequence counter, each count acting as one time step (0 → T0, 1 → T1, 2 → T2, …).
  • One sequence per instruction: one full count sequence serves one instruction; the next sequence serves the next instruction.
Logic circuit: Sequence Counter for Timing Signals
Figure. Sequence Counter for Timing Signals

How it works

  1. The timing signals are produced mainly by a sequence counter.
  2. An n-bit sequence counter counts through all 2n2^n values. A 3-bit sequence counter runs from 000 to 111, i.e. from 0 to 7.
  3. Each count value is used as a time step: 0 → T0, 1 → T1, 2 → T2, 3 → T3, 4 → T4, …, 7 → T7. After the last count it wraps around back to T0.
  4. The sequence of time steps is used for one instruction; the next sequence is used for the next instruction.
  5. If an instruction needs only a few time cycles (for example four), the counter must be cleared to all zeros after that instruction finishes execution, so the next instruction starts again at time zero (T0).
  6. The control signals are designed with logic gates, and the bus is designed using a multiplexer as its building block.

Formulas

  • 2n2^n = number of distinct states (count values) of an n-bit sequence counter

  • 0 to 2n−10 \text{ to } 2^n - 1 = count range of an n-bit sequence counter

  • 23=82^3 = 8 = number of states of a 3-bit sequence counter, giving counts 0 to 7 (T0 to T7)

  • Sequence counter timing cycle

  • The 3-bit sequence counter steps through counts 0 to 7 as timing signals T0 to T7, wrapping to T0, and can be cleared back to T0 after a short instruction.

Worked examples

3-bit sequence counter generating timing signals

  • Counter size = 3 bits.
  • Number of distinct states = 23=82^3 = 8.
  • Count sequence: 000 → 001 → 010 → 011 → 100 → 101 → 110 → 111, i.e. 0 → 1 → 2 → 3 → 4 → 5 → 6 → 7.
  • Mapping to timing signals: 0 = T0, 1 = T1, 2 = T2, 3 = T3, 4 = T4, …, 7 = T7.
  • After 7 (111) the counter returns to T0 (000) for the next instruction.

Instruction needing only 4 time cycles

  • The instruction uses T0, T1, T2, T3 (4 cycles).
  • After execution, the counter is cleared to 000 (all zeros).
  • The next instruction therefore begins at T0 again.

Revision summary

  • Timing signals in the hardwired control unit come from a sequence counter.
  • An n-bit sequence counter gives counts 0 to 2n−12^n - 1; a 3-bit counter gives 000 to 111 (0 to 7), used as T0 to T7.
  • One count sequence = one instruction.
  • The counter is cleared to zero after the instruction's required cycles so the next instruction starts at T0 — without the clear, the next instruction would not begin at time zero.
  • Control signals are built from logic gates.
  • The bus is built using a multiplexer as the basic building block.

Previous-year exam insights

  • A sequence counter (ring counter / Johnson counter / binary counter) generates the timing signals T0, T1, ...; the control signals are then produced by combinational logic that decodes the instruction register, the sequence counter state and the condition flags.
    Asked inGATE 2006
  • The number of distinct timing states an n-bit sequence counter can produce is 2n2^{n}, so the maximum number of time steps per instruction is 2n2^{n}; a counter with k states can time at most k steps before it must be reset.
  • Clearing the sequence counter to zero at the end of an instruction (end of the last required timing step) is what makes the next instruction restart at T0; the clear signal is generated by the control logic when the last step of the current instruction is reached.
  • In a hardwired control unit the control signal for each timing step is a Boolean function of the instruction opcode bits, the timing signal and the status/condition flags, implemented with gates; hence a change in the instruction set requires rewiring the logic, unlike a microprogrammed unit.
  • The control word / microinstruction format and the sequencing of control steps (fetch, decode, execute) are determined by the control unit; in microprogrammed control the control word is stored in the control memory and the microinstruction address is taken from a sequencer, not from a hardwired counter.
    Asked inGATE 2006
  • A multiplexer selects one of several inputs under the control of select lines; it is used as the building block for the common bus that routes register outputs, and the number of select lines needed for a bus with m sources is ceil(log⁡2m\log_{2} m).
Pages 1–2 of 2