Advantages of memory segmentation:
- Allow the memory capacity to be 1 MB even though the addresses associated with the individual instructions are 16 bits wide.
- Allow the use of separate memory areas for the program code and data and stack portion of the program.
- Permit a program and/or its data to be placed into different areas of memory whenever the program is end.
- Multitasking becomes easy
- The advantage of having separate code and data segments is that one program can work on different sets of data This is possible by reloading the data segment register (DS) to the point to the new data.
- The advantage of segment memory is that the reference logical addressed can be loaded into the instruction pointer (IP) and run the program anywhere in the segment memory as the logical address varies from 0000H to FFFFH.
- Programs are re-locatable so that programs can be run at any location in the memory.
Disadvantages of memory segmentation:
- External fragmentation is present
- Costly memory management algorithms.
- Segmentation finds free memory area big enough.
- Paging keep list of free pages.
- Segments of unequal size not suited as well for swapping.