Ch. 4 PPT Flashcards

1
Q

What is a unit of dispaching?

A

Thread/lightweight process

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

Unit of resource ownership

A

Process/task

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

What is multithreading?

A

The ability of an OS to support multiple, concurrent paths of execution within a single process

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

What is the single threaded approach?

A

There is a single thread of execution per process. Really, the concept of a thread is not recognized.

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

What is the multithreaded approach?

A

A process that spawns multiple threads, like the JRE

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

Where is the process image stored?

A

The virtual address space

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

What does a process have protected access to?

A

Processors, other processes, files, and I/O resources

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

What are some benefits of threads?

A

Takes less time than making/terminating a process, faster switching between threads, increases efficency/communication between programs

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

In a single-user system, what are threads good for?

A

Asynchronous processing, faster execution, and modular programs

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

Where is execution information stored?

A

In a thread-level data structure.

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

What happensto threads if a process is suspended/terminated?

A

All threads are suspended or terminated for that process

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

What are the key thread states?

A

Running, ready, and blocked

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

What are the thread change states?

A

Spawn, block, unblock, finish

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

How are threads synchronized?

A

All threads of a process share an address space/resources/ If a resource is altered, it affects all threads in the process

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

How are user level threads handled?

A

Managed by application, and many-to-one mappings

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

What are the advantages of user level threads?

A

Thread switching does not require kernel priveleges, scheduling can be application specific, and can be run on any OS

17
Q

What is bad about a ULT?

A

Any system calls are blocking, effecting all threads of a process if a system call is made. Might not take advaqntage of multiprocessing.

18
Q

What is the ULT work around for system calls?

A

Make the application spawn as multiple processes rather than threads

19
Q

What is a kernel level thread?

A

One that is managed entirely by the kernel and not at all by the application

20
Q

What is good about KLT’s?

A

The kernel can simotaneously schedule threads on multiple processors, and multiple threads in a process can be run if one in that process is blocked.

21
Q

What is bad about KLT’s?

A

A mode switch is required when switching control between threads, and is less portable than ULT.

22
Q

What is a combined approach?

A

Threads are created in the user space and most of scheduling is done by the application. Solaris is an example.

23
Q

How would IO implemented as a single process behave?

A

The IO operation threads would be subject to swapping

24
Q

What do multicore benefits depend on?

A

The ability to exploit parallel resources while executing

25
Q

When do things benefit from multicore environments?

A

Applications that are natively multithreaded/multiprocess

26
Q

How does solaris behave in multicore environments?

A

It has processes, user level threads, lightweight processes, and kernel threads

27
Q

How does linux handle multithreading?

A

There is no distinction between threads and processes. User level threads are mapped into kernel processes

28
Q

How is communication between threads handled in linux?

A

Processes with the same group ID can share space in memory

29
Q

What is sandboxing?

A

Each application is essentially run in a VM, and all of the resources they use are invisible tot he other apps. All threads execute in the same VM

30
Q

What uses sandboxing?

A

Android

31
Q

How does android reclaim resources?

A

A precedence heiarchy of processes to kill