[Numpy-discussion] code performanceon windows (32 and/or 64 bit) using SWIG: C++ compiler MS vs.cygwin
Thu Mar 12 04:11:31 CDT 2009
Sebastian Haase wrote:
> On Thu, Mar 12, 2009 at 4:39 AM, David Cournapeau <firstname.lastname@example.org> wrote:
>> On Thu, Mar 12, 2009 at 12:38 PM, David Cournapeau <email@example.com> wrote:
>>> and you can't
>>> cross compile easily.
>> Of course, this applies to numpy/scipy - you can cross compile your
>> own extensions relatively easily (at least I don't see why it would
>> not be possible).
> Thanks for the reply.
> I actually don't have easy access to the MS compiler.
The MS compilers are available freely - the trick is to get the PSDK
which contains the free compilers targeting 64 bits (Visual studio
express does not include 64 bits targeting compilers). AFAIK, no 64 bits
hosted compiler is available freely. So the situation is that you get
the 32 bits compilers binaries which run on windows 64 bits through WoW
and which target 64 bits. It is easier than it sounds :)
You have to be careful with the versions:
- python 2.5 -> use compiler version 14 (that is VS 2005 -> 64 bits
freely available through PSDK 6.0)
- python 2.6 -> use compiler version 15 (that is VS 2008 -> 64 bits
freely available through PSDK 6.1(a))
> David, will you be making 64bit binary versions of numpy+scipy available ?
Numpy, yes. For scipy, I have yet managed to build it successfully:
neither C++ nor Fortran GNU compiler runs well. I have no access to a
non free fortran compiler on windows 64 bits.
And anyway, it will be experimental; in particular, I won't distribute
the corresponding toolchain, and the mingw project does not distribute a
native toolchain either (you would have to build it yourself). So if you
can limit yourself to numpy, you are better of with MS compilers for now
> Cross compiling .... I have never done that: I suppose it's an
> addition option to "g++" and having extra libraries somewhere, right ?
Yes - it is easy for your own extensions, I would like numpy to be
cross-compilable, because the free cross compilers (windows 32 bits
hosted -> targeting 64 bits) are much more stable than the natives ones.
The natives ones do not work well for the moment (both g++ and gfortran
segfault or worse). The problem is that most projects which use
mingw-w64 can cross compile (from linux or mac os X) easily through
autoconf, so people do not care so much about the native compilers.
More information about the Numpy-discussion