Selecting and Accessing a Stack Segment


A stack segment is a form of data segment. Its descriptor must identify it as a read/writable segment so that the processor may perform both pushes (i.e., writes to the stack) and pops (i.e., reads from the stack). The descriptor also describes the stack type. A stack may be designated as an expand-up stack (the most common type; described in “Accessing the Stack Segment” on page 76) or an expand-down stack. A description of the expand-down stack can be found in the section entitled “Expand-Down Stack” on page 164. It should be noted that most OSs implement expand-up stacks.

Expand-Up Stack

The discussion that follows describes the operation of an expand-up stack (see Figure 9-6 on page 167 ...

Get The Unabridged Pentium 4 IA32 Processor Genealogy now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.