0% found this document useful (0 votes)
82 views16 pages

CS 251 Introduction To Computer Organization & Assembly Language

This document provides an introduction to a course on computer organization and assembly language. It discusses the main hardware components of a computer including the CPU, main memory, secondary storage, I/O devices, and how they interact. It also introduces assembly language, how it compares to machine language and high-level languages, and some advantages of each. The course will cover computer organization concepts from Tanenbaum's textbook and assembly language programming using Yu and Marut's textbook.

Uploaded by

idrissalma
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
82 views16 pages

CS 251 Introduction To Computer Organization & Assembly Language

This document provides an introduction to a course on computer organization and assembly language. It discusses the main hardware components of a computer including the CPU, main memory, secondary storage, I/O devices, and how they interact. It also introduces assembly language, how it compares to machine language and high-level languages, and some advantages of each. The course will cover computer organization concepts from Tanenbaum's textbook and assembly language programming using Yu and Marut's textbook.

Uploaded by

idrissalma
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 16

Riyadh Philanthropic Society For Science

Prince Sultan College For Woman


Dept. of Computer & Information Sciences

CS 251
Introduction to Computer Organization &
Assembly Language
Lecture 1
(Course Introduction)
Part I: Computer Organization
• Main hardware components and their relation to the software.
• What the computer does when it executes an instruction.

Course Introduction - Part I: Computer Organization


Part I: Topics to be covered
• Introduction to computer organization
•           Languages, levels, and virtual machines
•           Contemporary multilevel machines
• Processors
• Primary memory
• Secondary memory
•           Memory hierarchies
•           RAID
•           Brief overview of secondary devices
•  Input/output
•           Buses
•           DMA
•           Interrupts
•           Reading and writing operations
Course Introduction - Part I: Computer Organization
Basic Computer Components
Main Memory

Secondary
storage Central Processing Unit
e.g. Hard disk (CPU)
Arithmetic Control Unit Registers
Logic Unit

Input Input-Output Processor Output


Devices (IOP) Devices

Computer Organization 3
The CPU
• Its the brain of the computer.
Main
Memory
• Its function is to execute programs stored in the
main memory by fetching their instructions,
examining them, and then executing them one
CPU after the other.
Registers
Control
ALU

Unit

I-D (IOP) O-D

Computer Organization 4
The CPU (Continue)
• The CPU has three components:
Main
Memory
• ALU (Arithmetic & Logic Unit) for
manipulating data.
• Control Unit A control unit directs the flow of
CPU information. Think of it like a "traffic guard" if you may-
directing traffic so the vehicles go to their destination
Register
Contro

quickly and safely. This is more or less what a control unit


ALU

Unit

does, it controls where every bit of data goes.


s

• Registers
• Small (all of the same size), high speed
I-D (IOP) O-D memory used to store temporary results
& certain control information.

• Each register can hold one number.

Computer Organization 5
The CPU (Continue)
• The CPU components are connected by a bus.
Main
Memory
• Bus = collection of parallel wires for
transmitting addresses, data, and control
signals.
CPU
Register

• Busses can be:


Contro
l Unit
ALU

• External to the CPU, connecting to the memory


s

& I/O devices.

• Internal to the CPU.


I-D (IOP) O-D

Computer Organization 6
The Main Memory or Primary Memory

Main • Its a storage unit for instructions and data.


Memory
• It stores data temporary
• All programs which are running will be in Main Memory

CPU • faster then secondary storage


Register
Contro
l Unit
ALU

I-D (IOP) O-D

Computer Organization 7
The Secondary Memory or Secondary Storage

• It stores data and information

• For example, Hard disk

• It stores data permanently

• When programs are downloaded or installed they are stored in secondary

storage for example hard disk.

• Slow in working

• Have high capacity to store data

Computer Organization 7
The IOP
• It contains electronic circuits for
Main
Memory communicating and controlling the transfer of
information between the CPU and the outside
world.

CPU
Register
Contro
l Unit
ALU

I-D (IOP) O-D

Computer Organization 8
The I/O Devices
• Examples:
Main
Memory
• Keyboards

• Printers
CPU
• Monitor
Register
Contro
l Unit
ALU

I-D (IOP) O-D

Computer Organization 9
Part II: Introduction to Assembly Language
Computer languages

Machine Language Assembly Language High-Level Language


Collection of binary Symbolic form of machine Combines algebraic
numbers language (I.e. symbolic expressions & symbols taken
names are used to represent from English language
operations, registers & (ex. Pascal, COBOL
memory locations FORTRAN, …etc)

Ex. Ex. Ex.


10100001 00000000 00000000 MOV AX,A A=A+4
00000101 00000100 00000000 ADD AX,4
10100011 00000000 00000000 MOV A,AX

Course Introduction - Part II: Assembly Language


Computer languages (Continue)

Machine Language Assembly Language High-Level Language


Directly understood by aAssembler Compiler (or interpreter)
computer converts to machine converts to machine
language language

1 assembly language 1 HLL instruction = many


instruction = 1 machine machine language
language instruction instructions

Not standard (I.e. different Not standard (I.e. different Standard (I.e. programs are
machine language for assembly language for independent of the machine
every type of machine every type of machine) on which they will be
executed)

Course Introduction - Part II: Assembly Language


Advantages of High-Level Languages
• It is easier to convert a natural language algorithm to a HLL
program.
• It is easier to read & understand HLL program than ASM program.
• HLL program generally contains less instructions than equivalent
ASM programs less time is required to code the HLL program.
• HLL program can be executed on any machine that has a compiler
for that language ASM program is limited to one type of
machine.

Course Introduction - Part II: Assembly Language


Advantages of Assembly Language
• Performance:
• A well-written Assembly language program produces a faster,
shorter machine language program.
For Some applications speed and size is critical
• Access to hardware:
• Some operations, such as reading or writing to specific memory
locations & I/O ports can be done easily in Assembly but may
be impossible by a higher level language.

• Studying ASM language gain a feeling of the way the computer


thinks and the way things happen inside the computer.

Course Introduction - Part II: Assembly Language


We will start from Part I Introduction
to Computer Organization
Part I: Structured Computer Organization, 5th
edition, Andrew S. Tanenbaum
Part II:
Ytha Yu and Charles Marut (1992).
Assembly Language Programming and
Organization of the IBM PC, International
edition, McGraw-Hill publishing company.

You might also like