0% found this document useful (0 votes)
21 views40 pages

COA Unt-1

The document discusses the basic components and organization of a digital computer. It describes registers that store data and instructions, common bus systems for transferring information between registers, memory for long-term storage, and an accumulator for processing data. The computer uses a stored program with instruction codes to perform operations like arithmetic, logic, and data transfers. A control unit generates signals to sequence through instruction cycles, which involve fetching code from memory, decoding the operation, retrieving operands, and executing the instruction. The computer supports memory-reference and input/output instructions as well as interrupt handling.

Uploaded by

binggivaway
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)
21 views40 pages

COA Unt-1

The document discusses the basic components and organization of a digital computer. It describes registers that store data and instructions, common bus systems for transferring information between registers, memory for long-term storage, and an accumulator for processing data. The computer uses a stored program with instruction codes to perform operations like arithmetic, logic, and data transfers. A control unit generates signals to sequence through instruction cycles, which involve fetching code from memory, decoding the operation, retrieving operands, and executing the instruction. The computer supports memory-reference and input/output instructions as well as interrupt handling.

Uploaded by

binggivaway
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/ 40

Computer Organization

CO Unit-1
Block diagram of a digital computer
Digital logic gates
Registers transfer
➢Information transfer from one register to another is
designated in symbolic form by means of a
replacement operator.
➢ The statement R2 <-- R1 denotes a transfer of the
content of register R1 into register R2.
Block diagram of register
Registers: A register is a group of flip-flops with each flip-
flop capable of storing one bit of information.
➢4-bit register
Control function
If (P = 1) then (R2 <-- R1)
➢ where P is a control signal generated in the control
section.
➢ It is sometimes convenient to separate the control
variables from the register transfer operation by
specifying a control function.
➢ A control function is a Boolean variable that is equal to
1 or 0.
➢ The control function is included in the statement as
follows:
P: R2 <-- R1
➢ The control condition is terminated with a colon.
➢ It symbolizes the requirement that the transfer
operation be executed by the hardware only if P = 1.
Basic Symbols for Register Transfers
Bus and memory transfers
common bus system
➢ A typical digital computer has many registers, and paths
must be provided to transfer information from one
register to another.
➢ The number of wires will be excessive if separate lines
are used between each register and all other registers
in the system.
➢ A more efficient scheme for transferring information
between registers in a multiple-register configuration is
a common bus system.
➢ A bus structure consists of a set of common lines, one
for each bit of a register, through which binary
information is transferred one at a time.
➢ Control signals determine which register is selected by
the bus during each particular register transfer
Bus system for four registers
➢One way of constructing a common bus system is
with multiplexers.
➢The multiplexers select the source register whose
binary information is then placed on the bus
➢Each register has four bits, numbered 0 through 3.
➢ The bus consists of four 4 x 1 multiplexers each
having four data inputs, 0 through 3, and two
selection inputs, S1 and S0.
Memory Transfer
➢The transfer of information from a memory word to
the outside environment is called a read operation.
➢The transfer of new information to be stored into
the memory is called a write operation.
➢A memory word will be symbolized by the letter M
➢A memory unit that receives the address from a
register, called the address register, symbolized by
AR .
➢ The data are transferred to another register, called
the data register, symbolized by DR .
➢The read operation can be stated as follows:
Read: DR M[AR]
Microoperations
➢A microoperation is an elementary operation
performed with the data stored in registers.
1. Register transfer microoperation
2. Arithmetic microoperation
3. Logic microoperation
4. Shift microoperation
1. Arithmetic microoperation
1. Logic microoperation
➢Logic microoperations specify binary operations for
strings of bits stored in registers.
➢These operations consider each bit of the register
separately and treat them as binary variables.
➢ For example, the exclusive-OR microoperation with
the contents of two registers R 1 and R2 is
symbolized by the statement
P: R1 +- R1 R2
➢Let the content of R1 be 1010 and the content of R2
be 1 100.
➢The exclusive-OR microoperation stated above
symbolizes the following logic computation:

