Chapter 16 System Software Flashcards

1
Q

Operating System - Definition

A

A software that manages hardware resources and provides user interface

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

Purpose of OS (theres 7)

A
  • Provide interface
  • CPU management
  • Memory management
  • Manages peripherals
  • Organise file system
  • Security
  • Utilities
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

OS Multitasking

A

More than one program can be stored in memory, but only one can have CPU access at any given time.

The rest of programs remain ready

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

3 Memory Process States

A

Ready: A new process arrived at the memory, and the PCB is created

Running: Has CPU access

Blocked: Cannot progress until some event has occurred

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

Scheduling

A

Ensures that the computer system can serve all requests and obtain a certain quality of service.

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

4 Scheduling Algorithms

A
  1. Round Robin
  2. Shortest Job First
  3. First Come First Serve
  4. Shortest Time Remaining.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Explain what Round Robin is

List the Advantage/ Disadvantages

A
  • Allocates a fixed time slice to each process
  • Preemptive
  • Does not prioritize

Advantage
- Starvation does not occur

Disadvantages
- The processing resources could be used up on schedulling rather than processing

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

Shortest Job First, Define and give disadvantage

A

A scheduling process that selects the waiting process with the shortest execution time.

Disadvantages:
1. Hard to predict execution time
2. Can cause starvation of resource - long execution programs may have to wait an indefinite amount of time

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

Purpose of a User Interface

A
  • hides the complexities of the computer/ hardware/ OS from the user
  • Provides access systems for users with differing needs
  • Avoids complex commands involving memory location
  • for example a graphical user interfaces which uses icons for navigation
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

First Come First Served

A
  • No complex logic - each process is executed one after the other
  • Received processes are queued

Advantage
- Starvation doesnt occur - all processes will get a chance to run… eventually

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

Virtual Memory - what is it

A
  • Secondary storage is used to simulate additional main memory
  • Its created temporarily
  • Extends RAM - CPU appears to be able to access more memory that the actual available RAM
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Why would you use Virtual memory

A

It can be used when RAM is running low - computer processing many things at once

For more efficient use of RAM - any programs not running can be moved to virtual memory

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

Paging

A

Reading/ writing blocks of data from/to secondary storage when required

  • memory is divided into fixed size blocks
  • dividing of memory into pages done by the operating system
  • faster access times than segmentation
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Segmentation

A
  • Divides memory into variable sized blocks
  • segment size is calculated by the compiler
  • slower access time than paging
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Disk Thrashing

A
  • occurs when frequent transfers between main and secondary memory take place (when virtual memory is being used)

—> as main memory fills up, more pages need to be swapped in and out of secondary memory
—> this swapping leads to a very high rate of hard disk head movements
—> eventually, more time is spent swapping the pages/ data than processing it.

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

2 types of Translation Software

A

Interpreter and Compiler

17
Q

Explain the process of Interpreter

A
  • examines code one line at a time
  • checks each statement for errors
    —> if no error is found then statement/ line is executed
    —> if found the error is flagged anbd reported, interpreter is halted
  • interpretation is repeated for every iteration in loops
  • interpretation has to be repeated every time the program is run
18
Q

Compiler: State the 4 Compilation stages

A
  1. Lexical Analysis
  2. Syntax Analysis
  3. Code Generation
  4. Optimisation
19
Q

Explain the 4 stages of Compilation

A

Lexical Analysis
- Converting a sequence of characters into a sequence of tokens

Syntax Analysis
- Uses parsing algorithms to interpret the meaning of a sequence of tokens
- checks if code matches the grammar of the language
- syntax errors are reported
- parse tree is produced

Code Generation
- Converting intermediate representation of source code into executable code

Optimisation
- Minimising a programs execution time and memory requirement

20
Q

Why is RPN used

A

RPN or Reverse Polish Notation is used to carry out evaluation of expressions
- Provides an unambiguous method of representing an expression
- reads from left to right
- doesnt require brackets or rules of BODMAS