Which of the following memory management techniques divides memory into fixed-size blocks?
A Virtual Memory
B Segmentation
C Paging
D Swapping
Paging divides the memory into fixed-size blocks called pages. It allows the operating system to use memory more efficiently by allocating space for processes in non-contiguous blocks, preventing fragmentation.
In which memory management technique is each process divided into segments based on the logical divisions of the program?
A Virtual Memory
B Segmentation
C Paging
D Swapping
Segmentation divides a program into logical segments such as code, data, and stack. Each segment can vary in size, unlike paging, which uses fixed-sized blocks. This improves memory organization and management.
What is the primary goal of virtual memory in an operating system?
A Efficient Memory Utilization
B Process Synchronization
C Process Isolation
D Real-Time Scheduling
Virtual memory enables efficient memory utilization by allowing the system to use disk space to simulate extra RAM. It extends the memory available for processes, allowing large applications to run even on systems with limited physical memory.
Which of the following best describes the role of the operating system in memory management?
A Handling Interrupts
B Scheduling CPU Tasks
C Running Programs
D Managing Memory Allocation
The operating systemโs memory manager allocates and deallocates memory to processes. It ensures that each process has sufficient memory and handles memory protection, preventing unauthorized access to memory spaces.
What does fragmentation in memory management refer to?
A Wasted Memory Space
B Incomplete Process Execution
C Inconsistent Data Storage
D Process Termination
Fragmentation occurs when memory is allocated and deallocated in such a way that free memory is scattered in small, non-contiguous blocks. This results in inefficient memory usage and can limit the space available for new processes.
What is the benefit of using demand paging in virtual memory?
A Reduce CPU Load
B Memory Protection
C Load Pages Only When Needed
D Faster Process Execution
Demand paging is a technique where only the pages that are needed by a process are loaded into memory. This improves efficiency by reducing the amount of memory used and delaying loading until necessary.
What is a page fault in the context of virtual memory?
A Request for Non-existent Data
B Failure to Find a Page in Memory
C Memory Overflow
D Memory Access Violation
A page fault occurs when a program attempts to access a page in memory that is not currently in RAM. The operating system must then load the page from disk into memory to satisfy the request, which can cause a delay.
Which of the following is a disadvantage of segmentation in memory management?
A External Fragmentation
B Increased Page Faults
C Internal Fragmentation
D Memory Overhead
Segmentation can lead to external fragmentation, where free memory is scattered in small chunks, preventing larger memory blocks from being allocated. This can reduce the overall efficiency of memory usage.
What does the term “swapping” mean in memory management?
A Memory Protection
B Process Isolation
C Efficient Memory Allocation
D Moving Processes Between Memory and Disk
Swapping is a memory management technique where processes are moved between the RAM and disk storage. When the system runs low on memory, less important processes are swapped out to disk, making room for more critical processes.
Which operating system component is responsible for managing virtual memory?
A Process Manager
B Device Drivers
C Kernel
D File System
The kernel is responsible for managing virtual memory. It handles the allocation and swapping of memory pages between RAM and disk, ensuring that processes have the memory resources they need while managing system performance.
What does the term “address space” refer to in virtual memory?
A Range of Memory Addresses a Process Can Access
B Total Storage Space Available
C Amount of Physical RAM
D The Space Reserved for OS
Address space refers to the range of memory addresses that a process can use in virtual memory. The operating system ensures that each process accesses only its designated address space to prevent interference with other processes.
What is the role of the Translation Lookaside Buffer (TLB) in virtual memory?
A Cache Recently Used Page Entries
B Handle Interrupts
C Track Process States
D Manage Physical Memory
The Translation Lookaside Buffer (TLB) is a hardware cache that stores the most recently used virtual-to-physical page mappings. It speeds up memory access by reducing the need to frequently access the page table.
In virtual memory, what happens when a process accesses data not currently in RAM?
A Page Fault
B Cache Miss
C Segmentation Fault
D Process Termination
When a process accesses data not currently in RAM, a page fault occurs. The operating system must then load the required data from disk into RAM to satisfy the request, which may cause a delay.
Which of the following is a disadvantage of using paging in memory management?
A Increased Disk Space Usage
B Reduced Memory Access Speed
C Complex Process Management
D External Fragmentation
Paging can reduce memory access speed because it involves looking up the page table to map virtual addresses to physical ones. This extra step can introduce overhead, especially when dealing with large amounts of memory.
What is the primary advantage of using segmentation over paging?
A Reduced CPU Overhead
B No Fragmentation
C Logical Division of Memory
D More Efficient Memory Usage
Segmentation allows for a logical division of memory based on the program’s structure, such as separating the code, data, and stack. This makes it easier to manage large programs, as each segment can grow or shrink independently.