Question 51
MediumWhy do operating systems avoid swapping out a process that is waiting for I/O into its memory buffer?
- A.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Operating Systems
Why do operating systems avoid swapping out a process that is waiting for I/O into its memory buffer?
Such processes are already terminated
I/O processes have high priority
The device might write into memory that now belongs to another process
Swapping is always slow
Sign up free to see the answer and a step-by-step explanation.
Which of these is an advantage of paging over contiguous allocation?
No page tables needed
Addresses need no translation
No internal fragmentation
No external fragmentation
Sign up free to see the answer and a step-by-step explanation.
A memory leak in a long-running server is most likely to cause what over time?
The server gradually uses more and more memory until it slows or crashes
Files are deleted
The network disconnects
The CPU runs faster
Sign up free to see the answer and a step-by-step explanation.
What does a segmentation fault usually indicate?
The CPU is overheating
A network timeout
A program tried to access memory it is not allowed to
The disk is full
Sign up free to see the answer and a step-by-step explanation.
Which address binding allows a process to be moved to a different place in memory while it is running?
Link-time binding
Compile-time binding
Execution-time binding (with hardware such as an MMU)
Load-time binding
Sign up free to see the answer and a step-by-step explanation.
Which kind of fragmentation do fixed-size partitions mainly cause?
External fragmentation
No fragmentation
Disk fragmentation
Internal fragmentation
Sign up free to see the answer and a step-by-step explanation.
A buddy system manages 256 KB. Which block size does a 21 KB request receive?
64 KB
16 KB
21 KB
32 KB
Sign up free to see the answer and a step-by-step explanation.
With first fit, about how much memory is lost to fragmentation according to the 50-percent rule?
None
For N allocated blocks, another 0.5N blocks are lost — about one-third of memory
Half of all memory
Exactly one block
Sign up free to see the answer and a step-by-step explanation.
What is the main cost of compaction?
It increases internal fragmentation
The CPU time spent copying processes to new locations
It needs a second disk
It deletes processes
Sign up free to see the answer and a step-by-step explanation.
When does a segmentation fault occur?
When the disk is full
When a program accesses memory it is not allowed to (outside its segments or with the wrong permission)
When two processes share memory
When the CPU overheats
Sign up free to see the answer and a step-by-step explanation.