RLIMIT_AS maximum is 2GB

Jan Edler (edler@research.nj.nec.com)
Tue, 2 Mar 1999 23:34:58 -0500


With all the discussion about the tradeoff between physical memory
size and maximum virtual memory size awhile back, I was surprised to
find that the RLIMIT_AS (address space) limit is about 2GB,
and it doesn't seem possible for a process to get more VM than that.

The essence of the problem is that the rlimit_cur and rlimit_max
members of struct rlimit are simply type "long" and for size-oriented
limits (like RLIMIT_AS) they count bytes. So, the most you can have
is 0x7fffffff. So my questions:

1) Am I missing something?

2) Is there a solution for machines where sizeof(long)==4?

One approach would be to make RLIMIT_AS work in units of KB.
The only objection I can think of, is that it would then differ
from the other size-oriented limits, and that would be a bad thing.

3) If the AS limit is going to stay this way, why bother with the standard
#define __PAGE_OFFSET (0xC0000000) in <asm-i386/page.h>? I don't see
any reason not to just let it be 0x80000000 all the time.

Please CC me in reply, as I follow the list only through archives.

Jan Edler
edler@research.nj.nec.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/