KEMBAR78
Module1 Computer Organization BSC DataScience | PDF | Computer Data Storage | Random Access Memory
0% found this document useful (0 votes)
16 views24 pages

Module1 Computer Organization BSC DataScience

A computer system integrates hardware and software to process data through an Input-Process-Output model, enabling various functions such as automation and data analysis. Key components include the CPU, memory, input/output units, and storage systems, each serving specific roles in data handling. The document also details memory types, including volatile RAM and non-volatile ROM, as well as secondary storage options and cache memory for performance enhancement.

Uploaded by

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

Module1 Computer Organization BSC DataScience

A computer system integrates hardware and software to process data through an Input-Process-Output model, enabling various functions such as automation and data analysis. Key components include the CPU, memory, input/output units, and storage systems, each serving specific roles in data handling. The document also details memory types, including volatile RAM and non-volatile ROM, as well as secondary storage options and cache memory for performance enhancement.

Uploaded by

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

Module 1

COMPUTER SYSTEM

 A computer system is an integrated setup of hardware and software designed to


accept data as input, process it according to specific instructions, store and
retrieve data when required, and produce meaningful output for the user.
 It plays a central role in modern society, enabling automation, computation,
communication, and data analysis across a wide range of domains.
 A typical computer system operates based on the Input-Process-Output (IPO)
model:
Input: Accepts data from the user through input devices.
Process: Manipulates or transforms the data using a central processor.
Output: Presents the processed information to the user via output devices.
Storage: Saves data and instructions for current or future use.
 Key Features of a Computer System:
Speed: Computers can perform millions of instructions per second.
Accuracy: They process data with high precision, provided the input is correct.
Automation: Once programmed, they operate automatically without manual
intervention.
Storage Capacity: Computers can store vast amounts of data and make it
available instantly.
Versatility: They can execute a wide range of applications, from calculations to
video editing.
Multitasking: Modern systems can perform multiple tasks simultaneously.
 Components of a Computer System:
Hardware: The physical components (CPU, memory, motherboard, I/O devices).
Software: The set of instructions that tell the hardware what to do (operating
system, applications).
Users: People who interact with the system to perform tasks or control its
operations.
Data: Raw facts and figures that are processed into meaningful

BASIC FUNCTIONS OF A COMPUTER

1. Inputting. It is the process of entering data and instructions into a computer


system.
2. Storing. It is the process of saving data and instructions.
3. Processing. Performing arithmetic operations (add, subtract, multiply, divide,
etc.), or logical operations. (comparisons like equal to, less than, greater than,
etc.) on data to convert them into useful information is known as processing.
4. Outputting. It is the process of producing useful information or results for a
user, such as printed report or visual display.
5. Controlling. Directing the manner and sequence in which the above operations
are performed is known as controlling.

BASIC COMPUTER ORGANIZATION

Computer Architecture refers to the design and organization of a computer’s core


components — specifically how the CPU, memory, input/output units, and
storage systems interact to execute instructions efficiently.
Functional Units of a Computer
Input unit
An input unit performs inputting operation. It carries out the following functions:
(a) It accepts (or reads) instructions and data from outside world.
(b) It converts these instructions and data to computer acceptable form. Units
called input interfaces
accomplish this task.
(c) It supplies the converted instructions and data to the storage unit for storage
and further processing.
Central Processing Unit (CPU)
 Also known as the brain of the computer, responsible for processing all
instructions.
 Consists of:
o Arithmetic and Logic Unit (ALU): Performs all arithmetic (add, subtract)
and logical (AND, OR, NOT) operations.
o Control Unit (CU): Directs operations of the processor and controls the
flow of data among all parts.
o Registers: Small, fast memory units within the CPU that temporarily store
instructions, addresses, or intermediate data
Memory Unit

A storage unit performs storing operation. Specific functions of the storage unit
are to hold
(store):
(a) The data and instructions required for processing (received from input units).
(b) Intermediate results of processing.
(c) Final results of processing, before the system releases them to an output unit.
Storage unit of all computers is comprised of the following two types of
storage:-

