Command-line flag --max-mem-size sets the maximum value of
obtainable memory (including a very small amount of housekeeping
overhead). This cannot exceed 3Gb on 32-bit Windows, and most
versions are limited to 2Gb. The minimum is currently 32Mb.
If 32-bit R is run on most 64-bit versions of Windows the maximum
value of obtainable memory is just under 4Gb. For a 64-bit versions
of R under 64-bit Windows the limit is currently 8Tb.
Memory limits can only be increased.
R_MAX_MEM_SIZE provides another way to
specify the initial limit.