Most Likely Flashcards

1
Q

Deadlock occurs when

A

every process in a set is waiting for an event that can only be caused by another process in the set

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

Deadlock can occur only when the following four conditions are satisfied:

A

Mutual exclusion

Hold and wait

No preemption

Circular wait

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

Mutual exclusion

A

only one process at a time can use a resource

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

Hold and wait

A

a process holding at least one resource is waiting to acquire additional resources held by other processes

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

No preemption

A

a resource can be released only voluntarily by the process holding it, after that process has completed its task

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

Circular wait

A

here exists a set {P0, P1, …, Pn} of waiting processes such that P0 is waiting for a resource that is held by P1, P1 is waiting for a resource that is held by P2, …, Pn-1 is waiting for a resource that is held by Pn, and Pn is waiting for a resource that is held by P0.

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

A directed edge from a process to a resource is

A

called a request edge in system resource-allocation graph

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

The assignment edge is

A

a directed edge from a resource to a process.

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

A cycle in a resource-allocation graph is

A

not a sufficient condition for deadlock in the case that each resource has more than one instance.

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

A cycle in a resource-allocation graph is sufficient and necessary only

A

if each resource has only one instance.

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

Most OS pretend that deadlock

A

will never happen and leave it up to the responsibility of application programmer.

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

An unsafe state may lead to a

A

deadlocked state, but not necessary must lead to.

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

contiguous memory allocation

A

each process is contained in a single section of memory that is contiguous to the section containing the next process

With contiguous memory allocation, all portions of a process must be loaded into sequential physical memory partitions.

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

First fit

A

Allocate program to the first partition big enough to hold it

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

Best-fit

A

The allocator places a process in the smallest block of unallocated memory in which it will fit.

has the least wasted space and the smallest partition fitting the requirements.

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

worst-fit

A

Allocate program to the largest partition big enough to hold it

Allocate the largest hole. Again, we must search the entire list, unless it is sorted by size.

17
Q

External fragmentation

A

is the phenomenon that results in unused blocks of memory outside of existing partitions.

18
Q

All processes in a computer system share a

A

single inverted page table.

19
Q

Each entry in the inverted page table contains

A

a process id and page number

20
Q

Pure paging has

A

fixed page size, has internal fragmentation (so wasted memory is from internal fragmentation)

21
Q

effective memory-access time

A

Average time required to access memory based on the TLB Hit Ratio.

22
Q

translation look-aside buffer

A

Hardware cache of recently used page table entries. Smaller page size increases page count, resulting in larger page tables and smaller ____ hit ratio.

A small but fast-lookup hardware cache which stores page and frame numbers for memory access.

23
Q

The optimal page replacement policy is

A

impossible to implement because it would require the OS to have perfect knowledge of future events.

24
Q

A dead-lock free solution may still

A

have the problem of starvation.

25
Q

Global replacement for page replacement which can select the replacement page from any other process has the problem that

A

a certain process cannot control it page-fault rate.

26
Q

Local replacement only allows the system to

A

choose a replacement page from the pages belonging to the same process. Global replacement algorithm is more frequently used due to its efficiency in utilizing memory resources.

27
Q

Copy-on-Write allows

A

the parent and child processes to initially share the same pages, but when either process modifies a page, a copy of the shared page is created

28
Q

Thrashing occurs when

A

a process spends more time paging than executing.