[Numpy-discussion] Byte aligned arrays

Henry Gomersall heng@cantab....
Thu Dec 20 14:24:05 CST 2012


On Thu, 2012-12-20 at 21:13 +0100, Sturla Molden wrote:
> On 20.12.2012 21:03, Henry Gomersall wrote:
> 
> > Why is it important? (for my own understanding)
> 
> Because if CRT resources are shared between different CRT versions,
> bad 
> things will happen (the ABIs are not equivalent, errno and other
> globals 
> are at different addresses, etc.) Cython code tends to share CRT 
> resources with Python. For example, your Cython code might (invisibly
> to 
> us) invoke malloc to allocate space for an objent, and then Python
> will 
> later call free. This should perferably go through the same DLL.
> 
I understood the general point about it being bad, but it was more
specific to Cython, which I think you answered. Presumably it's less of
an issue with pure C libs where calls to libc are more obvious.

> Another thing is that msvcrt.dll is for Windows own system resources, 
> not for user apps.

I didn't know that. It's a real pain having so many libc libs knocking
around. I have little experience of Windows, as you may have guessed!

hen



More information about the NumPy-Discussion mailing list