Week 6 Flashcards

1
Q

What is virtual memory?

A

Virtual memory involves the separation of logical memory from physical memory. It allows an extremely large virtual memory to be provided when only a smaller physical memory is available

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

What is the benefit of a virtual memory system?

A

Each program takes less physical memory while running therefore more programs run at the same time. Increased CPU utilization and throughput with no increase in response time or turnaround time.

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

What is demand paging?

A

Demand paging is a method used to implement virtual memory where a page is brought into memory only when it is needed.

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

What is the valid-invalid bit scheme?

A

The valid-invalid bit scheme is a scheme used to determine whether a process is in memory or not. In a page table if a process valid-invalid bit “v” this means that it is in memory, but if it has the “i” bit this means that it is not in memory. Initially valid-invalid bit is set to “i” on all entries

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

What is a page fault?

A

A page fault is where process tries to access a page that is marked as invalid.

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

How are page faults dealt with?

A

If the page fault occurred because the reference was invalid the process is aborted, otherwise if the page was just not in memory yet the following occurs:
1. Find free frame
2. Read the desired page into the newly allocated frame
3. Reset tables to indicate page now in memory
4. Restart the instruction that caused the page fault.

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

What is pure demand paging?

A

Pure demand paging is where a process begins execution with no pages in memory. This then causes there to be page faults and the pages are then brought into memory.

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

What is Copy-on-Write?

A

Copy-on-Write (COW) is a technique that allows both parent and child processes to initially share the same pages in memory

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

What occurs when there is no free frame?

A

If there are no free frames then a page replacement algorithm is used to select a victim frame. The desired page is then brought into the (new) free frame and the page and frame tables are updated. The process is continued by restarting the instruction

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

What are the three types of page replacement algorithms?

A
  1. First-In-First-Out - Replace oldest page
  2. Optimal Algorithm - Replace page that will not be used for longest period of time (Must be able to see future)
  3. Least Recently Used (LRU) Algorithm - Replace page that has not been used for the longest period of time
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What do page replacement algorithm aim to achieve?

A

Page-replacement algorithm want lowest page-fault rate

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