Sub-systems made of further sub-systems

Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.

Sub-systems made of further sub-systems

Name:
Date:
Class:

Quick Questions

Shade in the A or B circle for each question.

1. A CPU is a sub-system of a computer system. Can the CPU itself be split into smaller sub-systems?
A No, a sub-system can never be split again
B Yes, e.g. into the ALU, control unit and registers
2. Which choice shows the levels in the correct order, from top to bottom?
A Computer system, CPU, ALU
B ALU, CPU, computer system
3. The CPU is a sub-system of the computer. When we split the CPU into parts, how do we treat the CPU?
A As a system in its own right at the next level
B As a single part that cannot be looked at again
4. When should we stop splitting sub-systems into smaller ones?
A When each part does one simple job
B When we have drawn exactly three levels
5. Which part of the CPU carries out calculations and logic decisions?
A The registers
B The ALU

Match the Pairs

Draw a line connecting each item on the left to its match on the right.

Left columnRight column
1Computer system → CPU → ALU AThe levels are in the wrong order: the ALU is part of the CPU, so the CPU must be above the ALU in the tree.
2CPU → ALU, control unit, registers BA system split level by level: the CPU is a sub-system of the computer, and the ALU is a sub-system of the CPU
3A sub-system at one level is a system at the next level down CComputer system → CPU, then CPU → ALU, control unit, registers
4Keep splitting until each part does one simple job, then stop DThe CPU is one system at this level, and it splits into three smaller sub-systems at the next level
5Computer system → ALU → CPU EThe monitor is not part of the CPU. It is an output device, so it does not belong to this branch of the tree.
6CPU → ALU, control unit, registers, monitor FALU: carries out arithmetic and logic (no further split)

Definitions

hierarchy of sub-systems

Fill in the Blanks

Complete each line of code by filling in the missing parts.

1.
_________ Computer() CALL CPU() ENDPROCEDURE
2.
PROCEDURE Computer() ____ CPU() ENDPROCEDURE
3.
PROCEDURE CPU() CALL ALU() ____________
4.
CALL ControlUnit() CALL _________() CALL ALU()
5.
Computer -> CPU -> ___

Spot the Error

Shade in the letter of the line that contains an error.

Question 1
A PROCEDURE ComputerSystem()
B CPU()
C CALL Memory()
D ENDPROCEDURE
Question 2
A PROCEDURE CPU()
B RUN ALU()
C CALL ControlUnit()
D CALL Registers()
E ENDPROCEDURE
Question 3
A PROCEDURE ALU()
B CALL Add()
C CALL Compare()
D ENDFUNCTION
Question 4
A FUNCTION ControlUnit()
B CALL Fetch()
C CALL Decode()
D ENDPROCEDURE
Question 5
A WHILE IsSimple(part) DO
B CALL Split(part)
C part ← NextPart()
D ENDWHILE

Answer Key

Sub-systems made of further sub-systems
Section A: Quick Questions
Q1
B — Yes, e.g. into the ALU, control unit and registers
Q2
A — Computer system, CPU, ALU
Q3
A — As a system in its own right at the next level
Q4
A — When each part does one simple job
Q5
B — The ALU
Section B: Match the Pairs
Q1
Computer system → CPU → ALU → A system split level by level: the CPU is a sub-system of the computer, and the ALU is a sub-system of the CPU
Q2
CPU → ALU, control unit, registers → The CPU is one system at this level, and it splits into three smaller sub-systems at the next level
Q3
A sub-system at one level is a system at the next level down → Computer system → CPU, then CPU → ALU, control unit, registers
Q4
Keep splitting until each part does one simple job, then stop → ALU: carries out arithmetic and logic (no further split)
Q5
Computer system → ALU → CPU → The levels are in the wrong order: the ALU is part of the CPU, so the CPU must be above the ALU in the tree.
Q6
CPU → ALU, control unit, registers, monitor → The monitor is not part of the CPU. It is an output device, so it does not belong to this branch of the tree.
Section C: Definitions
Q1
hierarchy of sub-systems — Each sub-system can be split into smaller sub-systems, level by level, until every part does one simple job. A sub-system at one level is a system at the next.
Section D: Fill in the Blanks
Q1
PROCEDURE Computer() CALL CPU() ENDPROCEDURE
Q2
PROCEDURE Computer() CALL CPU() ENDPROCEDURE
Q3
PROCEDURE CPU() CALL ALU() ENDPROCEDURE
Q4
CALL ControlUnit() CALL Registers() CALL ALU()
Q5
Computer -> CPU -> ALU
Section E: Spot the Error
Q1
B — A sub-system is run from its parent with the CALL keyword. The line should be CALL CPU().
Q2
B — Cambridge pseudocode uses CALL to use a sub-system, not RUN. The CPU splits into the ALU, control unit and registers, so the line should be CALL ALU().
Q3
D — A PROCEDURE must finish with ENDPROCEDURE. ENDFUNCTION closes a FUNCTION, so the last line should be ENDPROCEDURE.
Q4
A — The control unit is written as a PROCEDURE, which is closed by ENDPROCEDURE and uses CALL. FUNCTION does not match. The first line should be PROCEDURE ControlUnit().
Q5
A — We keep splitting while the part is NOT yet simple. The loop should stop once each part does one simple job, so the line should be WHILE NOT IsSimple(part) DO.