1.2 Systems Software Flashcards
Need for OS (1.2.1A), Paging, Segmentation and Virtual Memory (1.2.1B), Interrupts (1.2.1C), Scheduling (1.2.1D), Types of OS (1.2.1E), BIOS (1.2.1F), Device Drivers (1.2.1G), Virtual Machines (1.2.1H), The Nature of Application (1.2.2A), Utilities (1.2.2B), Open vs Closed (1.2.2C), Translators (1.2.2D), Stages of Compilation (1.2.2E), Linkers, Loaders and Libraries (1.2.2F), Development Methodologies (1.2.3A), Writing and following algorithms (1.2.3C)
What is meant by the term multitasking?
- When you have more than one program open and running at the same time
- The processor allocates a small amount of time to each process and cycles between them
What is file management?
- Data is stored in files
- An extension to the filename tells the OS which application to load the file into
- The OS may present a logical structure of files in folders and allow the user to rename, delete, copy and move files
What is user management?
- Allows multiple users to log into the same computer.
- The OS will retain settings for each user such as icons, desktop, backgrounds etc.
- Each user may have different access rights to files and programs
- A client-server network may impose a fixed or roaming profile for a user and manage login requests to the network
What are some UIs?
- WIMP: Windows, Icons, Menus and pointers
- Visual
- Interactive
- Intuitive
- Optimised for mouse and touch gesture input
What are the 2 methods of dividing memory into smaller sections?
- Paging
- Segmentation
Describe paging
- Pages are fixed size
- Pages are made to fit sections of memory
- Pages are physical divisions
- Programs are split to fit into a given number of pages
- Paging takes no account of how it splits the program, only that it splits it into fixed-sized pages
- It could separate the instructions inside a looping condition so they are in different pages, but that wouldn’t be efficient
Describe segmentation
- Segments are different sizes
- Segments are complete sections of programs
- Segments are logical divisions
What is Virtual memory?
- Using parts of the HDD to store programs that can’t be stored in primary memory
What is an interrupt?
- While the processor does the FDE cycle other devices and applications may require the processor’s attention.
- They need a way to signal to the processor that they require attention - this is what’s called an interrupt
What is the ISR?
- Interrupt Service Routine
- A program with a set of instructions that need to be fetched, decoded and executed to carry out the operations of the interrupt
- That means that the contents of the PC need to be changed to point to the address for the first instruction of the interrupt
What happens when an interrupt is received?
- The values held in the registers are copied into a data structure in memory known as the stack
- These values are pushed onto the stack in a stack frame, effectively saving them for later retrieval
- The interrupt can now be executed
- Once the interrupt is complete, we pop the frame off the top of the stack.
What does popping the frame of the stack allow us to do?
- Retrieve the previous values for the original program
- Load them back into the processor registers
- Carry on executing the original program where we left off
What happens when a high-priority interrupt comes along while an interrupt is being executed?
- The stack system handles it by:
- Suspending ISR A
- Pushes register contents onto the top of the stack
- Starts executing ISR B
- Once ISR B has completed executing, we pop the frame off the top of the stack to retrieve the value for ISR A, load them back into the processor registers and carry on executing ISR A
What are some examples of hardware interrupts?
- Power supply failure
- Power/reset button pressed
What are some examples of user interrupts?
- Moving the mouse
- Keyboard presses
What are some examples of software interrupts?
- Illegal instructions encountered
- Arithmetic overflow
- New log on request
What are some examples of timer interrupts?
- Screen recording application
- Data-logging program reading an input-sensor every second
What are some examples of I/O devices interrupts?
- Buffer nearly empty
- Printer ink supply notification
- Signal the completion of a data transfer to/from a device
What does a scheduler do?
- Manages which process to execute next
- Manages the length of time the next process can execute for
Explain the process of scheduling using Process A as an example
- Process A is a new process
- The number indicates the length of time before it finishes
- It enters the ready queue
- When the currently executing process finishes or is blocked or suspended, process A can move into a running state
- From here it will either:
- Finishing executing completely and leave the system
- Get blocked as it requires an input or output commands, meaning it can’t continue until more data is received
- Run out of time - each process is allocated a certain amount of time after which it is suspended and moved to the back of the ready queue
What is an FCFS algorithm?
- First come First Served
- Processes are executed in the order they arrive
- If a process takes a long time, the others behind it have to wait
What is a SJF algorithm?
- Shortest Job First
- Picks the processes that take the shortest amount of time and runs them until they finish
- The scheduler needs to know how long each process will take
What is a RR algorithm?
- Round Robin
- Each process is allocated a fixed amount of time, known as a time slice or quantum
- If the process isn’t complete by the end of its time slice, it returns to the back of the ready queue
What is a SRT algorithm?
- Shortest Remaining Time
- Similar to SJF
- Pre-emptive algorithm, meaning processes can be suspended if a higher priority process joins the queue
What is a MLFQ algorithm?
- Multi Level Feedback Queue
- This algorithm builds upon these standard algorithms with the following design principles:
- Separates processes into multiple ready queues based on their processing needs.
- Gives preference to processes with high I/O bursts
- I/O bound processes will sleep in a wait queue to give other processes CPU time
- This algorithm allows for processes to be shifted between queues
- If a process has too much CPU time, it will be moved to a lower priority queue
- If a process is I/O bound or an interactive process, it will be moved to a higher priority queue
- If a process is waiting too long in a low-priority queue, it will be moved to a higher priority queue
What are the 5 types of OS?
- Distributed
- Multi-User
- Real-Time
- Embedded
- Multi-tasking
What is a multi-tasking OS?
- An OS that handles many processes at the same time
What is a multi-user OS?
- An OS that allows more than one person to access a single computer at the same time
- The computer will manage the user’s various permissions and access rights when they log on
- Server operating system software will handle the requests of multiple people using different computers on a network at the same time
What is a distributed OS?
- An OS which can combine the processing power of multiple computers across a network for a single task
What happens in distributed computing?
- The operating system controls and coordinates system controls and coordinates the computers, presenting them to the user as if they were a single system
What are embedded OS?
- They run on dedicated hardware so they run with maximum efficiency, using low powered processor and very little memory
What is a real-time OS?
- An OS that executes processes within a known time frame
- Plenty of redundancy is built into these systems so they can handle sudden increases in input
- As such, processors in real-time OS rarely run at capacity
What is the BIOS responsible for?
- Responsible for loading the OS when the computer first turns on
- It first checks that the hardware it needs is connected and working using a POST
What is a bootloader used for?
- Used to load the OS kernel into memory
Where are BIOS settings stored and why?
- Stored in flash memory
- So that they can be changed and retained when the power if switched off
What is a device driver?
- Software that tells the OS how to communicate with a peripheral device
What does a device driver do?
- The device driver translates the OS’ instructions into a series of instructions that a specific piece of hardware will understand
What is a virtual machine?
- A program that has the same functionality as a physical computer
What do emulators do?
-Trick a program into thinking it’s running on its native hardware when it’s running on an entirely different machine
What is an advantage of virtual servers?
- If one server stops working, the others can pick up the load and continue working as if nothing happened
Give one example of intermediate code running on a virtual machine.
- Java
Why is Java good for running on virtual machines?
- Because other programming languages would either have to use a specific language of each device or use a suitable compiler.
- Java gets around this by compiling its code into a half-way code known as bytecode or intermediate code
- This code is then translated by a Java Virtual Machine (JVM) running on a target device which then translates it into specific machine code
Why is one advantage of the JVM process?
- Makes the code highly portable between devices.
What are the 2 types of software?
- System software
- Application software
What are the 2 types of system software?
- Operating Systems
- Utility software
What are some examples of Operating Systems?
- Windows
- Linux
- Windows
- macOS
- iOS
What are some examples of utility software?
- Antivirus
- Defragmentation
- Backup
- Compression
- Firewalls
What are some examples of application software?
- Presentation
- Word processor
- Web browser
- Games
What is a generic application?
- A word processor is an example of one. It does not have a specific or narrow purpose
- You can use it to carry out different tasks and meet multiple needs
What is a specific application?
- Database software is an example of one.
- Being highly specific and bespoke, however, makes it almost essential for creating serious database application
Where does specific application software tend to be installed?
- On systems where there is a direct need
What is utility software?
- Software designed to:
- Keep your computer safe
- Keep it running efficiently
- Provide you with useful tools to manage your files and applications
Utility software: What is file repair used for?
- Files can become corrupt or damaged for a number of reasons
- File repair attempts to correct these issues and restore the file to its original working state