[vtkusers] Memory allocation problems under Python wrapped VTK in Windows

John Drescher drescherjm at gmail.com
Fri Jan 16 15:36:57 EST 2009


>> Is this a problem of memory fragmentation?
>>
>>   Jim
>
> No it seems not to be as I can execute that non-VTK program and Python
> wrapped VTK code in any which order and the result is always the same.
>
It better be. However I do not believe that makes a difference to your
situation. Every program gets its own clean address space when you
execute it.

As far as address space fragmentation, unless you use the /3GB flag
and link with LARGE_ADDRESS_AWARE the maximum single allocation I have
found in windows programs ( compiled with VS and no VTK) is around
1.2GB. The reason is that windows loads its dlls inside of the same
2GB of address space that you are allocating memory from so this
reduces the maximum size of the block you can allocate. Running python
probably makes this worse by the python dlls being loaded at even
lower addresses than the windows dlls.

John



More information about the vtkusers mailing list