Primary storage.
Primary storage of a computer system, also known as main memory, stores pieces
of program instructions and data, intermediate results of processing, and recently
produced results of those job(s) on which the computer system is currently
working. The central processing unit can access these pieces of information
directly at a very fast speed. However, primary storage is volatile, and it loses the
information in it as soon as the computer system switches off or resets. Moreover,
primary storage normally has limited storage capacity because it is very
expensive. Primary storage of modern computer systems is made up of
semiconductor devices.
Secondary storage.
Secondary storage of a computer system, also known as auxiliary storage, takes
care of the limitations of primary storage. It supplements the limited storage
capacity and volatile characteristic of primary storage. This is because secondary
storage is much cheaper than primary storage and it can retain information even
when the computer system switches off or resets. A computer system uses
secondary storage to store program instructions, data, and information of those
jobs on which the computer system is currently not working but needs to hold
them for processing later. The most commonly used secondary storage medium is
magnetic disk.
Output Unit
An output unit performs outputting operation. It carries out the following
functions:
(a) It accepts the produced results, which are in coded form. We cannot
understand the coded results easily.

(b) It converts these coded results to human acceptable (readable) form. Units
called output interfaces accomplish this task.

(c) It supplies the converted results to outside world.

MEMORY ARCHITECTURES

Primary memory

A storage unit of a computer system is characterized and evaluated based on the


following properties:

1. Storage capacity. It is the amount of data, which the storage unit can store. Larger
storage capacity is desirable. As compared to secondary storage units, primary storage
units have less storage capacity.

2. Access time. It is the time required to locate and retrieve stored data from the storage
unit in response to a program instruction. Faster access time is preferable. As compared
to secondary storage units, primary storage units have faster access time.
3. Cost per bit of storage. It refers to the cost of a storage unit for a given storage
capacity. Lower cost is desirable. As compared to secondary storage units, primary
storage units have higher cost per bit of storage.

4. Volatile. If a storage unit can retain data stored in it even in case of power off or
interruption of power, it is called non-volatile storage. On the other hand, if a storage unit
loses data stored in it in case of power off or interruption of power, it is called volatile
storage.

5. Random access. If the time taken to access a piece of data from a storage unit is
independent of the location of the data in the storage unit, it is called random access
storage or random access memory (RAM).

Types of Memory Chips

Memory chips are classified based on their capability to retain stored data when power is
turned off or interrupted, and how easily stored data can be altered (overwritten).

RAM

• It is a volatile memory used by the CPU to store data and instructions


temporarily while the computer is on.

• Data is lost when the power is turned off.

• Stores currently running programs and their data.

• It allows both read and write operations

• Faster
• Random access (any location can be accessed directly)

• A computer’s motherboard usually has the flexibility to add more memory chips
for enhancing the memory capacity of the system.

• RAM chips, which plug into special sockets on the motherboard, are known as
single in-line memory modules (SIMMs).

1. SRAM (Static RAM):

• Uses flip-flops to store each bit.

• Faster and more reliable.

• Expensive.

• doesn’t require refreshing to retain data.

• Offers limited storage space.

• Has very low latency and quick access.

• Used in cache memory (L1, L2, L3).

2. DRAM (Dynamic RAM):

• Stores each bit using a capacitor and a transistor.

• Slower than SRAM.

• Cheaper and higher density.

• Used as main system memory.

DRAM Subtypes:

• SDRAM (Synchronous DRAM) – Syncs with system clock.

• DDR SDRAM (Double Data Rate SDRAM) – Transfers data on both rising and
falling edges of the clock signal.

• Versions: DDR, DDR2, DDR3, DDR4, DDR5 (latest).

ROM

• ROM stands for Read-Only Memory.

• It is a non-volatile memory, which means the data stored in it is not lost when the
power is turned off.
• Read-only: Data in ROM can only be read, not written or modified easily.

• Permanent storage: Stores critical instructions needed for booting up the


computer

• We can only read and use data stored in a ROM chip (we cannot change them).
This is the reason why it is called read-only memory (ROM).

Functions of ROM:

• Stores the BIOS (Basic Input Output System) or firmware.

• Performs the POST (Power-On Self Test) when the computer starts.

• Holds the program required to start a computer (called the bootstrap loader).

