0% found this document useful (0 votes)
3 views96 pages

Computer Organisation

The document provides an overview of computer organization and operating systems, detailing the basic structure of computers, types of computers, and their functional units. It discusses various components such as the processor, memory, and buses, as well as the role of software and operating systems in managing hardware resources. Additionally, it covers performance metrics and factors affecting computer performance.
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)
3 views96 pages

Computer Organisation

The document provides an overview of computer organization and operating systems, detailing the basic structure of computers, types of computers, and their functional units. It discusses various components such as the processor, memory, and buses, as well as the role of software and operating systems in managing hardware resources. Additionally, it covers performance metrics and factors affecting computer performance.
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/ 96

MALLAREDDY ENGINEERING COLLEGE FOR

WOMEN
(Autonomous Institution-UGC, Govt. of India)
Accredited by NBA & NAAC with ‘A’ Grade, UGC, Govt. of India NIRF Indian
Ranking–2018, Accepted by MHRD, Govt. of India
COMPUTER ORGANIZATION AND
OPERATING SYSTEMS

Mr.K.Raghavendra
Associate Professor, ECE Dept.
UNIT – I
3
UNIT - I
Basic Structure of Computers
Computer Types, Functional unit, Basic Operational Concepts, Bus structures,
Software performance, Multiprocessors and Multi Computers, Data Representation,
Fixed Point Representation, Floating - Point Representation.

Register Transfer Language and Micro Operations


Register Transfer Language, Register Transfer Bus and Memory Transfers,
Arithmetic Micro Operations, Logic Micro Operations, Shift Micro Operations,
Arithmetic Logic Shift Unit, Instruction Codes, Computer Registers Computer
Instructions - Instruction Cycle.

Memory
Reference Instructions, Input - Output and Interrupt, STACK Organization, Instruction
Formats, Addressing Modes, DATA Transfer and Manipulation, Program Control,
Reduced Instruction Set Computer.
4
INTRODUCTION

5
What is Computer?

o A fast electronic calculating


machine.
o Accepts digital input,
Processes it according to
the internally stored
instructions (Programs).
o Produces the result on the
output device.
o Executes a program.
6
What is Organization?

Organize -
o Arranging the things in a systemically or in an
order.
Organization –
o One or a group of people working with a
particular purpose.
Computer Organization –
o Software, Hardware and User.
7
Internal operations in Computer

8
What is Computer organization?

9
Types of Computers

10
Types of Computers

Types of Computers

Size and
Capacity Purpose

Types of Data Number of Number


Handling Microprocessor of Users

11
Computer classification based on size and capacity

Types of Computers based on size and Capacity

Super
Embedded
Computers
Computers
Mainframe Micro
Mini Computers
Computers Computers

12
Computer classification based on data handling

Types of Computers based on Data Handling

Analog Digital Hybrid


Computers Computers Computers

13
μPs

Types of Computers based on number of μPs

Sequential Parallel
Computers Computers

14
Computer classification based on Users

Types of Computers based on Users

Single User Multi User


Network
Computers Computers

15
Computer classification based on Purpose

Types of Computers based on Purpose

General Specific
Computers Computers

16
Computer
Definition

Super Computer : A computer that is considered to be fastest in the


world. Used to execute tasks that would take lot of time for other
computers. For Ex: Modeling weather systems, genome sequence,
etc.

17
Computer Definition

Mainframe Computer : A computer that a large, powerful computer


that can handle many tasks concurrently and is usually used
commercially.

18
Computer Definition

Mini Computer : A large, powerful computer that can handle many


tasks concurrently and is usually used commercially.

19
Computer Definition

Micro Computer : A complete computer made on small scale,


designed to be operated by an individual person at a time. It is
smaller in size than the mainframe or minicomputer.

20
Computer Definition

Embedded Computer : sometimes known as “Embedded systems” -


are purpose-built computing platforms designed for a specific task or
fixed functionality.

21
FUNCTIONAL
UNIT

22
Functional unit

Arithmetic
INPUT and Logic

I/O Unit MEMOR Processor


Y

OUTPUT Control

