CSE321 - 1. Introduction & Operating-System
CSE321 - 1. Introduction & Operating-System
Structures
● Narzu Tarannum
<[email protected]
● Computer-System Organization
● Computer-System Architecture
● Operating-System Structure
● Operating-System Operations
● Storage Structure
● System call
● Kernel – the one program running at all times (all else being application
programs).
● The kernel is the central module of an operating system (OS). It is
the part of the operating system that loads first, and it remains in
main memory. The kernel code is usually loaded into a protected
area of memory to prevent it from being overwritten by programs or
other parts of the operating system.
● Processes-management
● Storage-memory management
● Data-file management
● Input/output devices-i/o management
● Network management
● Protection& security
● Multi-programmed Batched Systems: Several jobs are kept in main memory at the
same time, and the CPU is multiplexed among them.
● Loosely coupled system – each processor has its own local memory; processors
communicate with one another through various communications lines, such as
high-speed buses or telephone lines.
Computer
CPU
Input OS Output
User program
Memory
Advantages-
● It saves the time that was being wasted earlier for each individual process in context switching from
one environment to another environment.
● The output is obtained only after all the jobs are executed.
● Thus,Concepts
Operating System priority can not be implemented if a certain
1.18 job has to be executed on anSilberschatz,
urgent basis.Galvin and Gagne ©2005
Limitations of Simple Batch Systems
● Not interactive
● Memory is limited
● CPU utilization is poor
● Speed mismatch between I/O device and
CPU
● Multiprogramming means more than one process in main memory which are ready to
execute.
● Single user cannot keep CPU and I/O devices busy at all times
● Multiprogramming organizes jobs (code and data) so CPU always has one to execute
● A subset of total jobs in system is kept in memory
● Process generally require CPU time and I/O time, when CPU has to wait (for I/O
for example), OS switches to another job and this idea will continue.
● The operating system is able to keep track of where you are in these tasks and go from
one to the other without losing information.
● Two Types:
● Symmetric Multiprocessing(SMP):
❑ Each processor runs an identical copy of the
operating system.
❑ Most modern operating systems support SMP.
● Asymmetric Multiprocessing:
❑ Each processor is assigned a specific task;
master processor schedules and allocates work
to slave processors
Master CPU
CPU 1 OS
P1
CPU 2 Slave CPU 1 Slave CPU 2 Slave CPU 3
P2
CPU 3 P3
P1 P2 P3
● One set of operating-system services provides functions that are helpful to the user
(Cont.):
● Another set of OS functions exists for ensuring the efficient operation of the
system itself via resource sharing
● Accounting - To keep track of which users use how much and what kinds of
computer resources
❖ Note that the system-call names used throughout this text are generic
● System call sequence to copy the contents of one file to another file
● The system call interface invokes the intended system call in OS kernel and
returns status of the system call and any return values
● The caller need know nothing about how the system call is implemented