Types of ROM

• Mask ROM (MROM)

• Programmable ROM (PROM)

• Erasable Programmable ROM (EPROM)

• Electrically Erasable Programmable ROM (EEPROM)

• Flash ROM (Flash Memory)

1. Mask ROM (MROM)

• Data is written during manufacturing.

• Cannot be changed or erased later.

• Very cheap for mass production.

• Used in devices where the program never needs to change.

• Example: Old calculators, game cartridges.

2.Programmable ROM (PROM)

• Blank when manufactured.

• Can be programmed only once by the user using a special machine (PROM
burner).

• After writing, data cannot be changed or erased.


• Example: Used in simple embedded systems.

3.Erasable Programmable ROM (EPROM)

• Can be erased and reprogrammed.

• Data is erased by exposure to ultraviolet (UV) light.

• After erasing, it can be reprogrammed using a PROM programmer.

• Example: Used in early computers and development boards.

4. Electrically Erasable Programmable ROM (EEPROM)

• Can be erased and rewritten electrically (no UV light needed).

• Can be updated without removing it from the device.

• Slower than RAM but useful for storing small data that changes.

• Example: BIOS chip in modern computers, smart cards.

5. Flash ROM (Flash Memory)

• A modern type of EEPROM.

• Faster and more efficient.

• Used in many modern devices.

• Example: USB drives, SSDs, memory cards.

• A type of non-volatile memory that can be electrically erased and reprogrammed,


allowing it to store data even when the power is turned off.

• It combines the benefits of both ROM (non-volatility) and RAM


(reprogrammability).

• Flash memory is widely used in various devices like USB drives, SSDs,
smartphones, and embedded systems to store firmware, software, and user data.
Secondary Memory

• Store data and programs permanently.

• Secondary memory includes: hard disk drives, flash, CDs or DVDs, and USB
drives.

• This is a non-volatile type of memory


• Secondary memory holds a vast quantity of data not directly accessed by the CPU
at any time but often calls for eventual use.

• It is slower compared to primary memory but is used for storing files,


applications, and operating systems for the long term.

• It is also called external memory or auxiliary memory.

Key Characteristics:

 Permanent storage (Non-volatile)

• Large storage capacity

• Slower than primary memory

• Used for backup and long-term storage

• Cheaper per GB compared to primary memory

Types of Secondary Memory:

1. Magnetic Storage Devices

• Hard Disk Drive (HDD)

• Floppy Disk (obsolete)

• Magnetic Tape (used for backup)

• Magnetic storage devices utilize magnetic fields to store and retrieve data.

• These devices store information by magnetizing tiny areas on a surface,


representing data as magnetic patterns.

2.Optical Storage Devices

• CD (Compact Disc) – ~700 MB

• DVD (Digital Versatile Disc) – 4.7 GB to 8.5 GB

• Blu-ray Disc – up to 25 GB or more

• CDs and DVDs store data using microscopic pits and lands arranged in a
spiral track on a reflective surface.
• A laser reads the data by detecting the differences in how light reflects off
these pits and lands, translating these differences into binary code (0s and
1s).

3. Solid-State Storage Devices

• Solid State Drive (SSD)

• Pen Drive / USB Flash Drive

• SSDs use electronic circuits and memory cells to store data, unlike
traditional HDDs which use mechanical spinning disks.

4.Cloud Storage

• Storing data online (e.g., Google Drive, Dropbox)


Cache memory

The use of main memory helps in minimizing the disk-processor speed mismatch to a
large extent because the rate of data fetching by CPU from main memory is about 100
times faster than that from a high-speed secondary storage like disk. Still the rate at
which CPU can fetch data from memory is about 10 times slower than the rate at which
CPU can process data. Performance of processors often gets limited due to this memory-
processor speed mismatch, and we can improve the overall system performance by
minimizing the memory-processor speed mismatch. Two approaches used commonly for
doing this are use of cache memory (pronounced “cash” memory) and memory
interleaving.
• A small high speed memory that is used to increase speed processing by making
current programs and data available to CPU at a rapid rate.

• Cache memory is a type of RAM (Random Access Memory) that is faster and
smaller than main memory.