23
Information Handelled by a Computer
Information – Instruction or Data.
Instructions – Commands
• Govern the transfer of information within a computer as
well as between the computer and its I/O devices .
• Specify the arithmetic and logic operations to be
performed.
Program – set of instructions that performs a task.
• Stored in memory
• One instruction is fetched and processed by processor
24
Information Handelled by a Computer

Information – Instruction or Data.


Data –
• Numbers and encoded characters
• Are part of instructions.
Instruction or data must be encoded in a suitable
format – 0 and 1.

25
Functional unit - Input Unit
o Accepts the coded information.
o Reads the data.
o On pressing a key - Converts external world data to a
binary form.
o Examples:

26
Functional unit - Output Unit
o Counterpart of input unit.
o Sends the processed result.
o Converts binary format to a external world data.
o Examples:

27
Functional unit - Arithmetic and Logic Unit
o Executes most operations.
o Performs – Arithmetic and Logical
o Arithmetic operations: Addition, subtraction,
multiplication, division
o Logical operations: OR, AND, NOT, <, >, = etc.
o Instruction execution : Operands are brought into ALU
from memory.
o Stored in registers.
o Operation is performed in ALU.
o Result is stored in memory or retained in processor.
28
Functional unit – Control Unit
o Controls all Operations.

o Coordinates all the activities of all units – control


signals and timing signals.

o Decodes the instruction to be performed.

o Instruction control WHAT operations takes place, but


WHEN to take place is decided by Control Unit.

29
Functional unit - Memory Unit
o Stores – Programs and Data
o Computer memory types –
o Primary memory (Main memory)
o Secondary memory (Auxiliary memory)

30
Functional unit – Memory- Primary
o Also called main memory.
o Fast and exclusively associated with Processor and
operates at electronic speed.
o Stores programs and their data while there are being
executed.
o Semiconductor memory that access at high speed.
o Large number of storage cells (one cell – one bit)
o Cells are processed in a group of fixed size – WORD.
o Each word is associated with address.
o Word length – number of bits in each word.
31
Functional unit – Memory- Primary
o Primary memory – RAM and ROM.
RAM (DRAM)-
o Any location can be accessed in a short and fixed time.
o Volatile memory ( temporary).
o Holds programs while they are running.
ROM -
o Readable only and can’t be altered.
o Non-volatile memory (Permanent).
o System Programs and firmware routines ( BIOS, I/O
drives, etc.). 32
Functional unit – Memory- Secondary
o Also called Auxiliary memory.
o Stores large amount of data and programs.
o Stores infrequently accessed information.
o Non-Volatile memory ( Permanent).
o Cheaper, Greater storage capacity.
o Slower than primary memory.
o Not directly accessed by Processor.
o Examples – CD, DVD, Hard Disk Optical disk, USB
storage etc.
33
Basic Operational Concepts

34
Basic Operational Concepts
o Computer is governed by instructions.

o To perform a given task an appropriate program


consisting of a list of instructions is stored in the
memory.

o Individual instructions are brought from memory into


the processor, which executes the specified operations.

o Data to be stored are also stored in the memory.


35
Basic Operational Concepts
An Instruction consists of two parts
OPCODE OPERAND/s

ADD LOCA, R0
The execution steps:
Step 1: Fetch the instruction from main memory into the
processor.
Step 2: Fetch the operand at location LOCA from main
memory into the processor.
Step 3: Add the memory operand (i.e. fetched contents
of LOCA) to the contents of register R0.
Step 4: Store the result (sum) in R0. 36
Basic Operational Concepts
The same instruction can be realized using two instructions
to improve the performance as
Load LOCA, R 1 // M[LOCA] R1
Add R1, R0 // R0 + R1 R0
The execution steps:
Step 1: Fetch the instruction from main memory into the
processor
Step 2: Fetch the operand at location LOCA from main
memory into the processor Register R1
Step 3: Add the content of Register R1 and the contents of
register R0.
Step 4: Store the result (sum) in R0. 37
Connections between the Processor and the Memory

Address Data Control


Bus Bus Bus

