"Maurice LING" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi, > > I think I've hit a system limit in python when I try to construct a list > of 200,000 elements. My error is > > malloc: vm_allocate (size = 2400256) failed...... > > Just wondering is this specific to my system or what? Will adding more RAM > helps in this case? > > Thanks and cheers > Maurice
malloc (which is the memory manager Python uses when it runs out of its own heap memory) is trying to get another 2.4 megabyte block of memory from the operating system so it can expand the heap. The operating system is refusing to fill the request. There are a lot of reasons why this might happen, ranging from system limits (too little swap space, too little real memory), to an inability to find a 2.4 meg block in the user part of the address space, etc. I'd check swap space, and then balance redesigning the application to not try to get large blocks of memory with spending money on more hardware memory that might not solve the problem. John Roth -- http://mail.python.org/mailman/listinfo/python-list