MEMSIZE System Option: Windows

Specifies the limit on the amount of virtual memory that can be used during a SAS session.

Valid in: configuration file, SAS invocation
Category: System Administration: Memory
PROC OPTIONS GROUP= MEMORY
Default: 2G
Windows specifics: valid values

Syntax

-MEMSIZE n | nK | nM | nG | nT | hexX | MAX

Required Arguments

n | nK | nM | nG | nT

specifies the limit in bytes, kilobytes (1024 bytes), megabytes (1,048,576 bytes), gigabytes (1,073,741,824 bytes), or terabytes (1,099,511,627,776 bytes). For example, a value of 0.25G is equivalent to 268,435,456 bytes, and 16.5M is equivalent to 17,301,504 bytes.

hexX

specifies the amount of memory as a hexadecimal value. You must specify the value beginning with a number (0–9), followed by hexadecimal characters (0–9, A-F), and then followed by an X. For example, 0F00000x sets the value of the MEMSIZE option to 15,728,640 bytes, which is equivalent to a value of 0x

MAX

specifies the largest reasonable value dependent on the amount of physical memory and paging space available when SAS is started.

Details

The MEMSIZE system option specifies the total amount of memory available to each SAS session. A value that is too low results in out-of-memory conditions.
A numeric value of 0 (or 0x) is equivalent to the option value MAX.
If an unreasonably small numeric value is specified (for example, 6K), the setting of the MEMSIZE option is silently increased to a minimum reasonable value that allows SAS to start and have basic functionality.
If a numeric value greater than 4,294,967,295 is specified on a 32-bit version of SAS, the setting of the value is silently reduced to 4,294,967,295.
Numeric values greater than 9,223,372,036,854,775,807 bytes is rejected as invalid, and prevents SAS from starting.
SAS does not automatically reserve or allocate the amount of memory that you specify in the MEMSIZE system option. SAS uses only as much memory as it needs to complete a process. For example, a DATA step might require only 20M of memory, so even though MEMSIZE is set to 500M, SAS uses only 20M of memory.
While your SAS jobs are running, you can monitor the effect of larger memory settings by using system monitoring tools.
Note: Setting MEMSIZE to MAX is reasonable only if consumers of large amounts of memory are not likely to become active after SAS has started. For example, if multiple instances of SAS are running concurrently, and all of these instances are started with a MEMSIZE value of MAX, one or more of these instances can encounter out of memory conditions, or, the operating system can run out of available paging space.