38
Instruction Register - IR
o Contains/Holds the instruction that is being executed.
o Its contents are available with the control unit which
generates the timing signals that controls the various
processing elements in one execution of instruction.
o The control unit decodes the current instruction to be
executed.
o After decoding, execution of the instruction will take
place. 39
Program Counter - PC
o Contains the memory address of the instruction to be
executed.
o During execution, the contents of the PC are updated
to point to the next instruction.
o Every time that an instruction is to be executed, the
program counter releases its contents to the internal
bus and sends it to the memory address register.

40
Memory Address Register - MAR
o Holds the address of the location to or from which data
are to be transferred.
o The connection of the MAR to the main memory is one-
way or unidirectional.

41
Memory Data Register - MDR
o Contains the data to be written or read out of the
addressed location.
o During the fetch operation, the MDR contains the
instruction to be executed or data needed during
execution.
o In write operation, MDR the data to be written into the
main memory.

42
Typical Operating Steps:
1. Programs reside in the memory through the input unit.
2. Execution of the program starts when, the PC is set to point at
the first instruction of the program.
3. The contents of the PC are transferred to MAR and a READ
control signal is sent to the memory.
4. The instruction is read out (fetched) of the memory and loaded
into the MDR.
5. The contents of MDR are transferred to the IR.
6. The instruction in IR is decoded.
43
Typical Operating Steps:
7. If the instruction involves an ALU operations, it obtains the
required operands.
8. If an operand is in the GPRs, it is transferred to the ALU for
operation.
9. If an operand is in the memory, it id fetched by sending its
address to MAR and initiating a READ cycle.
10. When operands has been read from the memory into the MDR, it
is transferred from MDR to the ALU.

44
Typical Operating Steps:
11. When all operands are available, the ALU preforms the desired
operation.
12. Results are stored back to GPRs or memory.
13. If the result of this operation is to be stored in the memory, the
results is sent to MDR.
14. Address of location where the result has to be stored is sent to
MAR and a WRITE cycle is initiated.

45
Bus Structure

46
What is Bus?
o A Bus is a collection of wires/lines that
connects several devices.
o Each wire/line carries one bit of information.
o Buses are used to send address, data and
control signals between the processor and
other components.
o This is to achieve a reasonable speed of
operation.
o In computer system all the peripherals are
connected to microprocessor through Bus.
47
Buses: Connecting I/O to Processor and
Memory

48
Types of Buses
Three types
o Address Bus
o Data Bus
o Control Bus

System
Bus

Memory I/O 1 I/O 2 I/O 3


49
Address Bus

o Uni-directional
o Carries the memory address from processor
to peripherals.
o Address bus carry I/O port address or device
address from I/O port.
o Address bus width determines the maximum
memory capacity.
o With n address line 2n memory location. 50
Data Bus

o Bi-directional.

o Carries the data from processor to peripherals


and vice-versa.

o Data bus width determines the system


performance.

51
Control Bus

o Bi-directional.

o Carries the control signals from processor to


peripherals and vice-versa.

o Controls access to address bus and data bus.


o Controls the use of address bus and data bus.

52
Types of Control Signals:
Memory Read: Issued by the CPU or DMA controller
when performing a read operation with the memory.
Memory Write: Issued by the CPU or DMA controller
when performing a write operation with the memory.
I/O Read: Issued by the CPU when it is reading from
an input port.
I/O Write: Issued by the CPU when writing into an
output port.
Ready: Issued to the CPU to synchronize the slow
memory or I/O ports with the fast CPU.
53
Types of Buses

54
Types of Bus Structures

Types of Bus Structures

Single Bus structure Multi Bus structure

55
Single Bus Structure

o Simplest way to connect functional units.


o Uses only one bus to connect all the elements.
o Common bus to communicate between processor and
peripherals.
o One transfer at a time – only two units can be actively
use the bus at a given time.
56
Single Bus Structure : Advantages & Disadvantages
Advantages:
o Low initial cost.
o Less maintenance.
o Simple in operation.
o Very flexible to attach peripheral.

