0% found this document useful (0 votes)
14 views74 pages

How Does A Computer Works?

What is computer? History of computer. How does a Personal computer works? How does a cpu works?

Uploaded by

muntasirshuvo17
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)
14 views74 pages

How Does A Computer Works?

What is computer? History of computer. How does a Personal computer works? How does a cpu works?

Uploaded by

muntasirshuvo17
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

Lecture 2

How do Computers work


Outline
● Chapter 1: What is Computer
● Chapter 2: History of Computers
● Chapter 3: How does a Personal Computer Work
● Chapter 4: How does the CPU work
Chapter 1: What is Computer
1.1 Different types of Computer based on different criteria
1.2 Benefits of using a Computer
1.3 Application of a computer in different domains
● A computer is a programmable electronic device that accepts
raw data as input and processes it with a set of instructions (a
program) to produce the result as output.

● It not only processes both numerical and non-numerical


calculations but also saves the output for future reference.

● The term "computer" originates from the Latin word


"computare," meaning to calculate.

● The Analytical Engine, invented by Charles Babbage in 1837,


Figure: A desktop computer
was the first computer, utilizing punch cards as read-only
memory.
Digital Computers operate “digitally”, using binary code (0s and 1s) for instructions and data
representation. A computer fundamentally operates through four key functions.

● Handling raw data fed into the


01 Input Operation
system

● Storing data for processing and


02 Storage Operation
future retrieval

● Executing program instructions


03 Data Processing
to manipulate data

● Displaying or exporting the


04 Output Operation
processed data
The basic parts without which a computer cannot work as follows:

● Processor: It executes instructions from software and hardware.

● Memory: It is the primary memory for data transfer between the CPU and storage.

● Motherboard: It is the part that connects all other parts or components of a computer.

● Storage Device: It permanently stores the data, e.g., hard drive.

● Input Device: It allows you to communicate with the computer or to input data, e.g., a keyboard.

● Output Device: It enables you to see the output, e.g., monitor.


Memory
Processor Motherboard
(RAM)

Input Output Storage


Devices Devices Devices
Chapter 1: What is Computer
1.1 Different types of Computer based on different criteria
1.2 Benefits of using a Computer
1.3 Application of a computer in different domains
Supercomputer Enterprise Level Computing for
Personal Computer
(Summit, Oak Ridge National Large Business
(Desktop)
Laboratory (USA)) (Microsoft Server)
Table: Specifications of Supercomputers

Tianhe-2 (National
Summit (Oak Ridge National Fugaku (RIKEN and Fujitsu,
Name of the Supercomputer Supercomputer Center in
Laboratory, USA) Japan)
Guangzhou, China)

Processing Power (*FLOPS) 200 petaflops 442 petaflops 33.86 petaflops

**Nodes 4608 158,976 16,000

512GB DDR4 + 96GB High