1010 Content of R 1
1 100 Content of R2
0110 Content of R 1 after P = 1
List of Logic Microoperations
➢There are 16 different logic operations that can be
performed with two binaryvariables.
➢In this table, each of the 16 columns F0 through F15
represents a truth table of one possible Boolean
function for the two variables x and y.
Sixteen Logic Microoperations
4. Shift microoperation
➢Shift microoperations are used for serial transfer of
data.
➢They are also used in conjunction with arithmetic,
logic, and other data-processing operations.
➢The contents of a register can be shifted to the left
or the right.
➢There are three types of shifts:logical, circular, and
arithmetic.
Logical shift
Example:
R1 shl R1
R2 shr R2
➢The two microoperations that specify a 1-bit shift to
the left of the content of register R 1 and a 1-bit
shift to the right of the content of register R2.
➢The symbols shl and shr for logical shift-left and
shift-right rnicrooperations
Circular shift
➢The circular shift (also known as a rotate operation)
circulates the bits of the register around the two
ends without loss of information.
➢This is accomplished by connecting the serial output
of the shift register to its serial input.
➢We will use the symbols cil and cir for the circular
shift left and right, respectively.
Arithmetic shift
➢An arithmetic shift is a rnicrooperation that shifts a
signed binary number to the left or right.
➢An arithmetic shift-left multiplies a signed binary
number by 2.
➢ An arithmetic shift-right divides the number by 2.
Arithmetic shift right.
Instruction Codes
➢ An instruction code is a group of bits that instruct the
computer to perform a specific operation.
➢ It is usually divided into parts, each having its own
particular interpretation.
➢ The most basic part of an instruction code is its
operation part.
➢ The operation code of an instruction is a group of bits
that define such operations as add, subtract, multiply,
shift, and complement.
➢ When this operation code is decoded in the control
unit, the computer issues control signals to read an
operand from memory and add the operand to a
processor register.
Stored Program Organization
➢The simplest way to organize a computer is to have
one processor register and an instruction code
format with two parts.
➢The first part specifies the operation to be
performed and the second specifies an address.
➢The memory address tells the control where to find
an operand in memory.
➢This operand is read from memory and used as the
data to be operated on together with the data
stored in the processor register.
Stored program organization
(a) Instruction format
➢It consists of a 3-bit operation code, a 12-bit
address, and an address mode bit designated by I.
➢The mode bit is 0 for a direct address and 1 for an
indirect address
(b) Direct address
➢When I bit is 0, so the instruction is recognized as a
direct address instruction.
➢The opcode specifies an ADD instruction, and the
address part is the binary equivalent of 457.
➢The control finds the operand in memory at address
457 and adds it to the content of AC .
(c)Indirect address
➢The instruction in address 35 has a mode bit I = 1.
➢Therefore, it is recognized as an indirect address
instruction.
➢The address part is the binary equivalent of 300.
➢The control goes to address 300 to find the address
of the operand.
➢The address of the operand in this case is 1350.
➢The operand found in address 1350 is then added
to the content of AC .
Computer Registers
➢ Computer instructions are normally stored in
consecutive memory locations and are executed
sequentially one at a time.
➢ The control reads an instruction from a specific address
in memory and executes it.
➢ It then continues by reading the next instruction in
sequence and executes it, and so on.
➢ This type of instruction sequencing needs a counter to
calculate the address of the next instruction
➢ The computer needs processor registers for
manipulating data and a register for holding a memory
address.
➢ These requirements dictate the register configuration
List of Registers for the Basic Computer
Basic computer registers and memory
Computer Instructions
Instruction format
➢The basic computer has three instruction code
formats
Timing and Control
➢The timing for all registers in the basic computer is
controlled by a master clock generator.
➢The clock pulses are applied to all flip-flops and
registers
➢The control signals are generated in the control unit
and provide control inputs for the multiplexers in
the common bus, control inputs in processor
registers, and microoperations for the accumulator.
There are two major types of control organization:
1. Hardwired control and
2. Microprogrammed control
➢In the hardwired organization, the control logic is
implemented with gates, flip-flops, decoders, and
other digital circuits.
➢In the microprogrammed organization, the control
information is stored in a control memory.
➢The control memory is programmed to initiate the
required sequence of microoperations.
Control unit
Instruction Cycle
➢ A program residing in the memory unit of the computer
consists of a sequence of instructions.
➢ The program is executed in the computer by going
through a cycle for each instruction.
➢ Each instruction cycle in turn is subdivided into a
sequence of subcycles or phases.
➢ In the basic computer each instruction cycle consists of
the following phases:
1. Fetch an instruction from memory.
2. Decode the instruction.
3. Read the effective address from memory if the
instruction has an indirect address.
4. Execute the instruction.
Flowchart for instruction cycle.
Memory-Reference Instructions
Input-Output Configuration
Program Interrupt Flowchart for interrupt cycle

You might also like