Operating System Concepts - User and Kernel Threads
26 Questions
0 Views

Operating System Concepts - User and Kernel Threads

Created by
@ReachableMatrix

Podcast Beta

Play an AI-generated podcast conversation about this lesson

Questions and Answers

In the One-to-One threading model, each user-level thread maps to a ______ thread

kernel

Creating a user-level thread in the One-to-One model creates a ______ thread

kernel

The Many-to-Many threading model allows many user-level threads to be mapped to many ______ threads

kernel

The Two-level model is similar to Many-to-Many but allows a user thread to be bound to a ______ thread

<p>kernel</p> Signup and view all the answers

Thread library provides programmer with API for creating and managing ______

<p>threads</p> Signup and view all the answers

Two primary ways of implementing thread libraries: Library entirely in ______ space

<p>user</p> Signup and view all the answers

Pthreads may be provided either as ______-level or kernel-level

<p>user</p> Signup and view all the answers

A POSIX standard API for thread creation and synchronization is known as ______

<p>Pthreads</p> Signup and view all the answers

Java threads are managed by the ______

<p>JVM</p> Signup and view all the answers

Rather than explicitly creating threads, Java allows thread creation around the ______ interface

<p>Executor</p> Signup and view all the answers

Thread-local storage (TLS) allows each thread to have its own copy of ______

<p>data</p> Signup and view all the answers

TLS is useful when you do not have control over the thread creation process, for example, when using a ______ pool

<p>thread</p> Signup and view all the answers

Local variables are visible only during a single function invocation, while TLS is visible across function invocations, similar to ______ data

<p>static</p> Signup and view all the answers

Scheduler Activations in the context of thread models require communication to maintain the appropriate number of kernel threads allocated to the ______

<p>application</p> Signup and view all the answers

In the context of Scheduler Activations, typically an intermediate data structure like lightweight process (LWP) is used between user and kernel threads, where each LWP is attached to a kernel ______

<p>thread</p> Signup and view all the answers

Scheduler Activations involve creating LWPs to determine how many ______ to create

<p>LWPs</p> Signup and view all the answers

The ForkJoinTask is an abstract base class. RecursiveTask and RecursiveAction classes extend ______ Task

<p>ForkJoin</p> Signup and view all the answers

Grand Central Dispatch is an Apple technology for macOS and iOS operating systems. It provides extensions to C, C++, and Objective-C languages, API, and runtime library. It allows identification of ______ sections

<p>parallel</p> Signup and view all the answers

Intel Threading Building Blocks (TBB) is a template library for designing parallel C++ programs. It includes a serial version of a simple for loop. The same for loop can be written using TBB with ______ statement

<p>parallel_for</p> Signup and view all the answers

OpenMP is a set of compiler directives and an API for C, C++, FORTRAN. It provides support for parallel programming in shared-memory environments. It identifies parallel regions – blocks of code that can run in ______

<p>parallel</p> Signup and view all the answers

Grand Central Dispatch manages most of the details of threading. A block in Grand Central Dispatch is enclosed in “^{ }”. Blocks placed in a dispatch queue are assigned to an available thread in the thread pool when removed from the ______

<p>queue</p> Signup and view all the answers

Two types of dispatch queues in Grand Central Dispatch are: serial – blocks removed in FIFO order, queue is per process, called main queue, and ______ – removed in FIFO order but several may be removed at a time

<p>concurrent</p> Signup and view all the answers

For the Swift language, a task is defined as a closure – similar to a block, minus the caret. Closures are submitted to the queue using the ______() function

<p>dispatch_async</p> Signup and view all the answers

Semantics of fork() and exec() system calls involve the duplication of only the calling thread or ______ threads?

<p>all</p> Signup and view all the answers

Thread Libraries handle various threading issues such as semantics of fork() and exec() system calls, signal handling, synchronous and asynchronous thread cancellation of target thread, thread-local storage, and ______ Activations

<p>Scheduler</p> Signup and view all the answers

Fork-Join Parallelism in Java involves the ForkJoinTask as an abstract base class. RecursiveTask returns a result via the return value from the compute() method, while RecursiveAction does not return a ______

<p>result</p> Signup and view all the answers

More Like This

Use Quizgecko on...
Browser
Browser