Systems software Flashcards
software and software development
Define what an operating system is
software that controls the computer, manages the computer’s hardware and from which other programs can be run
Outline the role of an operating system
- Manage the system hardware
- Manage the installation and running of programs
- Manage the security of the system
- Provide a user interface
Define user interface
How the computer and the user interact.
This could be :
- The command line interface, where operating system commands are typed in
- Graphical user interface, where programs run in Windows and the user interacts using a mouse and icons
Describe paging
This is when programs are divided physically into equal-sized blocks called pages
Describe segmentation
When programs are divided logically . They are split into blocks containing modules or routines
Why do we need virtual memory?
When a system runs low on physical memory (RAM), it uses virtual memory (an area of secondary storage).
How does the OS manage memory? Why?
Pages are swapped from main memory to virtual memory when not needed and then back to main memory when required. If this happens too often the computer slows down (disk thrashing).
Define interrupt
A signal sent to a CPU to indicate another process needs the processor’s time
Why do we need interrupts
The CPU needs to know when a device needs its attention.
When can Interrupt take place
An Interrupt can only take processor time from tasks with lower priority. When an interrupt is raised, the operating system runs the relevant interrupt service routine(IRS).
What happens before an interrupt request can be handled
At the end of each iteration of the fetch-decode-execute cycle, the processor checks to see if there are any interrupts. If there are, and they are of higher priority than the current task, then a range of steps take place.
What happens when there is an interrupt
The contents of the program counter and the other registers are copied to an area of memory called a stack.
- The relevant ISR can then be loaded by changing the program counter to the location of the ISR in memory.
- When the ISR is complete, the previous values of the program counter and other registers can be restored from the stack to the CPU.
What happens when a new, higher-priority interrupt is raised
The interrupt currently being serviced is also added to a stack in memory and the new interrupt is serviced. Once this new interrupt is finished, the previous interrupt is taken off the stack and continued.
what does scheduling ensure
That each job and user gets sufficient processing time.
Define scheduling
The method an operating system uses to ensure all processes get sufficient processing time.
A scheduler uses a scheduling algorithm to determine how to share processor time
What are the 5 scheduling algorithms
- Round robin
- First come first served
- Shortest job first
- Shortest remaining time
- Multilevel feedback queues
Describe ‘round-robin’
Each process is given a fixed amount of time.
If it hasn’t finished by the end of the time, it goes to the back of the queue so the next process in line can have its turn.
Describe ‘first come first served’
The first process to arrive is dealt with by the CPU until it is finished.
Meanwhile, any other processes that come along are queued up waiting for their turn.
Describe ‘shortest job first’
Picks the job that will take the shortest take and runs it until it finishes
Describe ‘shortest time remaining’
The scheduler estimates how long each process will take.
It then picks the one that will take the least amount of time and runs that.
This algorithm is pre-emptive. This means that if it hasn’t been completed after a certain amount of time, the scheduler checks whether any shorter process have been added. If so, it switches to them.
Describe ‘multilevel feedback queue’
Uses a number of queues.
Each of these queues has a different priority. The algorithm can move jobs between these queues depending on the job’s behaviour.
What are the 5 types of operating systems
- Distributed operating system
- Embedded operating system
- Multitasking operating system
- Multi-user operating system
- Real-time operating system
Describe a distributed operating system
Allows multiple computers to work together on a single task.
when can a distributed operating system be used
+ example
They tend to be used in systems aimed at completing computationally intensive tasks.
Eg. rendering complex 3D animations (where the workload can be shared across a collection of computers using a distributed operating system )
Describe an embedded operating system
Designed to run on embedded systems rather than general-purpose computers.
Define an embedded system
A computer that forms part of a device such as a washing machine, vending machine or a car’s engine management systems
Describe a multitasking operating system
Can run multiple programs simultaneously
When can a multitasking operating system be used
+example
Most modern personal computer operating systems are multitasking
Eg. Windows, MacOS and Linux
Describe a multi-user operating system
Allows multiple users to use a system and its resources simultaneously!
When can a multi-user operating system be used
+example
Tend to be used on larger, more powerful mainframe computers able to service large numbers of users at the same time
Eg. Banks and retailers
(which are capable of processing large numbers of transactions while being accessed by customers and employees)
Describe a real-time operating system
Designed to carry out actions within a guaranteed amount of time even when left running for long periods. Usually the expected response time is within a small fraction of a second.
When can a real-time operating system be used
+example
Autopilot on a plane is an example of a system that needs to run using a real-time operating system. If the plane needs to move it is essential there is no delay.
What is the BIOS and what does it do
BIOS - basic input/output system
When a computer is first switched on it looks to the BIOS to get up and running, and so the processor’s program counter points to the BIOS’s memory.
- loads the operating system into main memory
- contains the computer’s start up instructions
- loads configaration/ settings
Where is the BIOS stored
Originally stored on ROM, nowadays the BIOS is stored on flash memory so that it can be updated. This also allows settings such as the boot order of disks to be changed and saved by the user.
why do we need device drivers
To allow computers to communicate with various devices with different models and manufacturers.
what is a device driver
A piece of software that tells the operating system how it can communicate with hardware.
What role does the operating system play in managing device drivers?
The OS identifies hardware components and automatically installs or updates drivers without user intervention.
They connect to online databases or the device manufacturer’s servers to download compatible drivers, making the process more seamless for users.
What is a virtual machine, and how does it work
A virtual machine is a program that mimics the functionality of a physical computer.
- It runs on top of a host operating system, imitating a real machine’s hardware and software conditions.
- This allows it to operate as if it were a separate physical computer.
Why might someone run one operating system within another using a virtual machine
This might be necessary when a specific program requires an operating system that is different from the host system.
, or when developers want to test their software on multiple platforms without needing separate physical machines.
what is intermediate code
An artificial computer-readable representation of a program, designed to be efficient but not directly readable by the CPU
How does machine code differ from machine code
Unlike machine code, intermediate code cannot be executed by a CPU and is platform-independent, making it highly portable.
Why can’t intermediate code be directly run on a processor
It is not designed for processors and requires a virtual machine to interpret and execute it.
What role does a virtual machine play in executing intermediate code
A virtual machine converts it into instructions that the underlying hardware can execute.