L7 - Concurrency Flashcards

1
Q

Semaphores are ________________ that can only accessed by _________ and _________.

A

Semaphores are kernel data structures, that can only be accessed by wait and signal.

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

What is Push Through Blocking?

A

In push through blocking, the medium priority task is blocked by a lower priority task which inherited a higher priority from a task it directly blocks.

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

Name the three problems that can occur while multi-threading.

A
  • Race Conditions
  • Priority Inversions
  • Starvation
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What does NPP stand for?

A

In NPP (Non-Preemptive Protocol), a task that enters a critical section gets the highest priority level and therefore prevents a deadlock. NPP is easy to implement and denies preemption during execution of any critical section

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

Describe Starvation.

A

Process is denied necessary resources and waits forever.

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

Multi-Tasking

A

Parallel execution of independent processes is called multi-tasking.

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

Priority Ceiling Protocol (PCP) avoids ____________, ____________ and ____________. What is the concept of PCP?

A

Priority Ceiling Protocol (PCP) avoids priority inversion, deadlocks and chained blocking. Task can only enter critical section if priority is higher than priority ceiling of all currently locked semaphores

The protocol has:

  • medium permission
  • deadlock prevention and medium implementation
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is a Race Condition?

A

Threads/processes are reading or writing shared data. This leads to results depending on the exact execution order of instructions.

Solution: critical sections and mutual exclusion

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

What is understood under the term of performance degradation?

A
  • Slow Memory Access
  • changing threads
  • time consuming thread synchronization
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is not allowed in a critical section?

A

In critical sections shared resources are not allowed to be simultaneously accessed by competing tasks. There is only one process in the critical section.

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

Thread

A

Different execution paths that operate on the same data.

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

What is generally known as Memory Wall?

A

Memory speed does not keep up with processor speed.

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

How is Concurrency defined?

A

In concurrent processes code or instructions are executable in parallel.

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

Power Wall

A

High clock frequencies lead to high thermal output that can’t be handled.

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

Define HLP.

A

HLP stands for Highest Locker Priority Protocol: task in critical section is given highest dynamic priority. With an easy implementation and medium permission, HLP prevents a possible deadlock.

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

Multi-Threading

A

Parallel execution of independent subsequences is called multi-threading.

17
Q

Direct Blocking

A

Higher priority wants to access resource that is held by a lower priority task.

18
Q

In which protocol are tasks scheduled based on their active priority?

A

Priority Inheritance Protocol (PIP):

  • Low permission
  • no deadlock prevention and difficult implementation.
19
Q

Which resources does an execution of a process demand and on which factors does the execution time depend on?

A
  • CPU time
  • memory
  • hardware resources

The execution time depends on:

  1. CPU performance
  2. Availability of resources
  3. Input parameters
  4. Delays
20
Q

Priority Inversion

A

Low-priority task blocks high priority process.

21
Q

How many memory regions do threads use?

A

Threads always use the same memory region which leads to…

  • very low management effort
  • high efficiency
  • but also to conflicts (common memory space)
22
Q

Name limiting factors of memory development.

A
  • Memory Wall
  • Power Wall
  • Performance Degradation.