in kernel 2.2.15pre7, when declare a object larger than phisical mem, a
core dump will occure.
while on solaris 7, i can declare a object as large as 3x phisical mem
size. the SW &HW:
machine 1: ultra sparc + sun solaris 7 + 128M + 128M swap
machine 2: intel PII + 64M + 70M swap
i use the same test program (attashed) on each machine.
#include <stdio.h>
#include <string.h>
#define PHS_MEM (unsigned)(1<<26) /* 64M phisical memory */
/*
* Modify these lines for tests...
*/
#define BUFSIZE PHS_MEM
#define NEWSIZE PHS_MEM/64
char buf[BUFSIZE];
int main(int argc,char** argv)
{
int i;
char* p;
p=(char*)malloc(NEWSIZE);
if(!p){
perror("malloc");
exit(-1);
}
printf("%uM memory allocated at: %p\n",NEWSIZE>>20,p);
return 0;
}
-
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/
This archive was generated by hypermail 2b29 : Wed Feb 23 2000 - 21:00:20 EST