Operating System MCQ and Answers – Thread Pools

These Operating System MCQ and Answers – Thread Pools are asked in various examinations including BCA, MCA, GATE, and other tests. The questions based on the below Operating System MCQ and Answers – Thread Pools test your basic knowledge of MCQs on the topic of Operating Systems and the level of comprehension and grasp that you hold.

Operating System MCQ and Answers – Thread Pools

1. Thread pools limit the number of threads that exist at any one point, hence ____________

a) not letting the system resources like CPU time and memory exhaust

b) helping a limited number of processes at a time

c) not serving all requests and ignoring many

d) none of the mentioned

Answer: a

2. The number of the threads in the pool can be decided on factors such as ____________

a) number of CPUs in the system

b) amount of physical memory

c) expected number of concurrent client requests

d) all of the mentioned

Answer: d

3. Thread pools are useful when ____________

a) when we need to limit the number of threads running in the application at the same time

b) when we need to limit the number of threads running in the application as a whole

c) when we need to arrange the ordering of threads

d) none of the mentioned

Answer: a

4. Instead of starting a new thread for every task to execute concurrently, the task can be passed to a ___________

a) process

b) thread pool

c) thread queue

d) none of the mentioned

Answer: b

5. Each connection arriving at multi threaded servers via network is generally ____________

a) is directly put into the blocking queue

b) is wrapped as a task and passed on to a thread pool

c) is kept in a normal queue and then sent to the blocking queue from where it is dequeued

d) none of the mentioned

Answer: b

6. What is the idea behind thread pools?

a) a number of threads are created at process startup and placed in a pool where they sit and wait for work

b) when a process begins, a pool of threads is chosen from the many existing and each thread is allotted equal amount of work

c) all threads in a pool distribute the task equally among themselves

d) none of the mentioned

Answer: a

7. If the thread pool contains no available thread ____________

a) the server runs a new process

b) the server goes to another thread pool

c) the server demands for a new pool creation

d) the server waits until one becomes free

Answer: d

8. Thread pools help in ____________

a) servicing multiple requests using one thread

b) servicing a single request using multiple threads from the pool

c) faster servicing of requests with an existing thread rather than waiting to create a new thread

d) none of the mentioned

Answer: c

Comments