WorksheetsFOS QUIZ 7
Total questions: 25
Worksheet time: 13mins
What is a process in an operating system?
A passive entity stored on disk
A program in execution
A data structure in the PCB
A shared memory block
Which of the following is NOT a state of a process?
Ready
Terminated
Waiting
Distributed
What does a Process Control Block (PCB) NOT contain?
Process state
Scheduling information
Network configuration
Memory management information
Which system call creates a new process in Unix?
exec()
fork()
wait()
exit()
In process scheduling, what is the purpose of the ready queue?
Hold processes waiting for I/O operations
Store terminated processes
Maintain processes ready for CPU execution
Synchronize interprocess communication
Which IPC model uses shared variables for communication?
Message Passing
Shared Memory
RPC
Sockets
What does the send() function do in message-passing systems?
Receives a message from a process
Sends a message to another process
Creates a new process
Synchronizes process execution
In which communication model are mailboxes used?
Direct communication
Indirect communication
Shared memory
RPC
What is the primary advantage of threads over processes?
Easier implementation
Better resource sharing
Reduced execution speed
Increased process creation overhead
What is multithreading?
Running multiple processes simultaneously
Running multiple threads in a single process
Executing tasks in a distributed system
Running multiple kernels on a CPU
Which of these is NOT a multithreading model?
One-to-One
Many-to-Many
Many-to-One
Single-to-Single
What type of threads does the POSIX Pthreads library provide?
User-level threads
Kernel-level threads
Both user-level and kernel-level threads
Java-based threads
In the Many-to-One model:
Each user thread maps to a unique kernel thread
All user threads map to a single kernel thread
Kernel threads map to user threads as needed
There is no mapping between threads
Which threading library is NOT supported by Linux?
Java threads
Windows threads
POSIX Pthreads
Kernel threads
In thread pools:
Threads are created dynamically during execution
Threads await work after creation
Threads manage memory for the process
Threads terminate upon task completion
What is the purpose of thread-local storage (TLS)?
Sharing data between threads
Providing each thread with its own data
Reducing synchronization overhead
Managing thread scheduling
Which of the following is an implicit threading technique?
Thread pools
Fork-Join
OpenMP
All of the above
How are signals delivered in multithreaded processes?
To all threads simultaneously
To a specific thread
To the process's main thread
It depends on the implementation
Which threading model provides the greatest flexibility?
Many-to-One
One-to-One
Many-to-Many
Two-level
What is fork-join parallelism?
A method to create threads dynamically
A way to divide tasks and join results
A model for managing multiple processes
A synchronization technique
Which language does NOT use implicit threading?
C
Java
Swift
Python
What is a kernel thread?
A thread created by the user application
A thread managed directly by the operating system kernel
A thread that handles I/O operations only
A thread exclusive to multicore systems
What is the primary distinction between concurrency and parallelism?
Concurrency is simultaneous execution; parallelism is multitasking
Concurrency makes progress on tasks; parallelism executes tasks simultaneously
Concurrency is specific to threads; parallelism to processes
There is no distinction
What does the term "process state" refer to in an operating system?
The name of the process
The resources allocated to a process
The current status of a process during its execution lifecycle
The CPU time used by a process
In the context of video playback, what does the "Waiting" state represent?
Video tab initializes
Video is playing
Video buffering due to slow internet connection
You close the video
