摘要 |
A method and mechanism for performing an unconditional stack switch in a processor. A processor includes a processing unit coupled to a memory. The memory is configured to include a plurality of stacks, a special mode task state segment, and a descriptor table including a number of descriptors. The processor is configured to detect interrupts and access a descriptor corresponding to the interrupt within the descriptor table. Each of the descriptors in the descriptor table includes an index corresponding to entries in an interrupt stack table within the task state segment. Subsequent to accessing the descriptor corresponding to the interrupt, the processor is configured to access the index within the descriptor in order to determine whether or not an interrupt stack table mechanism is enabled. In response to detecting the interrupt stack table mechanism is enabled, the index is used to select an entry in the interrupt stack table. The selected entry in the interrupt stack table indicates a stack pointer which is then used to perform an unconditional stack switch.
|