• located close to the CPU that stores frequently accessed data and instructions,
allowing the CPU to retrieve them much faster than from main memory (RAM).

• It acts as a buffer between the CPU and main memory, significantly improving
computer performance by reducing the time it takes for the CPU to access data.

• When the CPU needs data, it first checks the cache memory. If the data is found
there (a "cache hit"), it can be accessed very quickly.

• If the data is not in the cache (a "cache miss"), the CPU has to fetch it from main
memory, which takes longer.

Types of Cache Memory

• L1 Cache (Level 1): The fastest and smallest cache, often located directly on the
CPU core.

• L2 Cache (Level 2): Larger than L1 and slightly slower, may be on the CPU or
on a separate chip.

• L3 Cache (Level 3): The largest and slowest of the CPU caches, often shared
between multiple CPU cores.
• Performance Improvement: Cache memory significantly speeds up computer
operations by reducing access times to frequently used data.

• Reduced Latency: It minimizes the delay between the CPU requesting data and
receiving it.

• Efficient Use of Resources: By keeping frequently used data readily available,


cache helps optimize the use of system resources.

Advantages:

• Faster data access and processing, Reduced latency, and Improved overall system
performance.

Disadvantages:

• More expensive than main memory.

• Smaller capacity than main memory.

• Volatile, meaning data is lost when power is turned off.

Registers

• In a computer, registers are small, high-speed storage locations within the CPU
(Central Processing Unit) used to quickly access and manipulate data during
program execution.

• They hold instructions, memory addresses, or any kind of data that the CPU needs
for immediate processing.
• Program Counter (PC): Holds the memory address of the next instruction to be
executed.

• Instruction Register (IR): Holds the instruction currently being executed.

• Accumulator (ACC): Used for arithmetic and logical operations.

• Data Registers: Used to store data that is being processed.


Output Unit

• This unit consists of presenting the results of data processing on a computer to the
user or the end consumer of the product.

• The output unit takes the data that has been processed in the machine-
understandable form and translates it into a form comprehensible to the user.

• Examples of output devices are monitors, printers, and speakers. It means that the
output unit is a part of the computing process and is an interface that provides
information about the result of the computing process.

Functions of the Output Unit:

• Convert machine-readable data into human-readable form: After the data has been
analysed in the CPU it is reformatted in the output unit to form items that can be
understood by the user in the form of text, images, sound, etc.

• Deliver processed results to the user: Converted data is then presented to the
output device that shows the user the result of the commands they gave the
computer.

• This unit closes the loop between the user and the computer, ensuring effective
communication between them by delivering the final product of the computational
process.
Basic Operational Concepts

• A computer system is a machine that processes data based on a set of instructions.


To understand how a computer works at its core, we need to explore two main
ideas:

• Role of Instructions

• Computer Performance

Role of Instructions

What are instructions?

• An instruction is a single operation that the processor can execute.

• Instructions are like the smallest units of work the computer understands.

Each instruction tells the CPU to do something specific, such as:

• Add two numbers

• Move data from one place to another

• Compare two values

• Store data into memory

• Jump to another instruction (used in decision-making)

Types of Instructions:

• Arithmetic instructions: Add, subtract, multiply, divide

• Data transfer instructions: Move data from memory to CPU or vice versa

• Control instructions: Decide which instruction to run next (like "if" conditions)

• Input/output instructions: Deal with devices like keyboards, screens, etc.

How the CPU Executes Instructions

The CPU follows a cycle called the Fetch-Decode-Execute Cycle:

• Fetch: The CPU gets (fetches) the next instruction from memory.

• Decode: It decodes (interprets) what the instruction is asking.

• Execute: It performs the action (e.g., addition, data movement).


This cycle happens millions or billions of times per second.

Example:

• Let’s say you want to add two numbers:

• Instruction 1: Load number A from memory

• Instruction 2: Load number B from memory

• Instruction 3: Add A and B

• Instruction 4: Store the result in memory

Even a simple task is broken down into these basic steps.

Computer Performance

• Performance refers to how efficiently and quickly a computer system can execute
instructions and complete tasks.

Factors that affect performance:

