os202

Repository for Operating Systems 202 Course 2020/2021

View project on GitHub

HOME
« PREVIOUS | | NEXT »

Top 10 List of Week 04

  1. What is Memory Management?
    Memory Management is the process of controlling and coordinating computer memory, assigning portions known as blocks to various running programs to optimize the overall performance of the system. It is the most important function of an operating system that manages primary memory. It helps processes to move back and forward between the main memory and execution disk. It helps OS to keep track of every memory location, irrespective of whether it is allocated to some process or it remains free.

  2. First, Best & Worst Fit Allocation Methods
    When there is more than one partition freely available to accommodate a process’s request, a partition must be selected. To choose a particular partition, a partition allocation method is needed. A partition allocation method is considered better if it avoids internal fragmentation. When it is time to load a process into main memory and if there is more than one free block of memory of sufficient size then the OS decide which free block to allocate. There are different Placement Algorithm: First Fit, Best Fit, Worst Fit, and Next Fit.

  3. Contiguous Memory Allocation
    Contiguous memory allocation is a memory allocation method that allocates a single contiguous section of memory to a process or a file. This method takes into account the size of the file or a process and also estimates the maximum size. Taking into account the future growth of the file and its request for memory, the operating system allocates sufficient contiguous memory blocks to that file. Considering this future expansion and the file’s request for memory, the operating system will allocate those many contiguous blocks of memory to that file.

  4. What is Swapping?
    Swapping is one of the several methods of memory management. Swapping is a mechanism in which an idle or blocked process can be swapped temporarily out of main memory (or move) to secondary storage (disk) and make that memory available to other processes. At some later time, the system swaps back the process from the secondary storage to main memory. Though performance is usually affected by swapping process but it helps in running multiple and big processes in parallel.

  5. What is Fragmentation?
    In a computer storage system, as processes are loaded and removed from memory, the free memory space is broken into small pieces. In this way memory space used inefficiently, so the capacity or performance of the system may degrade. The conditions of the fragmentation depend on the system of memory allocation. In most of the cases, memory space is wasted. Sometimes it happens that memory blocks cannot be allocated to processes due to their small size and memory blocks remain unused. This problem is known as Fragmentation.

  6. Paging in Operating System
    In Operating Systems, Paging is a storage mechanism used to retrieve processes from the secondary storage into the main memory in the form of pages. The main idea behind the paging is to divide each process in the form of pages. The main memory will also be divided in the form of frames. One page of the process is to be stored in one of the frames of the memory. The pages can be stored at the different locations of the memory but the priority is always to find the contiguous frames or holes. Pages of the process are brought into the main memory only when they are required otherwise they reside in the secondary storage.

  7. Page Table Entries
    Page Table is a data structure used by the virtual memory system to store the mapping between logical addresses and physical addresses. Page table has page table entries where each page table entry stores a frame number and optional status (like protection) bits. Many of status bits used in the virtual memory system. The most important thing in PTE is frame Number.

  8. Segmentation in Operating System
    Segmentation is a memory management technique in which each job is divided into several segments of different sizes, one for each module that contains pieces that perform related functions. Each segment is actually a different logical address space of the program. When a process is to be executed, its corresponding segmentation are loaded into non-contiguous memory though every segment is loaded into a contiguous block of available memory. Segmentation memory management works very similar to paging but here segments are of variable-length where as in paging pages are of fixed size.

  9. Logical vs Physical Addressing
    We have two types of addresses that are logical address and physical address. The logical address is a virtual address and can be viewed by the user. The user can’t view the physical address directly. The logical address is used like a reference, to access the physical address. The fundamental difference between logical and physical address is that logical address is generated by CPU during a program execution whereas, the physical address refers to a location in the memory unit.

  10. Difference Between Loading & Linking
    Linking and Loading are the utility programs that play a important role in the execution of a program. Linking intakes the object codes generated by the assembler and combines them to generate the executable module. On the other hand, the loading loads this executable module to the main memory for execution.
    Loading: Bringing the program from secondary memory to main memory is called Loading.
    Linking: Establishing the linking between all the modules or all the functions of the program in order to continue the program execution is called linking.