0% found this document useful (0 votes)
31 views11 pages

Cao U2

A bus is a communication system that transfers data between computer components. Early buses used parallel wires, but now include optical fibers. Buses carry different types of data and signals, like addresses, data, and controls. An instruction cycle refers to the processing for a single instruction, including fetching the instruction from memory, decoding it, executing it, and updating registers and memory. It involves components like the CPU, registers, ALU, memory, and buses to coordinate the flow of data needed to complete each instruction.

Uploaded by

vilasvairagade02
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
31 views11 pages

Cao U2

A bus is a communication system that transfers data between computer components. Early buses used parallel wires, but now include optical fibers. Buses carry different types of data and signals, like addresses, data, and controls. An instruction cycle refers to the processing for a single instruction, including fetching the instruction from memory, decoding it, executing it, and updating registers and memory. It involves components like the CPU, registers, ALU, memory, and buses to coordinate the flow of data needed to complete each instruction.

Uploaded by

vilasvairagade02
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

BUS

In early computers, the bus was parallel electrical wires with multiple hardware connections.
Therefore a bus is a communication system that transfers data between components inside a
computer or between computers. It includes hardware components like wires, optical fibers, etc.
and software, including communication protocols.

The Registers, ALU, and the interconnecting BUS are collectively referred to as data paths. Here
are the following types of the bus, such as:

i. Address bus: The buses which are used to carry address.


ii. Data bus: The buses which are used to carry data.
iii. Control bus: If the bus is carrying control signals.
iv. Power bus: If it is carrying clock pulse, power signals, it is known as a power bus.

The bus can be used for a single purpose or multiple purposes. When we would have different
kinds of buses, different types of bus organizations will take place, such as:

One Bus organization

In one bus organization, a single bus is used for multiple purposes. A set of general-purpose
registers, program counters, instruction registers, memory address registers (MAR), and memory
data registers (MDR) are connected with the single bus. Memory read/write can be done with MAR
and MDR.

The program counterpoints to the memory location from where the next instruction is to be
fetched. The instruction register will hold a copy of the current instruction. In one bus organization,
only one operand can be read from the bus at a time.
If the requirement is to read two operands for the operation, then the read operation needs to be
carried twice. So that's why it is making the process a little longer. One of the advantages of one
bus organization is that it is one of the simplest and also this is very cheap to implement.

At the same time, there is a disadvantage that it has only one bus. This "one bus" is accessed by all
general-purpose registers, program counter, instruction register, MAR, and MDR, making every
operation sequential. No one recommends this architecture nowadays.

Two Bus organizations

This overcame the disadvantage of one bus organization, and another architecture was developed
known as two bus organization. In two bus organizations, there are two buses, and the general-
purpose register can read/write from both the buses. In this case, two operands can be fetched at
the same time because of the two buses.

One bus fetch operand for ALU and another bus fetch for register. The situation arises when both
buses are busy fetching operands, the output can be stored in a temporary register. When the
buses are free, then the particular output can be dropped on the buses.

There are two versions of two bus organizations, i.e., in-bus and out-bus. From in-bus, the general-
purpose register can read data, and to the out bus, the general-purpose registers can write data.
Here buses get dedicated.

Three Bus organization

In three bus organizations, we have three buses, OUT bus1, OUT bus2, and an IN bus. From the out
buses, we can get the operand that can come from the general-purpose register and evaluated in
ALU, and the output is dropped on In Bus to be sent to respective registers.
This implementation is complex but faster because two operands can flow into ALU and out of ALU in
parallel. It was developed to overcome the "busy waiting" problem of two bus organizations.

In this structure, after execution, the output can be dropped on the bus without waiting because of
an extra bus. The main advantages of multiple bus organizations over the single bus are:

o Increase in size of the registers.


o Reduction in the number of cycles for execution.
o Increases the speed of execution, or we can say faster execution.
Execution of a complete instruction:

What is instruction cycle?

A sequence of instructions makes up a program stored in a computer's memory unit. The CPU executes
these instructions by going through a cycle for each instruction. The instruction cycle in a simple computer
includes the steps listed below:

 Get the instruction from memory.


 Decode the instruction.
 From memory, read the effective address.
 Execute the instruction.