Think of the computer as a factory, and instructions as steps in a manufacturing


process.

• The CPU is the worker.

• The clock speed is how fast the worker moves.

• The instructions are the task list.


• The memory is the storehouse where parts are kept.

• If the worker moves faster, gets parts quickly, and does tasks efficiently, more
products (results) are made in less time — better performance!

• Computers work by executing a sequence of instructions.

• These instructions tell the CPU exactly what to do.

• The Fetch-Decode-Execute cycle is how the CPU processes each instruction.

• Performance is influenced by speed, memory, instruction design, and how well


the CPU can multitask.

What is a "Language"?

• In general, a language is a system of communication using symbols, grammar,


and rules.
Just as humans use languages like English, Hindi, or Tamil to communicate with
each other, computers also need a language to receive and understand
instructions.

• But there’s a big difference:


🔸Humans understand words and emotions.
🔸 Computers only understand electrical signals — represented as 0s and 1s
(binary).

Software Language

• Computers are machines. They do not "think" or understand like humans.


They only process instructions — very specific, step-by-step commands — to
perform tasks.

• To make computers do anything (like calculations, displaying text, opening apps),


we must give instructions in a format they understand — this is where software
language comes in.

• Computer languages are divided into three main levels, based on how close they
are to human thinking or to machine understanding.

Machine Language

• Assembly Language

• High-Level Language
Machine Language (First Generation Language)

• The lowest level of computer language

• Written in binary (only 0s and 1s)

• Directly understood by the CPU (Central Processing Unit)

• Each instruction tells the hardware to do something very specific

• Example -10110000 01100001

• Fastest execution — no translation needed

• Direct control over hardware

• Difficult for humans to write, read, or debug

• Not portable — each CPU model has its own machine code

• One small error can crash the program

Assembly Language (Second Generation Language)

• A symbolic representation of machine language

• Uses short words or mnemonics to represent operations(e.g., MOV, ADD, SUB,


JMP)

• Each assembly instruction corresponds to one machine instruction

• Example- MOV AL, 61h(This means: Move the hexadecimal value 61 into
register AL.)

• Easier to understand and write than binary

• Good for hardware control and performance tuning

• Still very fast

• Still complex and hardware-dependent

• Programs are not portable (code for Intel CPU won’t work on ARM CPU)

• Must be translated into machine code using an assembler

High-Level Language (Third Generation Language)

• A language that is close to human language and abstract thinking


• Focuses on what to do, not how the hardware does it

• Common examples:

• Python

• C / C++

• Java

• JavaScript

• PHP

• Easy to learn and write

• Highly readable and maintainable

• Portable across different systems (e.g., same Python program runs on Windows
and Linux)

• Allows focus on solving problems rather than managing hardware

• Slower than machine/assembly (because it needs to be compiled or


interpreted)Less control over hardware behavior
Representation and Execution of Instructions: Operations and Operands

 An instruction is a command given to the computer’s CPU to perform a specific


operation (like add, move, compare).

 Instructions are the building blocks of programs.

Components of an Instruction

Each instruction typically includes two main parts:

1. Operation (Opcode):

• Tells the CPU what action to perform

• Example: ADD, MOV, SUB, LOAD

2. Operands:

• The data (or the address of the data) the operation is performed on

• Can be a register, memory address, or constant value

1. Introduction to Logical Operations

Logical operations are operations on binary values (0 and 1). They are fundamental to
decision making in digital systems and CPUs.
• Decision making

• Comparisons

• Control units

• Flags in ALU (Arithmetic Logic Unit)

➤ Role of Decision-Making:

• Decision-making allows the CPU to change the sequence of instructions based on


conditions (e.g., if-else).

➤ Comparators:

• Used in the ALU to compare two values:

• Equal to (==)

• Greater than (>)

• Less than (<)

➤ Conditional Execution:
Instructions may include:

BEQ (Branch if Equal)

BNE (Branch if Not Equal)

➤ Flowchart Logic Example:

• If A == B

• → Jump to Label1

• Else

• → Continue

➤ Example in Pseudocode:

if (A == B) {

goto LABEL1;

} else {

execute next instruction;

You might also like