Make Bounds

Encoding

EncodingOperand 1Operand 2
rmModRM.reg[w]ModRM.r/m

Description

The BNDMK instruction makes lower and upper bounds from the source operand's effective address. The result is stored in the destination register. At no time is memory accessed.

Which instruction form is used depends on the operating mode of the processor. In 16-bit and 32-bit modes, the 32-bit form is used. In 64-bit mode, the 64-bit form is used.

Operation

public void BNDMK_Sib(Bound dest, Sib addr)
{
    dest.Lower = addr.Base;
    dest.Upper = ~lea(addr);
}

Flags Affected

None.

Intrinsics

Exceptions

Real-Address Mode

#UD
  • If the LOCK prefix is used.
  • If 16 bit addressing is used, or 32 or 64 bit addressing is used, but without an SIB byte (rm is not 100b).
  • If a register operand encodes BND4 through BND7.

Virtual-8086 Mode

#UD
  • If the LOCK prefix is used.
  • If 16 bit addressing is used, or 32 or 64 bit addressing is used, but without an SIB byte (rm is not 100b).
  • If a register operand encodes BND4 through BND7.

Protected Mode

#UD
  • If the LOCK prefix is used.
  • If 16 bit addressing is used, or 32 or 64 bit addressing is used, but without an SIB byte (rm is not 100b).
  • If a register operand encodes BND4 through BND7.

Compatibility Mode

#UD
  • If the LOCK prefix is used.
  • If 16 bit addressing is used, or 32 or 64 bit addressing is used, but without an SIB byte (rm is not 100b).
  • If a register operand encodes BND4 through BND7.

Long Mode

#UD
  • If the LOCK prefix is used.
  • If 16 bit addressing is used, or 32 or 64 bit addressing is used, but without an SIB byte (rm is not 100b).
  • If a register operand encodes BND4 through BND7.