1
1
Early Days?
Fixed Programs
It can do basic mathematics, but it cannot be used as a word processor or a gaming console
Changing the program of a fixed program machine requires rewiring, restructuring, or redesigning
the machine
Stored Programs:
A stored program computer is one that stores program instructions in electronic memory
In this stored-program concept, programs and data are stored in the same memory. The basic
concept is the ability to store program instructions in memory along with the data on which those
instructions operate. This novel idea meant that a computer built with this architecture would be
much easier to reprogram.
It is also known as ISA (Instruction set architecture) computer and is having three basic units:
1. Central Processing Unit: The central processing unit considered as heart of computing system is
defined as an electric circuit used for the executing the instruction of computer program.
1. Control Unit
A control unit (CU) handles all processor control signals. It directs all input and output flow,
fetches code for instructions, and controls how data moves around the system. The execution of
each instruction is determined by a sequence of control signals produced by the control unit.
2. Arithmetic and Logic Unit (ALU) –
The arithmetic logic unit is that part of the CPU that handles all the calculations the CPU may
need, e.g. Addition, Subtraction, Comparisons. It performs Logical Operations, Bit Shifting
Operations, and Arithmetic operations. The inputs to an ALU are the data to be operated on,
called operands, and a code indicating the operation to be performed; the ALUs output is the
result of the performed operation.
Registers refer to high-speed storage areas in the CPU or in other words Registers are memory
location with specific purpose. The data processed by the CPU are fetched from the registers. There
are di erent types of registers used in architecture :-
Accumulator (AC): Stores the results of calculations made by ALU. It holds the intermediate of
arithmetic and logical operations. It acts as a temporary storage location or device.
How it works
An accumulator stores the intermediate results of each operation in multistep calculations. For
example, when adding multiple numbers, the accumulator first holds the result of adding the first
two numbers. Then the next number is added, and the new result replaces the previous result in the
accumulator
Program Counter (PC): Keeps track of the memory location of the next instructions to be dealt with.
The PC then passes this next address to the Memory Address Register (MAR). It is also known as the
instruction pointer.
How it works
When a computer starts or resets, the PC is automatically set to zero. After each instruction is
executed, the PC is incremented by one to point to the next instruction. The CPU reads the address
stored in the PC and executes the instruction at that address.
Memory Address Register (MAR): It stores the memory locations of instructions that need to be
fetched from memory or stored in memory.
The MAR sets its output to the address from the instruction register (IR) or program counter (PC)
The memory data register (MDR) holds the data found at the address in the MAR
Memory Data Register (MDR): It stores instructions fetched from memory or any data that is to be
transferred to, and stored in, memory.
How it works
The MDR temporarily stores data that's being read from or written to memory.
It acts as a bu er between the CPU and memory, allowing for e icient data transfer.
The MDR works in conjunction with the memory address register (MAR), which holds the address of
the location where data is to be read or written.
Current Instruction Register (CIR): It stores the most recently fetched instructions while it is waiting
to be coded and executed.
Buses – Data is transmitted from one part of a computer to another, connecting all major internal
components to the CPU and memory, by the means of Buses. Types:
1. Data Bus: It carries data among the memory unit, the I/O devices, and the processor.
2. Address Bus: It carries the address of data (not the actual data) between memory
and processor.
3. Control Bus: It carries control commands from the CPU (and status signals from
other devices) in order to control and coordinate all the activities within the
computer.
3. Input/Output Devices – Program or data is read into main memory from the input device or
secondary storage under the control of CPU input instruction. Output devices are used to
output information from a computer. If some results are evaluated by the computer and it is
stored in the computer, then with the help of output devices, we can present them to the user.
Whatever we do to enhance performance, we cannot get away from the fact that instructions can
only be done one at a time and can only be carried out sequentially. Both of these factors hold back
the competence of the CPU. This is commonly referred to as the ‘Von Neumann bottleneck’. We can
provide a Von Neumann processor with more cache, more RAM, or faster components but if original
gains are to be made in CPU performance then an influential inspection needs to take place of CPU
configuration.
This architecture is very important and is used in our PCs and even in Super Computers.
Comment on the results. Although machine B has a higher MIPS than machine A, it requires a longer
CPU time to execute the same set of benchmark programs
A programmer writes the program instructions in assembly language, which are easily understandable for
the humans. But the assembly language is not understandable by the computer machines, as these computer
machines are made of digital modules, which understand only binary logic. Hence, during execution,
program is converted into binary codes which is understandable by the computer machines. The Instruction
Set Architecture (ISA) is the part of the processor that is visible to the programmer or compiler designer.
They are the parts of a processor design that need to be understood in order to write assembly language,
such as the machine language instructions and registers. A binary coded instruction is in format, which is
interpreted and executed by the machine. The ISA serves as the boundary between hardware and software.
Instruction format
A simple instruction format is shown in Figure 1. It consists of three components: the operand address, the
operation code or opcode and the mode.
The number of bits is allocated to each component. Basic definition of these components are:
A point that can be noted for the instruction format of Figure is that size of operand filed of instruction is
24 bits. In case, this operand is a direct operand, then the size of the main memory addresses that can be
supported by the machine having instruction format, as given in Figure is 2 = 16 M memory words.
Operand Data Types
In computer, operands are the data bits on which operation is to be performed. As shown in Figure 9.1, data
types can be categorised as logical, integer and characters. Logical data is Boolean which may be 1/0 or
true/false. Integer data may be further divided into: decimal, fixed point, and floating point. And the
character data have mnemonics such as: ASCII, UNICODE etc.
Types of Instructions
To evaluate any computable function, a computer must have a group of instructions created by the designer
in machine language. Computer instructions are the translation of high level language code to machine level
language programs. The set of instructions include various types such as: arithmetic instructions, logical
instructions, shift instructions, instructions to transfer content from memory to processor register, program
control instructions and input/output instructions. Broadly, instruction can be categorized as below:
1. Data Transfer Instruction
2. Data Processing Instruction
3. Program Control Instruction