Disadvantages
o Occurrence of any fault occur affects all the elements
of the system.
o Low Performance – devices vary in speed of
operation.
57
Multi Bus Structure
o One bus is used to fetch
instruction.
o While other is used to
fetch data, required for
execution.
o It is to overcome the
bottleneck of single bus
o Contains multiple buses
– more Parallelism.
o Improves performance
and also increases cost.
58
Software

59
Software System

Software - Collection of programs that are executed as


needed to perform various functions such as:
o Receiving and interpreting user commands.
o Entering and editing application programs.
o Managing the storage and retrieval of files on
secondary storage devices.
o Running applications like word processors,
spreadsheets and etc.
o Controlling I/O units.
o Translating programs to machine instructions.
o Linking programs with library routines.
60
Software - Operating System (OS)
Operating System (OS) is a collection of routines used to
control the sharing of and interaction among various
computer units as they execute application programs.

o Assign computer resources to individual application


programs.
o Assign memory and magnetic disk space to program.
Move data between memory and disk units.
o Handle I/O operations.

61
User program and OS routine sharing of the processor

Transfer data
OS loads file from disk
application and prints the
program results.
from disk.

Waits for transfer to OS loads


Waits for transfer to
occur, then passes data file from
occur, then passes
execution control to disk.
execution control to
application program. application program.62
Performance

63
Performance
o Measures of how fast a computer can execute
a program.
o Factors affecting performance:
Design of the computer’s hardware.
Machine language instruction set.
Compiler.
o Performance is increased by the coordination
between the three factors.
64
Performance
o Elapsed Time : t0 – t5.

o Affected by speed of –
Processor
Disk
Printer
o Measures performance of the computer system.
o Depends on all of the units.

65
Performance – Processor time
o Processor performance – Processor time.
o Period during which the processor is active –
(Program and OS routine)
o To increase “performance” – minimized
“processor time”
o Depends on the hardware involved in the
execution of the machine instructions.
66
Performance – Processor time
o Processor time depends –

o Cache Memory – Increases performance


o Instructions are fetched and a copy is placed in cache
– If the same instruction or data item is needed, it is
read directly from cache.
o Single chip – Cache memory and processor. 67
Processor Performance
Depends on –
o Processor Clock
o Clock Rate
o Basic Performance Equation
o Pipelining and Superscalar operation
o Instruction Set
o Complier
68
Processor Clock
o Processor circuits are controlled by a timing signal
called a “clock”.
o Clock – the regular time intervals called “clock
cycles”.
o Processor divides machine instruction into a
sequence of basic steps.
o Each basic step are executed in one clock cycle.
69
Processor Clock
o Let P be the length of one clock cycle, then
the clock rate R is the inverse, R=1/P
o P is measured in seconds and R is measured
in cycles per second i.e. hertz.
o Clock rates ranging from few million to over a
billion cycles per second (or hertz)
70
Clock Rate
o Performance is increased – Increasing clock rate.
o Two ways :
Improving the integrated circuit (IC) and
making the circuits faster, thus reducing the
time to complete a basic step.
Reduce the amount of processing in a basic
step.

71
Basic Performance Equation

72
Pipelining and Superscalar Operation

Non-Pipelined Architecture
Pipelined Architecture

o Pipelining - Organizes the execution of the multiple instructions


simultaneously.
o Improves the throughput of the system.
o A higher degree of concurrency can be achieved if there were multiple
pipelines implemented in the processor – superscalar execution.
73
Instruction Set: RISC
o Simple instructions have a small number of steps per instruction
(small S).
o Processor using only simple instructions, could have a large
number of instructions, N and a small number of steps per
instruction, S.
o Simple instructions are more in number and with more efficient
pipelining, a lower S value can be achieved.
o Processors that use simple instructions are called Reduced
Instruction Set Computers (RISC).
74
Instruction Set: CISC
o Complex instructions have a larger number of steps per
instruction (larger S).
o Processor using only complex instructions, could have a small
number of instructions, N, and a large number of steps per
instruction, S.
o Complex instructions are less in number and with pipelining, a
lower S value can be achieved.
o Processors that use complex instructions are called Complex
Instruction Set Computers (CISC).
75
Compiler
o Translates a high level language program into machine level
language.
o Optimized Compiler reduces N X S ( reduce the total number of clock
cycles).
o Reduces the total number of clock cycles needed to execute a
program.
o The number of clock cycles required depends upon :
o Choice of instructions
o Order of instruction they appear in the program.
o Compiler and Processor are designed at the same time – to achieve
best results.
76
Performance Measurement

