1What is the specific name given to the set of all logical addresses generated by a program?
A.Physical address space
B.Logical address space
C.Disk address space
D.Relocation register space
Correct Answer: Logical address space
Explanation:The set of all logical addresses generated by a program is referred to as the logical address space. The set of all physical addresses corresponding to these logical addresses is the physical address space.
Incorrect! Try again.
2Which hardware device is responsible for mapping virtual addresses to physical addresses at run time?
A.CPU
B.MMU (Memory Management Unit)
C.TLB (Translation Lookaside Buffer)
D.Cache Memory
Correct Answer: MMU (Memory Management Unit)
Explanation:The Memory Management Unit (MMU) is a hardware device that maps virtual (logical) addresses to physical addresses at run time.
Incorrect! Try again.
3In the context of swapping, what is the role of the backing store?
A.It acts as the primary cache for the CPU.
B.It is a fast disk large enough to accommodate copies of all memory images for all users.
C.It stores the page table base registers.
D.It is a read-only memory section for the kernel.
Correct Answer: It is a fast disk large enough to accommodate copies of all memory images for all users.
Explanation:The backing store is usually a fast disk that provides direct access to any memory image. It must be large enough to hold copies of all memory images for all users so that processes can be swapped out and back in.
Incorrect! Try again.
4Which memory allocation algorithm allocates the smallest hole that is big enough to hold the process?
A.First-fit
B.Best-fit
C.Worst-fit
D.Next-fit
Correct Answer: Best-fit
Explanation:Best-fit allocates the smallest hole that is big enough. This strategy produces the smallest leftover hole, though it requires searching the entire list unless it is ordered by size.
Incorrect! Try again.
5What type of fragmentation occurs when there is enough total memory space to satisfy a request, but the available spaces are not contiguous?
A.Internal fragmentation
B.External fragmentation
C.Page fault
D.Segmentation fault
Correct Answer: External fragmentation
Explanation:External fragmentation happens when total memory space exists to satisfy a request, but it is not contiguous; storage is fragmented into a large number of small holes.
Incorrect! Try again.
6Which technique can be used to solve the problem of external fragmentation by shuffling memory contents to place all free memory together in one large block?
A.Paging
B.Swapping
C.Compaction
D.Segmentation
Correct Answer: Compaction
Explanation:Compaction involves shuffling memory contents to place all free memory together in one large block. It is only possible if relocation is dynamic and is done at execution time.
Incorrect! Try again.
7In a paging system, physical memory is broken into fixed-sized blocks called:
A.Pages
B.Frames
C.Segments
D.Blocks
Correct Answer: Frames
Explanation:Physical memory is broken into fixed-sized blocks called frames. Logical memory is broken into blocks of the same size called pages.
Incorrect! Try again.
8If the size of a logical address space is and a page size is bytes, then the high-order bits of a logical address designate the:
A.Page offset
B.Frame number
C.Page number
D.Segment limit
Correct Answer: Page number
Explanation:The logical address is divided into two parts: a page number () and a page offset (). If the address space is and page size is , the high-order bits designate the page number.
Incorrect! Try again.
9What is the primary function of the Translation Lookaside Buffer (TLB)?
A.To store the entire page table in the CPU cache.
B.To reduce the effective memory access time by caching page table entries.
C.To handle page faults.
D.To perform segmentation calculations.
Correct Answer: To reduce the effective memory access time by caching page table entries.
Explanation:The TLB is a small, fast-lookup hardware cache. It stores recent translations from logical to physical addresses to avoid accessing the main memory page table for every reference, thus reducing Effective Access Time (EAT).
Incorrect! Try again.
10What type of fragmentation is commonly associated with Paging?
A.External fragmentation
B.Internal fragmentation
C.Both Internal and External
D.Neither
Correct Answer: Internal fragmentation
Explanation:Paging eliminates external fragmentation, but suffers from internal fragmentation. This occurs because frames are allocated as whole units, and the last frame allocated to a process may not be completely full.
Incorrect! Try again.
11In segmentation, a logical address consists of:
A.Page number, Page offset
B.Segment number, Segment offset
C.Frame number, Frame offset
D.Base address, Limit register
Correct Answer: Segment number, Segment offset
Explanation:A logical address in segmentation is a two-tuple: <segment-number, offset>.
Incorrect! Try again.
12Which hardware register in segmentation contains the value of the smallest legal physical memory address for a segment?
A.Limit register
B.Base register
C.Relocation register
D.Page-table base register
Correct Answer: Base register
Explanation:The base register contains the starting physical address (the smallest legal physical memory address) where the segment resides in memory.
Incorrect! Try again.
13In segmentation, what happens if the offset is greater than the value in the limit register?
A.A page fault occurs.
B.The OS allocates more memory.
C.A trap (addressing error) is generated.
D.The offset wraps around to 0.
Correct Answer: A trap (addressing error) is generated.
Explanation:The limit register specifies the length of the segment. If the offset , the hardware generates a trap to the operating system (addressing error).
Incorrect! Try again.
14Which of the following is a technique where a process can be larger than the physical memory allocated to it?
A.Contiguous Allocation
B.Overlays
C.Virtual Memory
D.Swapping
Correct Answer: Virtual Memory
Explanation:Virtual memory allows the execution of processes that are not completely in memory, enabling the logical address space to be larger than the physical address space.
Incorrect! Try again.
15What is Demand Paging?
A.Loading all pages of a process before execution starts.
B.Loading a page into memory only when it is needed.
C.Swapping the entire process out to the disk.
D.Requesting pages from the kernel manually.
Correct Answer: Loading a page into memory only when it is needed.
Explanation:Demand paging is a strategy where pages are loaded into memory only when they are accessed (demanded) during program execution, rather than utilizing prepaging.
Incorrect! Try again.
16A Page Fault occurs when:
A.A process tries to access a page that is not currently in memory.
B.A process tries to access a protected memory area.
C.The TLB is full.
D.The page table is corrupted.
Correct Answer: A process tries to access a page that is not currently in memory.
Explanation:A page fault is an interrupt that occurs when a program attempts to access a page that is mapped in the logical address space but is not loaded in physical memory (marked invalid).
Incorrect! Try again.
17What is Belady's Anomaly?
A.Effective access time increases as the TLB hit ratio increases.
B.For some page replacement algorithms, the page-fault rate may increase as the number of allocated frames increases.
C.The CPU utilization decreases as the degree of multiprogramming increases.
D.Internal fragmentation increases as page size decreases.
Correct Answer: For some page replacement algorithms, the page-fault rate may increase as the number of allocated frames increases.
Explanation:Belady's Anomaly is the phenomenon where increasing the number of page frames results in an increase in the number of page faults for certain algorithms (specifically FIFO).
Incorrect! Try again.
18Which page replacement algorithm suffers from Belady's Anomaly?
A.LRU (Least Recently Used)
B.Optimal Replacement
C.FIFO (First-In, First-Out)
D.Stack Algorithms
Correct Answer: FIFO (First-In, First-Out)
Explanation:FIFO is the standard example of an algorithm that suffers from Belady's Anomaly. Stack algorithms like LRU and Optimal do not.
Incorrect! Try again.
19The Optimal Page Replacement algorithm replaces the page that:
A.Was brought in last.
B.Has been used least recently.
C.Will not be used for the longest period of time.
D.Has been used most frequently.
Correct Answer: Will not be used for the longest period of time.
Explanation:The Optimal algorithm replaces the page that will not be used for the longest period of time. This guarantees the lowest possible page-fault rate but is difficult to implement because it requires future knowledge.
Incorrect! Try again.
20The LRU (Least Recently Used) page replacement algorithm is based on the assumption that:
A.Pages used recently will likely be used again soon.
B.Pages brought in first are the least needed.
C.Pages used frequently should be replaced.
D.Future access patterns are random.
Correct Answer: Pages used recently will likely be used again soon.
Explanation:LRU replaces the page that has not been used for the longest period of time, operating on the principle of locality: pages used recently are likely to be used again.
Incorrect! Try again.
21What is the concept of Thrashing?
A.A condition where the CPU is idle because processes are busy swapping pages in and out.
B.A security breach in the paging system.
C.The process of compacting memory.
D.Rapid execution of short processes.
Correct Answer: A condition where the CPU is idle because processes are busy swapping pages in and out.
Explanation:Thrashing occurs when a process spends more time paging (swapping pages in and out) than executing. This usually happens when the degree of multiprogramming is too high and processes don't have enough frames.
Incorrect! Try again.
22The Working Set Model is used to:
A.Calculate the size of the Page Table.
B.Prevent Thrashing by estimating the frame requirements of a process.
C.Determine the optimal page size.
D.Manage disk scheduling.
Correct Answer: Prevent Thrashing by estimating the frame requirements of a process.
Explanation:The Working Set Model is based on the assumption of locality. It tracks the set of pages a process is currently using (the working set) to ensure the process is allocated enough frames to avoid thrashing.
Incorrect! Try again.
23In a Multi-level Paging scheme, the page table itself is:
A.Stored in the TLB.
B.Paged.
C.Segmented.
D.Compressed.
Correct Answer: Paged.
Explanation:In Multi-level paging, the page table is too large to fit in one contiguous block of memory, so the page table itself is paged. The outer page table maps to inner page tables.
Incorrect! Try again.
24What is the main advantage of Overlays?
A.It eliminates internal fragmentation.
B.It allows a process to be larger than the amount of memory allocated to it.
C.It speeds up disk I/O.
D.It simplifies the Operating System code.
Correct Answer: It allows a process to be larger than the amount of memory allocated to it.
Explanation:Overlays allow a process to be larger than the amount of memory allocated to it by keeping only the instructions and data that are needed at any given time in memory. This is usually managed by the user/programmer, not the OS.
Incorrect! Try again.
25Which bit in a page table entry indicates whether a page has been written to since it was loaded into memory?
A.Valid/Invalid bit
B.Dirty (Modify) bit
C.Reference bit
D.Protection bit
Correct Answer: Dirty (Modify) bit
Explanation:The Dirty bit (or Modify bit) is set when a page is written to. If the dirty bit is set, the page must be written back to the disk (backing store) when it is replaced.
Incorrect! Try again.
26If the Page Table Base Register (PTBR) contains the base address of the page table, and the page number is , the entry for page is found at:
A.
B.
C.
D.
Correct Answer:
Explanation:The address of the page table entry is calculated by adding the page number () scaled by the size of a page table entry to the base address stored in the PTBR.
Incorrect! Try again.
27In Segmentation with Paging, how is memory managed?
A.Segments are variable sized, and pages are fixed size.
B.The logical address space is segmented, and the segments are paged.
C.Pages are segmented into frames.
D.Memory is treated as a flat file.
Correct Answer: The logical address space is segmented, and the segments are paged.
Explanation:In Segmentation with Paging (e.g., Intel Pentium), the linear address space is divided into segments, but to avoid external fragmentation and manage large segments efficiently, the segments themselves are divided into pages.
Incorrect! Try again.
28Calculate the effective access time (EAT) if the memory access time is 100ns, the TLB access time is 20ns, and the TLB hit ratio is 80%. (Assume no page faults).
A.120 ns
B.140 ns
C.132 ns
D.100 ns
Correct Answer: 140 ns
Explanation:
Incorrect! Try again.
29What is the purpose of the Valid-Invalid bit in a page table?
A.To lock the page in memory.
B.To indicate if the page is read-only.
C.To indicate if the page is in the process's logical address space and currently in memory.
D.To count the number of accesses.
Correct Answer: To indicate if the page is in the process's logical address space and currently in memory.
Explanation:The Valid-Invalid bit indicates whether the page is valid (in the logical address space and in memory) or invalid (not in the address space or currently swapped out).
Incorrect! Try again.
30Which of the following creates a separation between user logical memory and physical memory?
A.Direct Memory Access (DMA)
B.Virtual Memory
C.Cache Coherence
D.Instruction Pipelining
Correct Answer: Virtual Memory
Explanation:Virtual memory involves the separation of logical memory as perceived by users from physical memory. This allows an extremely large virtual memory to be provided for programmers when only a smaller physical memory is available.
Incorrect! Try again.
31In the context of the Second-Chance (Clock) page replacement algorithm, what is the role of the Reference bit?
A.It marks the page as dirty.
B.It gives a page a 'second chance' to stay in memory if it was recently used.
C.It indicates the page is invalid.
D.It is used to calculate the physical address.
Correct Answer: It gives a page a 'second chance' to stay in memory if it was recently used.
Explanation:In the Second-Chance algorithm, if the reference bit is 0, the page is replaced. If it is 1, the bit is cleared (set to 0), the page is given a second chance, and the pointer moves to the next page.
Incorrect! Try again.
32What happens in a system using Pure Demand Paging when a process first starts?
A.All pages are loaded immediately.
B.The OS crashes.
C.Execution starts with no pages in memory, causing immediate page faults.
D.The process waits for the swapper.
Correct Answer: Execution starts with no pages in memory, causing immediate page faults.
Explanation:In Pure Demand Paging, never bring a page into memory until it is required. The process starts with no pages in memory, so the first instruction causes a page fault.
Incorrect! Try again.
33The 50% rule in memory allocation states that:
A.50% of memory is wasted by internal fragmentation.
B.Given allocated blocks, another blocks will be lost to external fragmentation.
C.Page tables take up 50% of memory.
D.The OS occupies 50% of RAM.
Correct Answer: Given allocated blocks, another blocks will be lost to external fragmentation.
Explanation:Statistical analysis of the First-fit algorithm indicates that, generally, given allocated blocks, another blocks will be lost to external fragmentation (one-third of memory may be unusable).
Incorrect! Try again.
34When does Internal Fragmentation become zero?
A.When using First-fit.
B.When using Variable Partitioning.
C.When using Paging.
D.When using Fixed Partitioning.
Correct Answer: When using Variable Partitioning.
Explanation:In Variable Partitioning (contiguous allocation), memory is allocated exactly to the size of the process (plus overhead), so there is no unused space inside the partition. It suffers from External Fragmentation instead.
Incorrect! Try again.
35Which structure helps in solving the problem of large page tables in a 64-bit address space by using a hash of the virtual page number?
A.Hierarchical Page Table
B.Inverted Page Table
C.Hashed Page Table
D.TLB
Correct Answer: Hashed Page Table
Explanation:A Hashed Page Table is often used for address spaces larger than 32 bits. The virtual page number is hashed into a page table that contains a chain of elements.
Incorrect! Try again.
36What is the primary feature of an Inverted Page Table?
A.It has one entry for each virtual page of the process.
B.It has one entry for each real physical frame of memory.
C.It is stored on the disk.
D.It uses segmentation.
Correct Answer: It has one entry for each real physical frame of memory.
Explanation:An Inverted Page Table has one entry for each real physical frame (frame-centric), rather than one entry for each logical page (process-centric). This decreases memory needed for the page table.
Incorrect! Try again.
37Which of the following statements about Swapping is true?
A.Swapping is very fast and has no performance overhead.
B.The context switch time in swapping is dominated by the transfer time of the backing store.
C.Swapping can only be done between RAM and Cache.
D.Swapping eliminates the need for virtual memory.
Correct Answer: The context switch time in swapping is dominated by the transfer time of the backing store.
Explanation:Swapping involves moving entire processes between memory and a backing store (disk). The transfer time is significant and usually dominates the total context switch time.
Incorrect! Try again.
38In the context of the MFU (Most Frequently Used) page replacement algorithm, the argument is that:
A.The page with the smallest count was just brought in and has yet to be used.
B.The page with the largest count was just brought in.
C.Old pages are better.
D.Random pages should be removed.
Correct Answer: The page with the smallest count was just brought in and has yet to be used.
Explanation:MFU argues that the page with the smallest count was just brought in and has yet to be used, so we should replace the one with the largest count (Most Frequently Used).
Incorrect! Try again.
39Logical address is also known as:
A.Physical Address
B.Real Address
C.Virtual Address
D.Hard Address
Correct Answer: Virtual Address
Explanation:A logical address is generated by the CPU and is also referred to as a virtual address.
Incorrect! Try again.
40If a system has a 32-bit logical address and a 4 KB page size, how many entries are in a single-level page table?
A.
B.
C.
D.
Correct Answer:
Explanation:Page size is 4 KB = bytes. The offset is 12 bits. The remaining bits for the page number are . Therefore, there are entries (1 million).
Incorrect! Try again.
41Which memory management scheme allows the user to view memory as a collection of variable-sized logic units (e.g., main, stack, symbol table)?
A.Paging
B.Segmentation
C.Contiguous Allocation
D.Hashing
Correct Answer: Segmentation
Explanation:Segmentation supports the user view of memory. A program is a collection of segments like main program, procedure, function, stack, variables, etc.
Incorrect! Try again.
42In a Paged Segmentation system (like MULTICS), the external fragmentation is eliminated by:
A.Paging the segments.
B.Making segments fixed size.
C.Using a single large segment.
D.Using Compaction.
Correct Answer: Paging the segments.
Explanation:In paged segmentation, the segments are divided into pages. Since pages are fixed-size and fit into frames, external fragmentation is eliminated (though internal fragmentation may exist in the last page of a segment).
Incorrect! Try again.
43What is the frame table?
A.A table mapping logical pages to frames for a specific process.
B.A system-wide data structure detailing which frames are free and which are allocated.
C.A table stored in the L1 Cache.
D.A list of all segments.
Correct Answer: A system-wide data structure detailing which frames are free and which are allocated.
Explanation:The OS maintains a system-wide frame table that contains details about physical memory: which frames are free, which are allocated, and to which process.
Incorrect! Try again.
44Which of the following creates a 'hole' in memory during contiguous allocation?
A.Process termination
B.Process creation
C.Context switching
D.Interrupt handling
Correct Answer: Process termination
Explanation:When a process terminates, it releases its memory, creating a block of available memory, commonly referred to as a hole.
Incorrect! Try again.
45The time required to service a page fault includes:
A.Only the disk read time.
B.Service the page-fault interrupt, Read in the page, Restart the process.
C.Only the process restart time.
D.Context switch time only.
Correct Answer: Service the page-fault interrupt, Read in the page, Restart the process.
Explanation:The effective access time with page faults includes three major components: servicing the page-fault interrupt, reading the page from disk (swap in), and restarting the process.
Incorrect! Try again.
46What is Global Replacement in page replacement algorithms?
A.A process selects a replacement frame from the set of all frames in the system.
B.A process selects a replacement frame only from its own set of allocated frames.
C.Replacing all pages in memory at once.
D.Replacing pages based on global time.
Correct Answer: A process selects a replacement frame from the set of all frames in the system.
Explanation:Global replacement allows a process to select a replacement frame from the set of all frames, even if that frame is currently allocated to another process.
Incorrect! Try again.
47Which of the following is NOT a benefit of Virtual Memory?
A.More programs can run concurrently.
B.Less I/O is needed to load or swap programs.
C.CPU utilization is increased.
D.It eliminates the need for a hard disk.
Correct Answer: It eliminates the need for a hard disk.
Explanation:Virtual Memory relies heavily on the hard disk (backing store) to hold pages that are not currently in physical RAM. It does not eliminate the need for it.
Incorrect! Try again.
48In Two-Level Paging, the logical address is divided into:
Explanation:In a two-level paging scheme, the page number is subdivided. The address is (outer page directory), (inner page table), and (offset).
Incorrect! Try again.
49Reentrant code (pure code) in paging allows:
A.Self-modifying code.
B.Sharing of common code among processes.
C.Writing to the code segment.
D.Dynamic linking.
Correct Answer: Sharing of common code among processes.
Explanation:Reentrant code is non-self-modifying code. If the code is reentrant, it can be shared among multiple processes (e.g., text editors, compilers) using shared pages, saving memory.
Incorrect! Try again.
50Which algorithm requires a counter or stack to track the age of pages?
A.FIFO
B.LRU
C.Optimal
D.Random
Correct Answer: LRU
Explanation:To implement LRU, hardware support is needed in the form of a counter (clock) or a stack to keep track of when each page was last used.
Incorrect! Try again.
Give Feedback
Help us improve by sharing your thoughts or reporting issues.