Question 21
EasyWhat is a pipe used for?
- A.
Cooling the CPU
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Operating Systems
What is a pipe used for?
Cooling the CPU
Sending a stream of data from one process to another
Joining two disks into one
Storing passwords
Sign up free to see the answer and a step-by-step explanation.
How does shared-memory communication between processes work?
The processes send letters by email
The OS copies every file twice
The processes must run on different computers
The processes read and write a common region of memory
Sign up free to see the answer and a step-by-step explanation.
How does message-passing communication between processes work?
Processes share one stack
Processes share a single thread
Processes send and receive messages through the operating system
Processes read each other's registers
Sign up free to see the answer and a step-by-step explanation.
What does it mean when a process is CPU-bound?
It cannot use the CPU
It is waiting for the disk
It spends most of its time computing rather than waiting for input/output
It is limited to one CPU core by law
Sign up free to see the answer and a step-by-step explanation.
What does it mean when a process is I/O-bound?
It uses only the CPU
It never uses input or output
It spends more time waiting for input/output than computing
It is blocked forever
Sign up free to see the answer and a step-by-step explanation.
What is the difference between concurrency and parallelism?
Concurrency means making progress on several tasks over the same period; parallelism means running them at the same instant on several cores
They mean exactly the same thing
Parallelism needs only one CPU core
Concurrency is only for networks
Sign up free to see the answer and a step-by-step explanation.
What is a thread pool?
A set of threads created in advance and reused to run tasks
A place where crashed threads are stored
A list of thread passwords
A single thread shared by all processes
Sign up free to see the answer and a step-by-step explanation.
Which part of the OS moves a process from the ready state to the running state?
The file system
The compiler
The CPU scheduler (dispatcher)
The device driver
Sign up free to see the answer and a step-by-step explanation.
When does a running process typically move to the waiting state?
When its time slice ends
When it requests I/O or waits for an event
When it finishes
When it is created
Sign up free to see the answer and a step-by-step explanation.
In the many-to-one threading model, what happens when one user thread makes a blocking system call?
The whole process blocks
Only that thread blocks
The OS creates a new kernel thread
The call is ignored
Sign up free to see the answer and a step-by-step explanation.