COA LabManual
COA LabManual
B.E. Semester 4
Government Engineering
College,
Bhavnagar
Certificate
completed the Practical work for the subject Computer Organization &
Place: Bhavnagar
Date:
Preface
Main motto of any laboratory/practical/field work is for enhancing required skills as well as
creating ability amongst students to solve real time problem by developing relevant competencies
in psychomotor domain. By keeping in view, GTU has designed competency focused outcome-
based curriculum for engineering degree programs where sufficient weightage is given to
practical work. It shows importance of enhancement of skills amongst the students and it pays
attention to utilize every second of time allotted for practical amongst students, instructors and
faculty members to achieve relevant outcomes by performing the experiments rather than having
merely study type experiments. It is must for effective implementation of competency focused
outcome-based curriculum that every practical is keenly designed to serve as a tool to develop and
enhance relevant competency required by the various industry among every student. These
psychomotor skills are very difficult to develop through traditional chalk and board content
delivery method in the classroom. Accordingly, this lab manual is designed to focus on the
industry defined relevant outcomes, rather than old practice of conducting practical to prove
concept and theory.
By using this lab manual students can go through the relevant theory and procedure in advance
before the actual performance which creates an interest and students can have basic idea prior to
performance. This in turn enhances pre-determined outcomes amongst students. Each experiment
in this manual begins with competency, industry relevant skills, course outcomes as well as
practical outcomes (objectives). The students will also achieve safety and necessary precautions
to be taken while performing practical.
This manual also provides guidelines to faculty members to facilitate student centric lab activities
through each experiment by arranging and managing necessary resources in order that the
students follow the procedures with required safety and necessary precautions to achieve the
outcomes. It also gives an idea that how students will be assessed by providing rubrics.
Computer Architecture is concerned with the way hardware components are connected together to
form a computer system. It acts as the interface between hardware and software. Computer
Architecture helps us to understand the functionalities of a system. A programmer can view
architecture in terms of instructions, addressing modes and registers. While designing a computer
system architecture is considered first. Computer Architecture deals with high-level design issues.
Architecture involves Logic (Instruction sets, Addressing modes, Data types, Cache
optimization).
Utmost care has been taken while preparing this lab manual however always there is chances of
improvement. Therefore, we welcome constructive suggestions for improvement and removal of
errors if any.
iii
Enrollment Number: 220210107041
DTE’s Vision
To provide globally competitive technical education.
Remove geographical imbalances and inconsistencies.
Develop student friendly resources with a special focus on girls’ education and support to
weaker sections.
Develop programs relevant to industry and create a vibrant pool of technical professionals.
Institute’s Vision
To transform the students into good human beings, employable engineering graduates
and continuous learners by inculcating human values and imparting excellence in
technical education.
Institute’s Mission
To provide education to students from the local and rural areas, so that they become
enlightened individuals and improve the living standards of their families, and their
contribution to industry and society. To foster a learning environment with technology integration
and individual attention, so that the students imbibe quality technical knowledge, skill-
development and character building.
Department’s Vision
To achieve excellence for providing value based education in computer science and
Information Technology through innovation, team work and ethical practices
Department’s Mission
To produce graduates according to the need of industry, government, society and
scientific community and to develop partnership with industries, government
agencies and R & D Organizations for knowledge sharing and overall development of
faculties and students.
To motivate students/graduates to be entrepreneurs.
To motivate students to participate in reputed conferences, workshops,
symposiums, seminars and related technical activities.
To impart human and ethical values in our students for better serving of society.
iv
Enrollment Number: 220210107041
v
Enrollment Number: 220210107041
vi
Enrollment Number: 220210107041
Sr. CO CO CO CO CO
Objective(s) of Experiment
No. 1 2 3 4 5
Study the basic structure and functional units of digital
1. √
computer.
2. Write the working of 8085 simulator GNUsim8085. √ √
3. Study basic architecture of 8085 along with small introduction. √ √
Write following 8085 assembly language programs.
a. To add two 8-bit numbers and store result in memory
location.
b. To add five 8-bit numbers and store sum and carry in
memory location.
c. Perform addition of two 8-bit numbers and store result
4. √
after using DAA instruction.
d. Perform 16-bit subtraction.
e. Perform multiplication of two 8-bit numbers using loop.
f. Find minimum and maximum from five 8-bit numbers
stored in memory location.
g. To count the no. of 1’s in given 8-bit value.
Write following 8085 assembly language programs.
a. To add two arrays of five 8-bit values and store result in
third array.
b. To store sum of unpacked BCD numbers from packed
BCD numbers.
5. √
c. To store an ASCII value of each Hex digits.
d. To set an MSB of an 8-bit values if it has even no. of 1’s.
e. To reverse an array of ten 8-bit values using subroutine.
f. Find factorial of given 8-bit value.
g. To perform division of 16-bit number by 8-bit number.
6. Design ALU using Logisim. √
7. Implement Booth’s multiplication algorithm. √
Study interconnection structures of components of
8. multiprocessor system.
√ √ √
vii
Enrollment Number: 220210107041
1. The student will demonstrate an understanding of the history, key terminology, and
current industry trends in computer architecture.
2. The student will demonstrate an understanding of how data is represented within a
computer system.
3. The student will demonstrate an understanding of the processor (CPU) subsystem.
4. The student will demonstrate an understanding of the memory subsystem and hierarchy.
5. The student will demonstrate an understanding of the various types of storage and the
Input/output (I/O) subsystem.
6. The student will demonstrate an understanding of the issues associated with
multiprocessors and benchmarking.
Guidelines for Faculty members
1. Teacher should provide the guideline with demonstration of practical to the students with
all features.
2. Teacher shall explain basic concepts/theory related to the experiment to the students before
starting of each practical
3. Involve all the students in performance of each experiment.
4. Teacher is expected to share the skills and competencies to be developed in the students
and ensure that the respective skills and competencies are developed in the students after
the completion of the experimentation.
5. Teachers should give opportunity to students for hands-on experience after the
demonstration.
6. Teacher may provide additional knowledge and skills to the students even though not
covered in the manual but are expected from the students by concerned industry.
7. Give practical assignment and assess the performance of students based on task assigned to
check whether it is as per the instructions or not.
8. Teacher is expected to refer complete curriculum of the course and follow the guidelines
for implementation.
Instructions for Students
1. Students are expected to carefully listen to all the theory classes delivered by the faculty
members and understand the COs, content of the course, teaching and examination
scheme, skill set to be developed etc.
2. Student should develop a habit of submitting the experimentation work as per the schedule
and s/he should be well prepared for the same.
Common Safety Instructions
viii
Enrollment Number: 220210107041
Index
ix
Enrollment Number: 220210107041
Experiment No: 1
Date:
Study the basic structure and functional units of digital computer.
Objectives:
Explanation:
There are a few basic components that aid the working-cycle of a computer i.e. the Input-
Process-Output Cycle and these are called as the functional components of a computer. It needs
certain input, processes that input and produces the desired output. The input unit takes the input,
the central processing unit does the processing of data and the output unit produces the output.
The memory unit holds the data and instructions during the processing.
Digital Computer: A digital computer can be defined as a programmable machine which reads
the binary data passed as instructions, processes this binary data, and displays a calculated digital
output. Therefore, digital computers are those that work on the digital data.
1
Enrollment Number: 220210107041
Input Unit:
The input unit consists of input devices that are attached to the computer. These
devices take input and convert it into binary language that the computer understands. Some
of the common input devices are keyboard, mouse, joystick, scanner etc.
Once the information is entered into the computer by the input device, the processor
processes it. The CPU is called the brain of the computer because it is the control center of
the computer. It first fetches instructions from memory and then interprets them so as to
know what is to be done. If required, data is fetched from memory or input device.
Thereafter CPU executes or performs the required computation and then either stores the
output or displays on the output device. The CPU has three main components which are
responsible for different functions – Arithmetic Logic Unit (ALU), Control Unit (CU) and
Memory registers
The ALU, as its name suggests performs mathematical calculations and takes logical
decisions. Arithmetic calculations include addition, subtraction, multiplication and division.
Logical decisions involve comparison of two data items to see which one is larger or smaller
or equal.
Control Unit:
The Control unit coordinates and controls the data flow in and out of CPU and also
controls all the operations of ALU, memory registers and also input/output units. It is also
responsible for carrying out all the instructions stored in the program. It decodes the fetched
instruction, interprets it and sends control signals to input/output devices until the required
operation is done properly by ALU and memory.
Memory Registers:
A register is a temporary unit of memory in the CPU. These are used to store the
data which is directly used by the processor. Registers can be of different sizes(16 bit, 32
bit, 64 bit and so on) and each register inside the CPU has a specific function like storing
data, storing an instruction, storing address of a location in memory etc. The user registers
can be used by an assembly language programmer for storing operands, intermediate results
etc. Accumulator (ACC) is the main register in the ALU and contains one of the operands of
an operation to be performed in the ALU.
Memory:
Memory attached to the CPU is used for storage of data and instructions and is
called internal memory. The internal memory is divided into many storage locations, each of
which can store data or instructions. Each memory location is of the same size and has an
address. With the help of the address, the computer can read any memory location easily
without having to search the entire memory. When a program is executed, its data is copied
2
Enrollment Number: 220210107041
to the internal memory and is stored in the memory till the end of the execution. The internal
memory is also called the Primary memory or Main memory. This memory is also called as
RAM, i.e. Random Access Memory. The time of access of data is independent of its
location in memory; therefore this memory is also called Random Access memory (RAM).
Output Unit:
The output unit consists of output devices that are attached with the computer. It
converts the binary data coming from CPU to human understandable form. The common
output devices are monitor, printer, plotter etc.
A computer consists of input unit that takes input, a CPU that processes the input and an
output unit that produces output. All these devices communicate with each other through a
common bus. A bus is a transmission path, made of a set of conducting wires over which data or
information in the form of electric signals is passed from one component to another in a
computer. The bus can be of three types – Address bus, Data bus and Control Bus.
The address bus carries the address location of the data or instruction. The data bus carries data
from one component to another and the control bus carries the control signals. The system bus is
the common communication path that carries signals to/from CPU, main memory and
input/output devices. The input/output devices communicate with the system bus through the
controller circuit which helps in managing various input/output devices attached to the computer.
Conclusion:
Enrollment Number: 220210107041
Quiz:
4
Enrollment Number: 220210107041
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
5
Enrollment Number: 220210107041
Experiment No: 2
Date:
Write the working of 8085 Simulator GNUsim8085.
Objectives:
Explanation:
8085 simulator is software on which instructions are executed by writing the programs in assembly
language.
GNUSim8085 is an 8085 microprocessor simulator with following features.
6
Enrollment Number: 220210107041
Labels:-
When given to any particular instruction/data in a program, takes the address of that instruction or
data as its value. But it has different meaning when given to EQU directive. Then it takes the
operand of EQU as its value. Labels must always be placed in the first column and must be
followed by an instruction (no empty line). Labels must be followed by a : (colon), to differentiate
it from other tokens.
Operations:-
As mentioned above the operations can be specified in two ways that are mnemonics and pseudo
operation.
Pseudo operations can be defined by using following directives:-
There are only 3 directives currently available in our assembly language.
1. DB - define byte ( 8 bits )
2. DS - define size (no. of bytes)
3. EQU - like minimalistic #define in C
DB is used to define space for an array of values specified by comma separated list. And the label
(if given to the beginning of DB) is assigned the address of the first data item.
DS is used to define the specified number of bytes to be assigned and initialize them to zero. To
access each byte you can use the + or -operator along with label.
EQU behaves similar to #define in C. But it is simple. It can be used to give names only to
numeric constants. Nesting of EQU is not allowed. You can use EQU only in operands for pseudo
ops and mnemonics.
Operands:-
Operands are specified according to the user. The register set specified in the architecture of 8085
(A, B, C, D, E, H and L) are used to access and store data. These registers are specified as
operand. In case of accessing data or storing data in the memory ‘m’ is specified as an operand
and the address of this memory location is taken from the HL pair (data in HL pair).
7
Enrollment Number: 220210107041
Picture 1
Step 1: Open GNU Sim 8085 above window will open. Now click on close button highlighted in
the above screen shot.
8
Enrollment Number: 220210107041
Picture 2
Step 2: Start writing the code after start: nop in load me at 10 that is at load me at 11.
Picture 3
Step 3: Click on reset and reset all the registers by clicking on reset all.
Picture 4
Step 4: click on the highlighted button to execute the code
9
Enrollment Number: 220210107041
Picture 5
Step 5: after you execute the code mention the name your program by writing the name in the
name section as mentioned in the screen shot in picture 5 and the drive where you want to save it.
After that click on save.
Picture 6
Step 6: after this you will see the result of the instructions in the respective registers as seen in the
above picture 6.
10
Enrollment Number: 220210107041
Conclusion:
Quiz:
2) How we can set the value at memory location and I/O port?
11
Enrollment Number: 220210107041
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
12
Enrollment Number: 220210107041
Experiment No: 3
Date:
Study basic architecture of 8085 along with small introduction.
Objectives:
Explanation:
The architecture of the 8085 microprocessor consists of several key components, including the
accumulator, registers, program counter, stack pointer, instruction register, flags register, data
bus, address bus, and control bus.
13
Enrollment Number: 220210107041
Flag Register:
It is an 8-bit register that stores either 0 or 1 depending upon which value is stored in the
accumulator. Flag Register contains 8-bit out of which 5-bits are important and the rest of 3-bits
are “don’t Care conditions”. The flag register is a dynamic register because after each operation to
check whether the result is zero, positive or negative, whether there is any overflow occurred or
not, or for comparison of two 8-bit numbers carry flag is checked. So for numerous operations to
check the contents of the accumulator and from that contents if we want to check the behavior of
given result then we can use Flag register to verify and check. So we can say that the flag register
is a status register and it is used to check the status of the current operation which is being carried
out by ALU.
Different Flags are: Carry Flag, Parity Flag, Auxiliary Carry Flag, Zero Flag, Sign Flag
Accumulator:
Accumulator is used to perform I/O, arithmetic, and logical operations. It is connected to ALU
and the internal data bus. The accumulator is the heart of the microprocessor because for all
arithmetic operations Accumulator’s 8-bit pin will always there connected with ALU and in most-
off times all the operations carried by different instructions will be stored in the accumulator after
operation performance.
Program Counter:
Program Counter holds the address value of the memory to the next instruction that is to be
executed. It is a 16-bit register.
Stack Pointer:
It works like a stack. In stack, the content of the register is stored that is later used in the program.
It is a 16-bit special register. The stack pointer is part of memory but it is part of Stack operations,
unlike random memory access. Stack pointer works in a continuous and contiguous part of the
memory. Whereas Program Counter (PC) works in random memory locations. This pointer is
very useful in stack-related operations like PUSH, POP, and nested CALL requests initiated by
Microprocessor. It reserves the address of the most recent stack entry.
Temporary Register:
14
Enrollment Number: 220210107041
It is an 8-bit register that holds data values during arithmetic and logical operations.
The address bus is a 16-bit bus that is used to address memory and other devices. The address
bus is used to select the memory location or device that the microprocessor wants to access.
The control bus is a set of signals that controls the operations of the microprocessor, including
the read and write operations. The control bus includes signals such as the read signal, write
signal, interrupt signal, and reset signal. The read signal is used to read data from memory or
other devices, the write signal is used to write data to memory or other devices, the interrupt
signal is used to signal the microprocessor that an interrupt has occurred, and the reset signal is
used to reset the microprocessor to its initial state.
Conclusion:
Quiz:
15
Enrollment Number: 220210107041
3) What are the data bus, address bus and control bus?
16
Enrollment Number: 220210107041
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
17
Enrollment Number: 220210107041
Experiment No: 4
Date:
Write following 8085 assembly language programs with output.
Objectives:
Explanation:
LDA 2050H ; Read 8-bit value from memory location 2050H in A register
MOV B, A ; Copy value of A register in B
LDA 2051H ; Read 8-bit value from memory location 2051H in A register
ADD B ; Add register B contents to A and store the sum in A register
STA 2052H ; Store the sum from A register on memory location 2052H
HLT ; Stop the execution
LXI H, 2050H ; Load 16-Bit address in HL register pair (location of first value)
MOV A, M ; Copy value from location stored in HL register pair to A
INX H ; Increment address in HL register pair (location of second value)
ADD M ; Add second value from M to A and store the sum in A register
INX H ; Increment address in HL register pair (location of result to be stored)
18
Enrollment Number: 220210107041
MOV M, A HLT ; Store the value from A register to M (location point by HL register pair)
; Stop the execution
Output:
b. To add five 8-bit numbers and store sum and carry in memory location.
JMP START
; Jump on start label
DATA: DB 01H, 05H, 08H, 99H,
; Five 8-bit values stored named as DATA
12H
COUNT: DB 05H
; Count value is stored in COUNT
SUM: DB 00H
; Initial value of SUM is 00H
CARRY: DB 00H
; Initial value of CARRY is 00H
START: LDA COUNT
; Load COUNT value in A register
MOV C, A
; Copy COUNT value in C register from A
MVI A, 00H
; Clear value of A register (to store sum)
MVI B, 00H
; Clear value of B register (to store carry)
LXI H, DATA
; Load 16-Bit address of DATA in HL register pair
LOOP: ADD M
; Add first value to A register
JNC NEXT
;Check if Carry flag is not set, take jump on label
NEXT
INR B
; if Carry flag is set increment B register value
NEXT: INX H
;Increment address in HL register pair (for other
values)
DCR C
; Decrement C register value (to decrement count
value)
JNZ LOOP
; if Zero flag is not set, take jump on label LOOP
STA SUM
; Store sum from A register in SUM
MOV A, B
; Copy B register value to A (to store carry in
CARRY)
STA CARRY
; Store carry from A register to CARRY
HLT
; Stop the execution
Output:
19
Enrollment Number: 220210107041
c. Perform addition of two 8-bit numbers and store result after using DAA instruction.
MVI A, 05H ; Store 8-bit value in A register
MVI B, 07H ; Store 8-bit value in B register
ADD B ; Add value of B register to A, sum is in A register ( 05H + 07H = 0CH )
DAA ; Decimal Adjust Accumulator (convert value higher than 09 to BCD)
STA 2050H ; Store the result on the location 2050H
HLT ; Stop the execution
Output:
20
Enrollment Number: 220210107041
f. Find minimum and maximum from five 8-bit numbers stored in memory location.
JMP START
; Jump on start label
DATA: DB 56H, 32H, 59H,
; Five 8-bit values stored named as DATA
01H, 23H
MAX: DB 00H
; Initial value of MAX is 00H
MIN: DB 00H
; Initial value of MIN is 00H
START: MVI C, 05H
; Initial value of C register is 05H (work as counter)
LXI H, DATA
; Load 16-Bit address of DATA in HL register pair
MOV B, M
; Copy first value in B register from M (B will store Max
value)
MOV D, M
; Copy first value in D register from M (D will store Min
value)
LOOP: MOV A, M
; Copy first value in A register
CMP B
; Compare the value of A and B register
JC MINI
; Check if Carry flag is set, take a jump on label MINI
MOV B, A
; if Carry flag is not set, copy the value of A register to B
MINI: CMP D
; Compare the value of A and D register
JNC SKIP
; if Carry flag is not set, take a jump on label SKIP
MOV D, A
; if Carry flag is set, copy the value of A register to D
SKIP: INX H
; Increment address in HL register pair (for other values)
DCR C
; Decrement C register value (to decrement count value)
JNZ LOOP
; if Zero flag is not set, take jump on label LOOP
MOV A, B
; Store B register value in A (Max value)
STA MAX
; Store value from A register to MAX
MOV A, D
; Store D register value in A (Min value)
STA MIN
; Store value from A register to MIN
HLT
; Stop the execution
Output:
21
Enrollment Number: 220210107041
Conclusion:
Quiz:
22
Enrollment Number: 220210107041
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
23
Enrollment Number: 220210107041
Experiment No: 5
Date:
Write following 8085 assembly language programs with output.
a. To add two arrays of five 8-bit values and store result in third array.
b. To store sum of unpacked BCD numbers from packed BCD numbers.
c. To store an ASCII value of each Hex digits.
d. To set an MSB of an 8-bit values if it has even no. of 1’s.
e. To reverse an array of ten 8-bit values using subroutine.
f. Find factorial of given 8-bit value.
g. To perform division of 16-bit number by 8-bit number.
Objectives:
Explanation:
a. To add two arrays of five 8-bit values and store result in third array.
JMP START ; Jump on start
DATA1: DB 01, 02, 03, 04, 05 ; First Array
DATA2: DB 06, 07, 08, 09, 10 ; Second Array
SUM: DS 5 ; Third array to store sum
COUNT: DB 05 ; Counter value
START: LXI B, DATA1 ; Load address of DATA1 in BC reg. pair
LXI H, DATA2 ; Load address of DATA2 in HL reg. pair
LXI D, SUM ; Load address of SUM in DE reg. pair
LOOP: LDAX B ; Start of LOOP; Read values from DATA1
ADD M ; Add values from DATA2
STAX D ; Store sum in SUM
INX B ; Increment location of DATA1
INX H ; Increment location of DATA2
INX D ; Increment location of SUM
LDA COUNT ; Load count in A register
DCR A ; Decrement count value in A register
STA COUNT ; Store count from A register
JNZ LOOP ; Check Zero flag, if it is not set go back to LOOP
HLT ; Stop the execution
24
Enrollment Number: 220210107041
Output:
25
Enrollment Number: 220210107041
Output:
26
Enrollment Number: 220210107041
27
Enrollment Number: 220210107041
28
Enrollment Number: 220210107041
Output:
Conclusion:
Quiz:
29
Enrollment Number: 220210107041
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
30
Enrollment Number: 220210107041
Experiment No: 6
Date:
Design ALU using Logisim.
Competency and Practical Skills: working of ALU, arithmetic and logical operations,
concepts of Digital fundamentals for logic gates, adders, etc.
Objectives:
Equipment/Instruments: Logisim
Explanation:
31
Enrollment Number: 220210107041
32
Enrollment Number: 220210107041
Conclusion:
Quiz:
33
Enrollment Number: 220210107041
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
34
Enrollment Number:
Experiment No: 7
Date:
Implement Booth’s multiplication algorithm.
Objectives:
Explanation:
Booth algorithm gives a procedure for multiplying binary integers in signed 2’s complement
representation in efficient way, i.e., less number of additions/subtractions required. It operates on
the fact that strings of 0’s in the multiplier require no addition but just shifting and a string of 1’s
in the multiplier from bit weight 2k to weight 2m can be treated as 2(k+1) to 2m. As in all
multiplication schemes, booth algorithm requires examination of the multiplier bits and shifting of
the partial product. Prior to the shifting, the multiplicand may be added to the partial product,
subtracted from the partial product, or left unchanged according to following rules:
1. The multiplicand is subtracted from the partial product upon encountering the first least
significant 1 in a string of 1’s in the multiplier
2. The multiplicand is added to the partial product upon encountering the first 0 (provided
that there was a previous ‘1’) in a string of 0’s in the multiplier.
3. The partial product does not change when the multiplier bit is identical to the previous
multiplier bit.
AC and the appended bit Qn+1 are initially cleared to 0 and the sequence SC is set to a number n
equal to the number of bits in the multiplier.
The next step is to shift right the partial product and the multiplier (including Qn+1). This is an
arithmetic shift right (ashr) operation which AC and QR to the right and leaves the sign bit in AC
unchanged.
The sequence counter is decremented and the computational loop is repeated n times.
Product of negative numbers is important, while multiplying negative numbers we need to find
2’s complement of the number to change its sign, because it’s easier to add instead of performing
binary subtraction. Product of two negative numbers is demonstrated below along with 2’s
complement.
Example – A numerical example of booth’s algorithm is shown below for n = 4. It shows the step
by step multiplication of -5 and -7.
BR = -5 = 1011,
BR'+1 = 0101 <-- 2's Complement (add 1 to the Binary value obtained after 1's complement)
Qn Qn+1 = 10
OPERATION AC QR Qn+1 SC
0 1001 0 4
AC + BR’ + 1 0101 1001 0
ASHR 0010 1100 1 3
AC + BR 1101 1100 1
ASHR 1110 1110 0 2
ASHR 1111 0111 0 1
AC + BR’ + 1 0100 0111 0
ASHR 0010 0011 1 0
Conclusion:
37
Enrollment Number:
Quiz:
38
Enrollment Number:
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
39
Enrollment Number:
Experiment No: 8
Date:
Study interconnection structures of components of multiprocessor system.
Objectives:
Explanation:
The components that form a multiprocessor system are CPUs, IOPs connected to input output
devices, and a memory unit.
The interconnection between the components can have different physical configurations,
depending on the number of transfer paths that are available
Between the processors and memory in a shared memory system
Among the processing elements in a loosely coupled system
There are several physical forms available for establishing an interconnection network.
40
Enrollment Number:
Disadvantage:
Only one processor can communicate with the memory or another processor at any given
time.
As a consequence, the total overall transfer rate within the system is limited by the speed
of the single path.
Multiport Memory
A multiport memory system employs separate buses between each memory module and each
CPU. The module must have internal control logic to determine which port will have access to
41
Enrollment Number:
memory at any given time. Memory access conflicts are resolved by assigning fixed priorities to
each memory port.
Advantage:
The high transfer rate can be achieved because of the multiple paths.
Disadvantage:
It requires expensive memory control logic and a large number of cables and connections.
Crossbar Switch
It consists of a number of cross-points that are placed at intersections between processor buses
and memory module paths. The small square in each cross-point is a switch that determines the
path from a processor to a memory module.
Advantage:
Supports simultaneous transfers from all memory modules.
42
Enrollment Number:
Disadvantage:
The hardware required to implement the switch can become quite large and complex.
Below fig. shows the functional design of a crossbar switch connected to one memory module.
Using the 2x2 switch as a building block, it is possible to build a multistage network to control the
communication between a number of sources and destinations. To see how this is done, consider
the binary tree shown in Fig. below.
43
Enrollment Number:
One such topology is the omega switching network shown in Fig. below
Some request patterns cannot be connected simultaneously. i.e., any two sources cannot be
connected simultaneously to destination 000 and 001. In a tightly coupled multiprocessor system,
the source is a processor and the destination is a memory module. Set up the path → transfer the
address into memory → transfer the data. In a loosely coupled multiprocessor system, both the
source and destination are processing elements.
Hypercube System
The hypercube or binary n-cube multiprocessor structure is a loosely coupled system composed of
N=2n processors interconnected in an n-dimensional binary cube.
Each processor forms a node of the cube, in effect it contains not only a CPU but also
local memory and I/O interface.
Each processor address differs from that of each of its n neighbors by exactly one bit
position.
Fig. below shows the hypercube structure for n=1, 2, and 3.
44
Enrollment Number:
Routing messages through an n-cube structure may take from one to n links from a source node to
a destination node.
A routing procedure can be developed by computing the exclusive-OR of the source node
address with the destination node address.
The message is then sent along any one of the axes that the resulting binary value will
have 1 bits corresponding to the axes on which the two nodes differ.
A representative of the hypercube architecture is the Intel iPSC computer complex.
It consists of 128(n=7) microcomputers, each node consists of a CPU, a floating point
processor, local memory, and serial communication interface units.
Conclusion:
Quiz:
45
Enrollment Number:
46
Enrollment Number:
Suggested Reference:
Good Average Good Average Good Satisfactory Good Satisfactory Good Average
(2) (1) (2) (1) (2) (1) (2) (1) (2) (1)
Rubrics 1 2 3 4 5 Total
Marks
47