77
Multiprocessors & Multicomputers

78
Multiprocessors

79
Multiprocessors

80
Multiprocessors
o A system with two or more CPUs or processors.
o Can execute tasks at the same time.
o Failure in one processor will not affect the tasks of the other
processors - more reliable.
o Two types –
Shared memory multiprocessor –
▪ all the CPUs shares the common memory.
▪ processors communicate with each other by reading and
writing to the memory.
Distributed memory multiprocessor –
▪ every CPU has its own private memory.
▪ If the required data is not available in the private memory, the
processor communicates with the main memory or the other
processors via the bus. 81
Multicomputers

Message Passing
Interconnect Network

82
Multicoumpters
o A system with multiple processors that are connected together to
solve a problem.
o Each processor has its own memory and it is accessible only by
that particular processor.
o The processors can communicate with each other via an
interconnection network.
o A task is divided between processors.
o Processors communicate with each other by passing messages
between them.
83
Difference

84
Data Representation

85
Information
Interpretation of information handled by computer –
Data Representation.

86
Fixed point Representation
o A positive and negative integer number.
o With the help of fixed number representation –
data is converted into binary form
data is processed
Stored
used by the system.
o Also known as Integer Number Representation.

87
Fixed point Representation
Range : For n bits
-2n-1 to + (2n-1-1)

Range : For n bits


0 to + (2n-1)
88
Signed Representation
o Three ways:
Sign and Magnitude
1’s Complement
2’s Complement

89
Signed Representation – Sign & Magnitude
o Uses most significant bit of the word to represent the sign.
0 - Positive
1 - Negative.
MSB LSB
o Rest of the number is encoded in magnitude part.
o Examples :
+37 = 00100101
-37 = 10100101
+6712 = 00011010 00111000
-6712 = 10011010 00111000
90
Signed Representation – 1’s Complement
o Negative number is stored as bit-wise complement of
corresponding positive number.
o Leftmost bit of positive number is 0 and negative number is
1.
o +196 = 00000000 11000100
o -196 = 11111111 00111011
o Arithmetic is easier than sign-magnitude.
o Two representations for zero:
+0 = 00000000 00000000
-0 = 11111111 11111111 91
Signed Representation – 2’s Complement
o Negative number obtained by taking 1's Complement of
positive number and adding 1.

o +6713 = 00011000 00011101


1's Comp = 11100111 11100010
2's Comp = 11100111 11100011

o One representations for zero:

o +0 = 00000000 00000000

o -0 = 00000000 00000000
92
Floating point Representation
o Can represent a very large positive and
negative numbers. As well as zero.
o Example: 1.23 × 1088
1.23 × 10-88
-1.23 × 1088
-1.23 × 10-88
o Typically expressed in the scientific notation,
with a fraction (m) also known as mantissa,
and an exponent (e) of a certain radix (r), in
the form of m × re . 93
Floating point Representation
o In computers, floating-point numbers are
represented with a radix of 2, in the form
of M×2^E'.
o Both E and m can be positive as well as
negative.
o Modern computers adopt IEEE 754 standard
for representing floating-point numbers.
o There are two representation schemes:
32-bit single-precision
64-bit double-precision.
94
IEEE-754 32-bit Single-Precision Floating-Point Numbers
o The most significant bit is the sign bit (S), with 0 for
positive numbers and 1 for negative numbers.
o The following 8 bits represent Biased Exponent (E').
o The remaining 23 bits represents fraction or
mantissa (m or M).

95
IEEE-754 64-bit Double-Precision Floating-Point Numbers
o The most significant bit is the sign bit (S), with 0 for
positive numbers and 1 for negative numbers.
o The following 11 bits represent Biased Exponent (E').
o The remaining 52 bits represents fraction or
mantissa (m or M).

96

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy