1.2.1 // System Software Flashcards

You may prefer our related Brainscape-certified flashcards:
1
Q

What’s the OS’s main purpose, and what are some of it’s functions?

One sentence for purpose, and list it’s 4 main functions.

A

It manages hardware and provides an interface between the user and the application software.

It’s main functions are:
1. Providing a User Interface
2. Memory Management
3. Interrupt Handling
4. Processor Scheduling.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the purpose of Memory Management?

Don’t speak about a specific type of MM, give general information.

A
  • Organises the use of (Main) Memory by converting logical addresses to physical addresses.
  • Allows programs to share and allocate memory
  • Protects data and programs from eachother
  • Allows programs larger than Main Memory to run.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What’s Paging, and why is it useful?

Speak about Virtual Memory and programs larger than RAM.

A
  • A MM technique where parts of the program are swapped from Virtual Memory to RAM when needed; It’s only used when RAM is full.
  • It’s useful as it lets programs larger than RAM to be run.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How does Paging work, and what are it’s properties?

Speak about divisions, and non-contiguity.

A
  • The Memory Manager divides RAM into equal sized sections called Pages. These pages are equal sizes in the Hard Disk too. (4KB)
  • Because Paging uses Physical Division, Pages can be present in any location and order. (Non-Contiguous)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are the Advantages of Paging?

A
  1. Pages having fixed sizes // Allocating Pages and working out their location is much easier
  2. Memory Efficient // All pages can be used with no space between them.
  3. Automatic // Programmer/users don’t need to worry about Paging.

On the other hand, memory within a page may be wasted as programs are unlikely to take up that exact amount of space.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is Segmentation, and why is it useful?

A
  • An MM technique where memory can be divided into logical segments which can be of different lengths.
  • It’s useful because only the exact space needed is used per program.

Segments can relate to part of a program, e.g. a subroutine or function.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What are the Disadvantages of Segmentation?

A
  1. Wasted Space // As programs are loaded and removed from memory, wasted space may form between segments.
  2. Programmer Concerns // Programmers often need to specify segments in some architectures.

However, segments being dynamic can reduce internal fragmentation.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is Virtual Memory, and when is it used?

A
  • VM is a higher level MM technique where an area of the Hard Disk is designated to store pages of programs until they are needed in RAM.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is Disk Thrashing, and how does it happen?

Talk about insufficient RAM

A
  • Disk Thrashing happens when pages are being repeatedly swapped from VM to RAM. This happens more if the computer has insufficient RAM.
  • It can noticeably slow down the Hard Disk’s transfer speeds.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What’s an Interrupt, and what sort of things can cause one?

Talk about priority and the CPU.

A
  • A signal to the processor that makes it halt it’s current task(s) to focus on executing a higher-priority event.

Things that can cause an Interrupt include:
* Hardware devices such as an I/O device
* Software during an error
* A scheduled Interrupt from the Internal Clock
* Power Failure

The CPU checks for any interrupts to be processed AFTER the execution stage of the FDE cycle.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How does the CPU use the Stack to handle Interrupts?

Speak about Register contents, the ISR, and pushing & popping.

A
  • When an interrupt is detected, fetching is delayed and the contents of the CPU registers are pushed onto a Stack.
  • The CPU then calls the ISR (Interrupt Service Routine) to process the Interrupt. When processing finishes, register values are popped from the stack back into the CPU.

The Stack is a LIFO data structure; meaning the last data pushed on will be the first one popped and retrieved.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What’s Interrupt Priority, and how is the Stack involved?

Some Interrupts are of a higher priority than others…

A
  • When a higher-priority Interrupt is recieved, the current Interrupts’ register contents will be pushed onto the stack and the higher-priority Interrupt processed.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is Processor Scheduling, and what is it’s main purpose?

Speak about CPU engagement and execution starting.

A
  • A technique used by the OS to allocate time for each application to use the CPU, creating the illusion of multi-tasking.

It’s main objectives are:
* Maximising CPU engagement by minimising when the CPU is idle
* Allowing all processes to be given resources, ensuring fairness.
* Minimising response time between starting execution after being scheduled.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is Round Robin, and how does the CPU know when to switch between time slices?

A
  • A PS technique where (by FIFO) a time slice is allocated by which the CPU’s resources can be used.
  • The CPU knows when to switch between time slices by acknowledging if the job has been completed at the end of each time slice.

FIFO: First In, First Out

Round Robin is great for ensuring fairness, and maximising CPU engagement.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What are the Drawbacks of Round Robin?

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is First Come First Serve, and what could the Drawbacks be?

Talk about CPU utilisation, and long wait times

A
  • A PS technique where the first job to arrive is solely processed until it completes.
  • Shorter processes may need to wait for a longer one to finish processing.
  • Underutilisation of the CPU, causing inefficiency in Time-Sharing Environments.
17
Q

What is Shortest Remaining Time?

A
  • A PS technique where each job’s completion time is estimated on arrival.
  • The job with the shortest remaining time to completion is executed, meaning shorter, new jobs can take over processing over a current one.
18
Q

What are the Drawbacks of Shortest Remaining Time?

A
  1. The CPU needs to know the length of the task.
  2. If there are too many short jobs, a longer one may be ‘starved’ and take a while to get processed.

Tends to be faster than Shortest Job First, although it has more overhead.

19
Q

What is Shortest Job First?

A
  • Similar to SRT, the estimated time to process a job is estimated by the User.
  • The waiting job with the smallest execution time is executed when the current job is completed.
20
Q

What are Multi-Level Feedback Queues?

Speak about priorities & waiting times.

A
  • A PS technique where multiple queues are created with different priority levels.
  • If a job uses too much CPU time, it is moved to a lower-priority queue.
  • If a process has waited long enough, it is moved to a higher-priority queue.