Topic C Flashcards
What is multiprogramming?
- Loading several programs into memory simultaneously, all sharing a single CPU
- when the running program can’t continue (waiting for I/O) switch to another program
What is Multi-Access Time Sharing?
Each program has time slices. The program will run for a specified amount of time that’s dictated by the operating system then switch into waiting after it’s time slice is up
How long are time slices?
milliseconds long
what does the CPU switching rapidly between processes do?
It gives the illusion of uninterrupted execution in parallel
- makes it seem like multiple programs are running at once
What is the idea of a time slice?
the OS will split process time into a fixed quantum. At the end of a time slice the CPU sends an interrupt to the OS which puts a bit of its own OS code onto the CPU this code swaps out the running process and puts a new process onto the CPU, sets up the instruction pointer to wherever it needs to go and that program runs on the CPU
What is an interrupt
an automatic call of a sequence of instructions to deal with an event occurring outside normal program execution
what is the ISR
The sequence of instructions stored in that reserved area of memory
What is the interrupt service routine also known as?
the interrupt routine or interrupt handler
How do we protect the register values of the program that was running when an interrupt happened?
- we save them all in the process control block
- this is a table of descriptors one for each process maintained by the OS
What happens during a context switch?
The state of the current program gets stored in its process control block.
What is the difference between programs and processes
- A program is a static thing that the programmer writes, it could be source code or object code
- the process is the running version of a program
- A single program can have multiple processes
What does an OS structure consist of?
- A central kernel
- A set of processes
- system calls
What does the kernel do?
performs low level, frequently needed activity. Performs 4 processes in particular that help to keep the computer under control
What does the system calls do?
allows a particular process wants to spawn another process to do something.
What is the bootstrap program
it reads from the OS from disk and puts it into memory. It loads the IP and points it to the first instruction of the OS itself