C/C++ Compiler (cl.hlp) (Table of Contents; Topic list)
Optimize Entry/Exit Code for Protected-Mode Windows (/GA)
                                             Up Contents Index Back
─────C/C++ Compiler─────────────────────────────────────────────────────────
 
     Syntax:  /GA
              /GD
 
     For protected-mode Windows applications, use the /GA option to
     optimize the entry/exit code of all far functions explicitly
     marked as __export.
     See: Make far Functions __export
          Conflicts Between __fastcall and Windows Entry/Exit Code
 
     For Windows dynamic-link libraries (DLLs) designed for protected
     mode, use the /GD option to optimize the entry/exit code of all
     far functions explicitly marked as __export.
 
     When used instead of either the /GW or the /Gw option, both the
     /GA option and the /GD option save 10 bytes and 7 instructions for
     each function call. For /GA, use of __export adds an additional 6
     bytes and 4 instructions to a function call; /GD with __export
     adds an additional 6 bytes and 7 instructions to a function call.
     The code generated in all four cases is smaller than that
     generated by /Gw or /GW. Note that in all four cases, you can also
     use the generate 80286 code option (/G2) to save an additional 4
     bytes.
 
     Both the /GA and /GD options define the _WINDOWS constant, and the
     /GD option defines the _WINDLL constant. The /GA option specifies
     use of both mLIBCfW.LIB and the Windows API library. The /GD
     option specifies use of both mDLLCfW.LIB and the Windows API
     library. You cannot specify the /Gw, /GW, or /Gq options with
     either the /GA or the /GD options.
                                    -♦-