MS-DOS 6.22 MEM /C Command Explained
In MS-DOS 6.22, managing the strict 640 KB conventional memory limit
is vital for running memory-intensive programs and games. The
MEM command paired with the /C (classify)
switch provides a detailed breakdown of how the system's memory is
currently allocated among active programs and drivers. This article
explains the specific function of the MEM /C command, the
data it outputs, and how it is used to optimize system memory
configurations.
Purpose of the /C Switch
The /C switch stands for "classify." When appended to
the standard MEM command, it instructs MS-DOS to group and
display all programs, device drivers, and system modules currently
loaded into memory. Unlike the basic MEM command—which only
provides high-level totals of free and used memory—the /C
switch reveals exactly which software components are consuming those
resources.
Information Provided by MEM /C
When you run MEM /C, the command outputs a structured
table containing the following details:
- Module Name: The name of each loaded program, TSR
(Terminate and Stay Resident utility), or device driver (such as
HIMEM.SYSorCOMMAND.COM). - Total Size: The total amount of memory consumed by each module, displayed in both decimal bytes and hexadecimal format.
- Conventional Memory: The specific amount of standard 640 KB conventional memory used by each program.
- Upper Memory: The amount of Upper Memory Blocks (UMBs) utilized between 640 KB and 1 MB, if Upper Memory is enabled.
Beneath the program list, MEM /C prints a comprehensive
summary showing:
- Total, used, and free conventional memory.
- Total, used, and free upper memory.
- Extended (XMS) and expanded (EMS) memory statistics.
- The size of the largest executable program that can currently run in conventional memory.
- The largest free block available in the Upper Memory Area.
Role in Memory Optimization
The primary function of MEM /C is to assist with manual
and automated memory optimization:
- Identifying Memory Hogs: It allows users to pinpoint TSRs and drivers that occupy large chunks of conventional memory.
- Relocating to Upper Memory: By checking the exact
size of a driver via
MEM /C, users can determine whether that driver will fit into available Upper Memory Blocks using theDEVICEHIGHdirective inCONFIG.SYSor theLOADHIGH(LH) command inAUTOEXEC.BAT. - Evaluating MemMaker Results: It serves as a
verification tool to check the results after running the MS-DOS
automated optimization tool,
MEMMAKER.
Practical Usage
Because the list generated by MEM /C typically exceeds
the standard 25-line DOS display, it is commonly paired with the
/P (pause) switch:
MEM /C /P
This halts the screen after each full page of output, allowing you to review the memory layout without it scrolling off the screen.