From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <96079341819698.tru64-unix-managers.marc@archive.invalid> From: Franc Carter Date: Wed, 22 Mar 2000 23:06:38 +0000 To: tru64-unix-managers Subject: pthread_create_problem X-MARC-Message: https://marc.info/?l=tru64-unix-managers&m=96079341819698 We are having a problem with pthread_create(). Thread creation fails if we try to create a thread when we the process is bigger than about 512M. The vm-mapentries on the machine is set to 32768. The machine has 2GB of ram. An example piece of code that fails is below. Any suggestions and/or an explanation of how vm-mapentries affects the system would be appreicated. thanks =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D #include #include #include #include void *test (void *arg) { return NULL; } int main () { pthread_t thread; int i; assert (malloc (512*1024*1024)); i =3D pthread_create (&thread, NULL, test, NULL); if (i=3D=3DENOMEM) printf ("Out of memory\n"); return i; } --=20 Franc Carter MEMLab, University of Sydney Ph: 61-2-9351-7819 Fax: 9351-6461