Marks Distribution?Mid1: 15%?Mid2: 15%?Class activities+ Assignment+Projects: 20%?Final: 50%?Book:Opertaing System Concepts byAbraham Silberschatz 10thEdition
What is an Operating System??A program that acts as an intermediarybetween a user of a computer and thecomputer hardware
Computer System Structure?Computer system can be divided intofour components:◦Hardware – provides basic computingresources◦Operating system◦Application programs◦Users
Four Components of a Computer System
Operating System Definition?OS is aresource allocator◦Manages all resources◦Decides between conflicting requests for efficientand fair resource use?OS is acontrol program◦Controls execution of programs to prevent errors andimproper use of the computer“The one program running at all times on thecomputer” is thekernel.
Computer Startup?bootstrap programis loaded at power-upor reboot◦Typically stored in ROM or EPROM, generallyknown asfirmware◦Initializes all aspects of system◦Loads operating system kernel and startsexecution
Computer System Organization?Computer-system operation◦One or more CPUs, device controllers connectthrough common bus providing access toshared memory◦Concurrent execution of CPUs and devicescompeting for memory cycles
Computer-System Operation?I/O devices and the CPU can execute concurrently?Each device controller is in charge of a particulardevice type?Each device controller has a local buffer?CPU moves data from/to main memory to/fromlocal buffers?I/O is from the device to local buffer of controller?Device controller informs CPU that it has finishedits operation by causing aninterrupt
Common Functions of Interrupts●Interrupt transfers control to the interruptservice routine generally, through theinterruptvector, which contains theaddresses of all the service routines●Interrupt architecture must save the addressof the interrupted instruction●Atraporexceptionis a software-generated interrupt caused either by anerror or a user request●An operating system isinterrupt driven
Interrupt Handling?The operating system preserves the state ofthe CPU by storing registers and the programcounter?Determines which type of interrupt hasoccurred:◦polling◦vectoredinterrupt system?