Please note that the content of this book primarily consists of articles
available from Wikipedia or other free sources online. For example, on
the 16-bit x86 platform, six memory models exist. They control what
assumptions are made regarding the segment registers, and the default
size of pointers. Four registers are used to refer to four segments on
the 16-bit x86 segmented memory architecture. DS, CS, SS, and ES. A
logical address on this platform is written segment:offset, in
hexadecimal. In real mode, in order to calculate the physical address of
a byte of memory, one left-shifts the contents of the appropriate
register 4 bits, and then adds the offset.Far pointers contain the new
value of DS or CS within them. To use them the register must be changed,
the memory dereferenced, and then the register restored. They may
reference up to 1 megabyte of memory. Note that pointer arithmetic does
not modify the segment portion of the pointer, only its offset.
Operations which exceed the bounds of zero or 65535 will undergo modulo
64K operation just as any normal 16 bit operation.