C/C++ Compiler (cl.hlp) (Table of Contents; Topic list)
Medium Memory Model: Details
                                             Up Contents Index Back
─────C/C++ Compiler─────────────────────────────────────────────────────────
 
     Syntax:  /AM
 
     The medium-model option allows a single segment for program data
     and multiple segments for program code. Each source module is
     given its own code segment.
 
     Medium-model programs can have more than 64K of code but less than
     64K of data. Program code can occupy any amount of space and is
     given as many segments as needed. Total program data cannot be
     greater than 64K.
 
     The defaults in medium-memory programs are far code addressing
     and near data addressing. You can override the defaults with the
     __near keyword for code and the __far or __huge keyword for data.
     See: Overriding Default Addressing
 
     Using the /AM option causes CL to emit both the _M_I86 and the
     _M_I86MM preprocessor identifiers.
                                    -♦-