STI             Set Interrupt Enable Flag            Flags: O D I T S Z A P C
- - 1 - - - - - -
STI IO

Logic IF ← 1

STI sets the interrupt-enable flag (IF). After executing the
instruction following STI, the CPU responds to external
interrupts, but only if the next instruction allows the interrupt
flag to remain enabled.

If external interrupts are disabled and you code STI,RET (such as
at the end of a subroutine), the RET is allowed to execute before
external interrupts are recognized. Also, if external interrupts
are disabled and you code STI,CLI, then external interrupts are
not recognized because the CLI instruction clears the interrupt
flag during its execution.

Non-maskable interrupts are recognized no matter what the state of
the IF flag.

Protected mode
If the current task has insufficient privilege to alter IF, a
general protection exception is generated.


Opcode Format
FB STI


Length and timing
Operands Bytes 8088 186 286 386 486 Pentium
- 1 2 2 2 3 5 7 NP