The instruction cycle is divided into four phases: fetching an instruction from memory, decoding the fetched
instruction, reading the address from memory, and finally, instruction execution. The computer processor
carries it out.

Role of Component

In a computer, there are a lot of instructions; these instructions are called Instruction Set of Architecture that
is ISA. An execute instruction is a machine language instruction that runs data as a machine instruction.
The program to be run consists of instructions stored in memory.

The central processing unit (CPU) executes the program's instructions to finish the task. The CPU is
primarily responsible for the execution of instructions. In the CPU, instructions are executed in CPU
registers. Now we see some CPU and their registers.
 Central Processing Unit (CPU): A computer's central processing unit (CPU) is regarded as its
brain. The CPU is an electrical circuitry that executes instructions from a computer program. In a
computer, the Processor operates instructions by completing fundamental arithmetic, logic, control,
and I/O operations as necessary. A computer's CPU is mainly responsible for its speed and
efficiency. Only the CPU in a computer can execute instructions. However, because the program
might be quite lengthy, the CPU loads it into the main memory (RAM) and then fetches and executes
instructions one by one from memory.
 Memory Address Register (MAR): It indicates the memory address from which data or
instructions are read or stored.
 Program Counter (PC): The PC keeps track of the next instruction to be executed once an ongoing
instruction has been completed.
 Instruction Register (IR): Holds the last instruction fetched.

The processor reduces the processing of instructions to a two-step process. The CPU reads (fetches)
instructions (codes) one at a time from memory and executes or performs the operation provided. The
reading of an instruction from a memory address to a CPU register is known as instruction fetch. Depending
on the type of instruction, the execution of this instruction may include multiple operations.

The instruction cycle refers to the processing produced by a single instruction (fetch and execution). The
fetch cycle and the execute cycle make up the instruction cycle. If the electric power source is turned off, an
unrecoverable fault occurs, or if the program itself quits, the program is terminated.

A program counter is utilized for the fetch cycle of a standard CPU. The program counter keeps track of the
next instruction to be fetched. As programs are run in order, the next instruction in the sequence is usually
fetched first.

An instruction register is loaded with the fetched instruction in the CPU and binary code. The CPU decodes
the command and performs the necessary action.

Steps for Executing of Instruction by CPU


There are six steps to the execution of instructions.

 Fetch instruction: The fetching instructions from the main memory begins the execution cycle. The
current program counter will acquire the instruction placed in the instruction register (IR).
 Decode Instruction: During this cycle, the decoder interprets the encoded instruction stored in the IR
(instruction register).
 Perform ALU Operation: Two operands in the instruction will be operated on a specified operator
in the instructions in an ALU (Arithmetic Logic Unit). For example, if the instruction were to add
two numbers, the addition would occur here. The outcome of the process is output by the ALU,
which takes two values and outputs one.
 Access Memory: There are only two memory access instructions: LOAD and STORE. A value from
memory is copied to a register by LOAD, and a register value is copied to memory by STORE. This
step is skipped if you follow any other instructions.
 Update Register File: The ALU's output/result is written back to the register file in this phase to
update the register file. It's also possible that the result is due to a LOAD from memory. Some
instructions do not provide results that can save. The BRANCH and JUMP instructions, for example,
have no outcomes to save.
 Update Program Counter(PC): At the completion of the current instruction's execution, we must
update the program counter (PC) to the address of the next instruction so that we may return to step 1
and have the CPU acquire the next instruction. If the instruction was BRANCH or JUMP, the
program counter might need to be set to a different memory address than the following one.

Why Instruction Cycle is required?

 An instruction cycle for a computer system is required to properly comprehend the flow of
instructions and the execution of an instruction in a computer processor.
 It deals with the entire flow of instructions from the time the computer system boots up to when it
shuts down. The internal flow of the central processing unit can be better understood via the
instruction cycle, allowing any problems to be quickly remedied.
 It deals with the fundamental functions of a computer processor, and it necessitates a thorough
understanding of the many phases involved.
 All sorts of instructions for the computer processing system follow the fetch-decode-execute cycle.

You might also like