DOCERR: MASM 5.1 Instructions Operand Size Documented Wrong

Last reviewed: November 3, 1994
Article ID: Q67439
The information in this article applies to:
  • Microsoft Macro Assembler for MS-DOS, versions 5.0, 5.1, and 5.1a
  • Microsoft Macro Assembler for OS/2, versions 5.1 and 5.1a

In the "Microsoft Macro Assembler 5.1 Reference" manual, a number of instructions indicate that their operand size is a mem64 when they should indicate an operand size of mem48. The instructions are documented incorrectly as LGDT, LIDT, LLDT, SGDT, SIDT, and SLDT. These instructions require the FWORD PTR operator and not the QWORD PTR operator. If the QWORD PTR operator is used, the Microsoft Macro Assembler (MASM) will generate the following warning:

   warning A4057: illegal size for operand

These instructions are privileged 286 and 386 instructions that are used to load and save the protected mode descriptor table registers. These registers are only 6 bytes long, even though descriptor table entries are normally 8 bytes.


Additional reference words: 5.00 5.10 5.10a
KBCategory: kbprg kbdocerr
KBSubcategory: MASMLngIss


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: November 3, 1994
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.