Some Instructions May Require Enabling of Instruction Set

Last reviewed: January 23, 1995
Article ID: Q47504
The information in this article applies to:
  • Microsoft Macro Assembler for MS-DOS and OS/2, versions 5.0, 5.1, 5.1a, 6.0, 6.0a, and 6.0b

SUMMARY

Using an instruction that requires a 80186, 80286, or 80386 processor may cause the Microsoft Macro Assembler (MASM) 5.1 to generate the one of the following errors:

   A2066: Must have instruction after prefix.
   A2105: Expected: instruction, directive, or label

and MASM 6.0 to generate the following error:

   A2085: instruction or register not accepted in current CPU mode

The error occurs because the default assembly mode is 8086. The .186, .286, .286p, .386, or .386p directive must be placed in the source code prior to any instructions that require those modes.

In addition, MASM 6.0 supports 80486 instructions.

MORE INFORMATION

The following information is taken from page 621 of the "Microsoft Macro Assembler Programmer's Guide" for MASM 6.0

80186 Processor Instructions

   BOUND        INSW         OUTSW
   ENTER        LEAVE        POPA
   INS          OUTS         PUSHA
   INSB         OUTSB        PUSHW*

80286 Processor Instructions

   ARPL         SIDT         VERR
   LAR          SLDT         VERW
   LSL          SMSW
   SGDT         STR

80286 and 80386 Privileged-Mode Instructions

   CLTS         LIDT         LMSW
   LGDT         LLDT         LTR

80386 Processor Instructions

   BSF          LSS          SETNAE
   BSR          MOVSD        SETNB
   BT           MOVSX        SETNBE
   BTC          MOVZX        SETNC
   BTR          OUTSD        SETNE
   BTS          POPAD        SETNG
   CDQ          POPFD        SETNGE
   CMPSD        PUSHAD       SETNL
   CWDE         PUSHD*       SETNLE
   INSD         PUSHFD       SETNO
   IRETD        SCASD        SETNP
   IRETDF*      SETA         SETNS
   IRETF*       SETAE        SETNZ
   JECXZ        SETB         SETO
   LFS          SETBE        SETP
   LGS          SETC         SETPE
   LODSD        SETE         SETPO
   LOOPD*       SETG         SETS
   LOOPED*      SETGE        SETZ
   LOOPNED*     SETL         SHLD
   LOOPNZD*     SETLE        SHRD
   LOOPZD*      SETNA        STOSD

80486 Processor Instructions

   BSWAP*       INVD*        WBINVD*
   CMPXCHG*     INVLPG*      XADD*

   * New to MASM 6.0


Additional reference words: kbinf 5.00 5.10 5.10a 6.00 6.00a 6.00b
KBCategory: kbtool
KBSubCategory: MLIss


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: January 23, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.