C/C++ Compiler (cl.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
Generate Entry/Exit Code for Real-Mode Windows Functions (/Gw)
                                             Up Contents Index Back
─────C/C++ Compiler─────────────────────────────────────────────────────────
 
     Syntax:  /Gw
              /GW
 
     Use the /Gw option when compiling real-mode Windows modules
     containing far functions marked as __export. The /Gw option
     instructs the compiler to generate entry/exit code sequences for
     real-mode Windows call-back functions.
 
     Use the /GW option when compiling real-mode Windows modules
     containing only functions not marked as __export. The /GW option
     is similar to the /Gw option, but generates a more efficient entry
     sequence for real-mode windows functions that are not call-back
     functions.
 
     See the Tools manual included in the Microsoft Windows Software
     Development Kit documentation for more information. Both options
     define the _WINDOWS constant, declared in the Windows version of
     STDIO.H.
 
     NOTE:  The /GW option has been improved for Microsoft C/C++. Use
            the /Gq option if you need the entry/exit code generated
            by previous versions of /GW.
            See: /Gq
 
     The /GA, /GD, and /GE options perform entry/exit code that will
     run only under standard- or enhanced-mode Windows. Use of these
     options can save up to 10 bytes and 7 instructions for each
     function call.
     See: /GA /GD /GE
          Conflicts Between __fastcall and Windows Entry/Exit Code
                                    -♦-