Published on

What are the differences between paging and segmentation?

Authors

Paging and segmentation are very crucial techniques to ensure smooth performance of large systems while not burning the servers.

Image

🔹 Paging Paging is a memory management scheme that eliminates the need for contiguous allocation of physical memory. The process's address space is divided into fixed-size blocks called pages, while physical memory is divided into fixed-size blocks called frames.

The address tranlation process works in 3 steps:

  1. Logical Address Space: The logical address (generated by the CPU) is divided into a page number and a page offset.
  2. Page Table Lookup: The page number is used as an index into the page table to find the corresponding frame number.
  3. Physical Address Formation: The frame number is combined with the page offset to form the physical address in memory.

Advantages:

  • Eliminates external fragmentation.
  • Simplifies memory allocation.
  • Supports efficient swapping and virtual memory.

🔹 Segmentation Segmentation is a memory management technique where the memory is divided into variable-sized segments based on the logical divisions of a program, such as functions, objects, or data arrays.

The address tranlation process works in 3 steps:

  1. Logical Address Space: The logical address consists of a segment number and an offset within that segment.
  2. Segment Table Lookup: The segment number is used as an index into the segment table to find the base address of the segment.
  3. Physical Address Formation: The base address is added to the offset to form the physical address in memory.

Advantages:

  • Provides logical separation of different parts of a program.
  • Facilitates protection and sharing of segments.
  • Simplifies management of growing data structures.

Author

AiUTOMATING PEOPLE, ABN ASIA was founded by people with deep roots in academia, with work experience in the US, Holland, Hungary, Japan, South Korea, Singapore, and Vietnam. ABN Asia is where academia and technology meet opportunity. With our cutting-edge solutions and competent software development services, we're helping businesses level up and take on the global scene. Our commitment: Faster. Better. More reliable. In most cases: Cheaper as well.

Feel free to reach out to us whenever you require IT services, digital consulting, off-the-shelf software solutions, or if you'd like to send us requests for proposals (RFPs). You can contact us at [email protected]. We're ready to assist you with all your technology needs.

ABNAsia.org

© ABN ASIA

AbnAsia.org Software