Memory/**node 32GB HBM2 88GB
Bandwidth Memory (HBM2)

Research on masks related to the


Artificial Intelligence, Human COVID-19 pandemic, Government Security
Health Research, Earthquake Developing Generative AI Applications, Studying
Purpose
Simulation, Materials Science Models, Drug Discovery, Combustion and Magnetism, and
and Nuclear Research Weather Forecasting, and Aerodynamics Simulations.
Simulating Natural Disasters.

* FLOPS (Floating Point Operations Per Second) is a measure of a computer's processing speed, indicating the number of floating-point calculations it can perform
in one second. FLOPS is a metric more commonly associated with specialized computing hardware like GPUs (Graphics Processing Units) or accelerators used in
supercomputers.

** In the context of supercomputers, a "node" typically refers to a single computing unit within the larger supercomputer system. Each node is a self-contained unit
that contains one or more processors (CPUs or accelerators), memory, storage, and other necessary components.
Applications of Supercomputers
● Molecular Modeling: Simulation of molecular structures for drug discovery and materials science.
● Weather and Climate Modeling: Enabling high-resolution weather forecasts, climate modeling, and the simulation of natural
disasters, aiding in disaster preparedness
● Aerospace and Aerodynamics: Designing and optimizing aircraft, simulating fluid dynamics, and improving aerodynamic
performance.
● Biomedical Research: genomics research, protein folding simulations, and drug discovery by analyzing vast biological
datasets.
● Financial Modeling: risk analysis, algorithmic trading, and complex financial simulations for investment strategies.
● National Security: cryptography, code-breaking, and simulating scenarios for defense and strategic planning.
● Earth Science and Environmental Studies: Modeling geological processes, studying ocean currents, and monitoring
environmental changes on a global scale.
● Large-Scale Simulations: Simulating the behavior of complex systems such as nuclear simulation traffic flow, city planning,
and population dynamics.
Table: Specifications of Enterprise level computing in Large Business Organizations

Specification Detail

Processor Intel Xeon Scalable Processor (Up to 2)

Processing Power (FLOPS) 48 teraflops

Memory Up to 192GB of RAM

Purpose ERP, CRM, Data Analytics, Virtualization, Database


Management, Collaboration tools, Network
Infrastructure.
Azure
Cloud
Services
(Microsoft)
Large businesses are relying on
services, such as Azure Cloud Services
from Microsoft and Google Cloud Large
Platform (GCP) from Google to manage Business
their operations, process vast Organisations
amounts of data, and provide services
at scale.
Google
Cloud
Platform
(GCP)
Table: Specifications of Personal Computers

Laptop Desktop
Personal Computers
(MacBook Air) (Content Creation PC)

Processor Apple M1 AMD Ryzen 9 5900X

Memory 8GB 32GB

Web Browsing, Email, Word


Video Editing and 3D
Purpose Processing, and Light Content
rendering
Creation
Chapter 1: What is Computer
1.1 Different types of Computer based on different criteria
1.2 Benefits of using a Computer
1.3 Application of a computer in different domains
Benefits of using a Computer

● Increases your productivity: A computer increases your productivity. For example, after having a basic
understanding of a word processor, you can create, edit, store, and print the documents easily and quickly.
● Connects to the Internet: It connects you to the internet that allows you to send emails, browse content, gain
information, use social media platforms, and more. By connecting to the internet, you can also connect to your
long-distance friends and family members.
● Organized Data and Information: It not only allows you to store data but also enables you to organize your data.
For example, you can create different folders to store different data and information and thus can search for
information easily and quickly.
● Assist the physically challenged: It can be used to help the physically challenged, e.g., Stephen Hawking, who
was not able to speak using a computer to speak. It also can be used to help blind people by installing special
software to read what is on the screen.
Chapter 1: What is Computer
1.1 Different types of Computer based on different criteria
1.2 Benefits of using a Computer
1.3 Application of a computer in different domains
Application of a Computer in Different Domains

● Healthcare: Electronic Health Records (EHR) systems for storing and managing patient data, medical imaging systems like
MRI and CT scans for diagnostics, and computer-assisted surgery systems for precision in surgical procedures.
● Business and Finance: Financial modeling using spreadsheet software, online banking systems for transactions, Enterprise
Resource Planning (ERP) systems for managing business processes, and algorithmic trading in financial markets.
● Entertainment: Video games, streaming services like Netflix and Hulu, digital music platforms like Spotify, and computer-
generated imagery (CGI) in movies for special effects.
● Transportation: Traffic control systems, GPS navigation for vehicles, and airline reservation systems for managing flights
and bookings.
● Agriculture: Precision farming using computerized systems for monitoring and controlling crop growth, automated
machinery for planting and harvesting, and computer simulations for optimizing crop yield.
● Manufacturing: Computer-aided design (CAD) and computer-aided manufacturing (CAM) systems for product design and
production, automation in factories using programmable logic controllers (PLCs), and inventory management systems.
Chapter 2: History of Computer
2.1 Analog to Digital
2.2 Generations of Computers
Antikythera
Mechanism

● Ancient Greek device from the 1st century BCE.


● Regarded as one of the earliest analog computers.
● Unearthed in 1901.
● Was used to predict celestial events and eclipses.
● Calculations based on the positions of the sun, moon,
and planets.
● Utilized a system of gears and rotating dials.
● Demonstrated advanced mechanical engineering and
astronomical knowledge. Figure: Antikythera Mechanism
Astrolabe

● Originated in ancient Greece; refined by Islamic


scholars.
● A portable analog astronomical instrument.
● Used for calculating time and positions of celestial
objects.
● Assisted astronomers and navigators in various
calculations.
● Included a rotating disk and alidade.
● Equipped with various scales for measurement. Figure: Astrolabe

● Employed a manual analog method for complex


mathematical problem-solving.
ENIAC

● Developed in the 1940s.


● Among the first general-purpose electronic digital
computers.
● Operated using vacuum tubes for calculations.
● Utilized mainly for scientific and military purposes.
● Represented a significant shift from analog to digital
computing.
Figure: ENIAC
IBM 360

● Launched in the 1960s.


● Represented a significant step forward in digital
computing technology.
● Mainframe computers designed for compatibility
across different models in the series.
● Key to advancements in business, government, and
scientific research.

Figure: IBM 360


Modern Personal
Computer

● Marked by significant advancements in processing


power, storage, and graphics.
● Introduction and standardization of dual-core and
Figure: Laptop (MacBook) from 2006
multicore processors.
● Widespread adoption of high-speed internet.
● Facilitated growth in online services, social media, and
e-commerce.
● Increase in prevalence of laptops.
● Contributed to greater mobility in computing.
● Development of more immersive graphics.

Figure: Desktop Computer from early 2000s


Quantum
Computer

● Unlike classical computers using bits (0 or 1), quantum


computers use qubits.
● Qubits can exist in multiple states at once due to
superposition.
● Ability to perform certain calculations significantly
faster than classical computers.
● Revolutionize cryptography and enhance security.
● Solve complex optimization problems more efficiently.
Figure: Quantum Computer
Chapter 2: History of Computer
2.1 Analog to Digital
2.2 Generations of Computers
5th Generation
Ultra-large scale integration (ULSI)
3rd Generation technology. Microprocessor chips
with millions of electronic
1st Generation Adoption of integrated circuits components. Focus on parallel
(ICs). Enhanced computing power processing hardware and AI
Introduction of electronic circuits, with reduced size and cost. Rise of software. Utilization of languages
replacing mechanical components. high-level programming languages. like Java, .Net. Popular devices
Vacuum tubes used for CPU and Advancements in operating include desktops, laptops,
memory. Use of batch operating systems, including time-sharing and notebooks, ultrabooks, and
systems and punch cards. multi-programming. chromebooks.
1959 1971

1946 1965 1980


2nd Generation 4th Generation
Transition to transistor-based Introduction of very large scale
computers. Faster, more compact, integrated (VLSI) circuits. Further
and energy-efficient designs. miniaturization and affordability of
computers. Real-time, time-sharing,
Magnetic cores for primary
and distributed operating systems.
memory; magnetic discs and tapes Popularity of programming
for secondary storage. Emergence languages like C and C++.
of programming languages like
COBOL and FORTRAN.
Development of batch processing
and multiprogramming operating
systems.
Chapter 3: How does a Personal
Computer Work
3.1 Core PC Components
3.2 Powering up a PC
3.3 PC Operating System
PC Case

● A box-like structure with lights, vents, and cable ports.


● Varies in size from small tabletop units to tall towers.
● Larger case size does not necessarily mean more
power.
● Internal components determine the computer's
capability.
● Selection or design of case based on compatibility with
the motherboard type.
Figure: Different sizes of cases of PC
Motherboard

● Central circuit board in a PC.


● Connects all internal and external components.
● Most components are removable and replaceable
without changing the motherboard.
● Complementary Metal-Oxide Semiconductor (CMOS)
stores system information like the clock when the PC
is off.
Figure: A Motherboard
● Common sizes include ATX and MicroATX.
● Larger size with more space for ports and expansion
slots.
Power Supply

● Essential for powering all PC components except the


CMOS.
● Mounted inside the case.
● Features an external power cable connection.
● Some cables connect directly to the motherboard.
● Others link to various components like GPU, drives
and fans.

Figure: A Power Supply


CPU

● Contains the microprocessor, the heart of a PC's


operations.
● Performance of both hardware and software depends
on the CPU.
● Commonly 32-bit or 64-bit.
● Software compatibility often depends on the
architecture. Figure: Central Processing Unit (CPU)

● Typically feature four or more cores.


● Enables efficient multitasking and handling of multiple
tasks simultaneously.
RAM

● Acts as a buffer for storing information during


processing.
● A fast CPU and sufficient RAM are both crucial for a
PC's speed.
● Each PC has a maximum RAM capacity it can support.
● Motherboard slots indicate the specific type of RAM
required. Figure: Random Access Memory (RAM)

● DDR-4 is currently supported by most motherboards.


● Transition to the newer, faster DDR-5 standard is
underway in some systems.
Drives

● Stores data when not actively in use.


● Hard drives (HDD) and solid-state drives (SSD) for
storing operating systems and software.
● Optical drives for reading/writing CDs, DVDs, and Blu-
Figure: Optical Drive (top left), Hard Disk Drive (HDD) (top right),
ray discs.
and Solid State Drive (SSD) (bottom)
● Depends on the drive controller technology: older IDE
or newer SATA standard.
● NVME SSDs get connected via M.2 connector pins
directly to the motherboard.

Figure: SATA (left) and IDE (right)


Cooling Devices

● Increased processing leads to higher heat production.


● CPU and components have a heat tolerance limit.
● Overheating can cause damage to components and
circuitry.
● Fans are the most widely used method for cooling a
PC.
● A metallic block called a heat sink is used to draw heat
away from the CPU.
● High-performance users (like gamers) may use more
advanced cooling solutions, such as water-cooled
systems. Figure: Cooling Devices (Top: Air Cooling; Bottom: Water Cooling)
Graphics Components

● Some motherboards have integrated graphics.


● Others have an expansion slot for an external video
card or GPU.
● GPUs process complex graphics data for the screen.
● Reduce the processing load on the CPU.
● Accepts video cards based on specific interfaces (e.g.,
AGP, PCI).
● Equipped with dedicated video RAM. Figure: Accelerated Graphics Port (AGP) and Peripheral
Component Interconnect (PCI)
● Include additional cooling fans for high performance.
Ports (USB Ports)

● Universal Serial Bus (USB) standard for data transfer. Figure: Ports are places on the outside of the PC where
● Connects computers to various devices. users can plug in cables

● Cable design: four-wired, shielded with two for


power/ground and two for data.
● Automatic device detection through voltage change
on data wires.

Figure: USB cable


Ports (Network Ports)

● Ethernet is used for connecting to wired network


Figure: Ethernet Port
systems.
● Facilitates internet and local network connections.

Figure: Ethernet Cable


Ports (Video Ports)
● Video Graphics Array (VGA): Supports 640 × 480
resolution, up to 60Hz, and 16 colors. Can display 256
colors at 200 × 320 resolution. Analog technology,
becoming outdated.
● High Definition Multimedia Interface (HDMI):
Transmits high-definition audio and visual signals. Figure: VGA Port (top), DisplayPort (bottom left) and
HDMI (bottom right)
Supports widescreen format, higher pixel counts
(1920×1080), faster refresh rates, and extensive color
range. Bandwidth up to 10 gigabits per second.
● DisplayPort: Similar to HDMI, used for digital audio
and video output.
Figure: HDMI Cable (left) and VGA Cable (right)
Audio Ports

● Mini analog audio jacks or optical audio ports.


● HDMI and DisplayPort also transmit digital audio.

Figure: 3.5mm analog audio jack


Legacy Ports

● Rarely used in modern PCs.


● Include parallel printer ports and Personal System Figure: Parallel Printer Port

(PS)/2 ports for keyboard and mouse.

Figure: PS/2 Port


Peripherals

● Any hardware not mounted inside a PC's case.


● Connects to a PC externally.
● Integral for user interaction with the PC.
● Plugged into various ports on the PC.
● Monitors, keyboards, mice, printers, speakers,
headphones, microphones, webcams, USB flash drives.
etc.

Figure: Different types of peripherals


Expansion Slots

● Allow addition of components without designated


motherboard slots.
● Enhance PC capabilities beyond base configuration.
● Removable components fitting into expansion slots.
● Enable adding extra video cards, network cards,
printer ports, TV receivers, etc.
● Must match the specific type of expansion slot.
Figure: Expansion Slots
● Types include legacy ISA/EISA, common PCI, PCI-X,
PCI Express, and the newer M.2 standard.
Chapter 3: How does a Personal
Computer Work
3.1 Core PC Components
3.2 Powering up a PC
3.3 PC Operating System
Boot Process Overview
● Also known as booting the PC.
● "Boot" is short for "bootstrap," indicating starting from the beginning.
● Controlled by the PC's basic input-output system (BIOS).

BIOS: Fundamental Software


● Stored on a flash memory chip on the motherboard.
● Occasionally updated by the PC manufacturer.
● "Flashing the BIOS" involves updating with new software.
BIOS Functions
● Controls the boot process.
● Provides basic configuration interface for hardware components.
● Allows configuration of drive read order during boot and processor speed.

Accessing BIOS Interface


● Detailed in PC's documentation.
● Often indicated during boot-up (e.g., "Press DEL to enter Setup Menu").
Boot Process Steps

● Activation of Power Supply:


i. Power button triggers the power supply to energize the motherboard and
components.
● Power-On Self-Test (POST):
i. Initial program in BIOS checking for hardware issues.
ii. Single beep indicates all is well; other sequences signal hardware failures.
● Boot Process Display:
i. Shows BIOS manufacturer, processor specs, RAM amount, and detected drives.
ii. Some PCs display a manufacturer's logo splash screen instead.
iii. Option to disable splash screen in BIOS settings.
Boot Process Steps (Continued)

● Accessing Boot Disk:


i. BIOS seeks the first sector of the designated boot disk (hard disk or SSD with OS).
ii. Boot disk order can be changed in BIOS settings or with a key sequence during boot.
● Bootstrap Loader Check and Load:
i. BIOS checks for a bootstrap loader in the first sector.
ii. Loads the boot loader into RAM.
● Handover to Boot Loader:
i. BIOS transfers control to the boot loader.
ii. Boot loader begins loading the operating system into memory.
● Operating System Initialization:
i. Boot loader hands over control to the OS.
ii. The operating system becomes ready for user interaction.
Chapter 3: How does a Personal
Computer Work
3.1 Core PC Components
3.2 Powering up a PC
3.3 PC Operating System
Operating System

● Post-boot, PCs are controlled through an operating


system (OS).
● These OSs are adaptable to a variety of PC hardware
configurations.
● Most run either a version of Microsoft Windows or a
Linux distribution.
● Mac OS X is specifically designed for Apple hardware.
Figure: Laptop running on Windows 10 and Windows 11
Operating System Responsibilities
● Breaks down and prioritizes tasks before
01 Processor Management sending them to the CPU.
● Ensures efficient processor workload
handling.

● Manages data flow in and out of RAM.


02 Memory Management ● Utilizes virtual memory on hard disk
when RAM is insufficient.

● Offers software interface for internal


components and connected devices.
03 Device Management ● Handles input from keyboards/mice and adjusts
graphics for screen resolution.
● Manages network interfaces, including internet
connections.
Operating System Responsibilities
● Directs permanent data storage on various
04 Storage Management devices (HDDs, SSDs, USB drives).
● Facilitates creating, reading, editing, moving,
copying, and deleting documents.

● Enables data exchange between software programs


05 Application Interface and the PC.
● Requires applications to be compatible with the
operating system version.

● Provides a platform for user interaction with the


computer.
06 User Interface (UI) ● Includes graphical user interface (GUI) using icons
or audio instead of text.
● Initially popularized by Apple, now a standard in all
operating systems.
Chapter 4: How does the CPU work
4.1 Von Neumann Architecture
4.2 Components of the processor
4.3 System buses
4.4 Fetch-Execute Cycle
Von Neumann
Architecture
● Early computers were incapable of storing programs
or data.
● John von Neumann developed the concept of the
stored program computer in the mid-1940s.
● Laid the foundation for modern computer
architecture.

Von Neumann Architecture Features:

● Introduction of a central processing unit (CPU or


processor).
● Enabled direct memory access by the processor.
● Computer memory capable of storing both programs Figure: John von Neumann
and data. (Mathematician, Physicist, Computer Scientist, Engineer and Polymath)
● Concept of stored programs composed of sequentially
executed instructions.
Figure: Simple representation of Von Neumann Architecture
Chapter 4: How does the CPU work
4.1 Von Neumann Architecture
4.2 Components of the processor
4.3 System buses
4.4 Fetch-Execute Cycle
Components of the Processor (CPU)

Arithmetic
Logic Unit
(ALU)
Arithmetic Logic Unit (ALU)

● Arithmetic Logic Unit (ALU) performs arithmetic and logic operations during program run.
● Possibility of having more than one ALU for different operations.
● Separate ALUs for fixed point and floating-point operations.
● Executed through a series of addition, subtraction, and shifting operations.
● Example: Left/right shifting bits to emulate multiplication or division.
● A temporary register in the ALU is utilized for storing intermediate results during ALU calculations.
Control Unit (CU)

● Control Unit (CU) reads instructions from memory.


● Utilizes the program counter (PC) to locate instruction addresses.
● CU interprets the fetched instruction.
● Generates signals transmitted along the control bus.
● Signals instruct and coordinate actions of computer components.
● Ensures synchronized data flow and execution of program instructions.
● Central to maintaining order and efficiency in computer operations.
System Clock

● Produces timing signals on the control bus.


● Essential for synchronization of computer operations.
● Ensures coordinated functioning of different computer components.
● Prevents operational conflicts and errors.
● Without a system clock, it can lead to system crashes and malfunction.
Immediate Access Store (IAS)

● Stores data and programs for quick CPU access.


● Also known as primary memory or RAM.
● CPU moves data from secondary storage (like hard disks) to IAS.
● Temporary storage to enhance speed and efficiency.
● Read/write operations in IAS are significantly faster than in secondary storage.
● Key data for applications is stored temporarily in IAS.
● Facilitates faster processing and improved application response.
Registers

● Fundamental to the Von Neumann architecture.


● Serve as quick-access data storage locations within the CPU.
● General Purpose Registers: Hold frequently used data for the CPU.
● Special Purpose Registers: Used for specific functions within the CPU.
● Can be utilized directly by programmers for CPU addressing.
● Significantly faster than other memory forms like RAM.
● Accelerate data processing by providing rapid access to essential data.
Chapter 4: How does the CPU work
4.1 Von Neumann Architecture
4.2 Components of the processor
4.3 System buses
4.4 Fetch-Execute Cycle
Buses are used in computers as a parallel transmission component; each wire in the bus transmits one bit of data.
There are three common buses used in the Von Neumann architecture known as address bus, data bus and control bus.

Figure: System buses


Address Bus
● Transports memory addresses throughout the
computer system.
● In CPU-memory communication, address bus is
unidirectional. Prevents addresses from being sent
back to the CPU.
● Determines the number of memory locations
addressable at once.
● Wider bus means more memory locations can be
addressed. Bus width directly affects the system's
addressing capability.
● 16-bit bus: Addresses up to 2^16 (65,536) memory
locations. Figure: System buses
● 32-bit bus: Addresses up to 2^32 (4,294,967,296)
memory locations.
● Technology for wider buses exists but is more
complex.
Data Bus
● Bidirectional, allowing data flow in both directions.
● Facilitates data movement between CPU, memory,
and input/output devices.
● Can transport addresses, instructions, or numerical
values.
● The wider the bus, the larger the word length that can
be transported. (A word is a group of bits which can be
regarded as a single unit
● Common word lengths: 16-bit, 32-bit, 64-bit.
Figure: System buses
● Wider data buses with larger word lengths enhance
overall performance.
Control Bus
● Bidirectional bus that carries signals from the Control
Unit (CU) to other computer components.
● Facilitates the distribution of control signals within the
computer system.
● Typically 8-bits wide, sufficient for transmitting
control signals.

Figure: System buses


System Clock (Revisited)

● Defines the clock cycle, synchronizing all computer operations.


● Integral for maintaining operational harmony within the computer.
● Transmits timing signals for synchronization.
● Higher clock speeds (e.g., 3.5GHz – which means 3.5 billion clock cycles a second) result in more clock cycles per
second.
● Directly increases the processing speed of the computer.
● Although a higher clock speed boosts processing speed, it does not always equate to improved overall computer
performance.
Other Performance Factors

● Width of the address bus and data bus can affect computer performance.
Increasing bus width (data and address buses) increases the performance and
speed of a computer system.
● Increasing clock speed usually increases the speed of a computer. However,
using a clock speed higher than the computer (Overclocking) was designed
for can lead to problems.
● Use of cache memories can also speed up a processor’s performance.
● Use of multi-core CPUs. However, Dual-core and quad-core configurations
Figure: Two cores, one channel (left)
have different communication channels and overheads. and four core, six channels (right)
● Doubling the number of cores does not necessarily double the computer’s
performance.
Chapter 4: How does the CPU work
4.1 Von Neumann Architecture
4.2 Components of the processor
4.3 System buses
4.4 Fetch-Execute Cycle
Fetch-Execute Cycle

● Address and data buses are employed to fetch data and instructions.
● Data and instructions fetched from memory are stored in registers.

Fetch Phase:

● CPU retrieves the instruction from memory indicated by the program counter (PC).
● PC is incremented to point to the subsequent instruction.

Execution Phase:

● CPU interprets and executes the fetched instruction.


● May involve additional data fetching, calculations, or modifying program flow.

Continuation of the Cycle:

● The fetch-execute cycle repeats continuously.


● Enables the CPU to process a sequence of instructions in a program.
Fetch-Execute Cycle (Analogy)

Imagine a librarian (CPU) in a large library (memory) organizing and processing a list of tasks
(instructions). The librarian has a notebook with a list of tasks to be performed, and there's a
pointer indicating the current task. This pointer corresponds to the program counter. In the fetch
phase, the librarian reads the next task from the notebook, and in the execute phase, they perform
the task—whether it's finding a specific book on a shelf, making a note in a register, or performing a
calculation. The librarian then moves on to the next task, and this process continues until all tasks
are completed. In this way, the librarian efficiently manages and executes a set of instructions just
like a CPU does with machine language instructions in a computer.
Thank you
References
[1] Computer Science - Cambridge International AS & A Level
[2] [Link]
[3] [Link]
[4] [Link]
[5] [Link]

Note: Some texts have been generated using LLMs and reviewed by instructors.

You might also like