Explain the differences between Paging and segmentation.
Paging and segmentation
Paging
|
Segmentation
|
Computer memory is separated into small partitions which are all similar size and considered to as, page frames. Then while a process is loaded this gets divided in pages that are similar size as those earlier frames. The process pages are after that loaded in the frames.
|
Memory-management scheme which supports user vision of memory.
Computer memory is allocated in different sizes (as segments) depending upon the required for address space through the process.
|
Address generated through CPU is divided into:
Page number (p) - It used like an index in a page table that contains base address of each page into physical memory.
Page offset (d) - It combined with base address to describe the physical memory address which is sent to the
memory unit.
|
Logical address contains a two tuple:
< segment-number, offset >
|
Transparent to programmer (i.e. system
allocates memory)
|
Includes programmer (i.e. allocates memory to
specific function inside code)
|
No separate- the protection
|
To separate the protection
|
No separate- the compiling
|
To separate the compiling
|
No shared-the code
|
To share the code
|