News for hackers. Stuff that matters.
Re:Pillow-SIMD: improving the performance of image processing by dalke on Friday May 13, 2016 @02:24PM (#11692210)
In practice, it's very hard to make Python's distutils do this. I tried to figure it out years ago, see http://stackoverflow.com/questions/15527611/how-do-i-specify... . I also asked on the distutils list. No one had a clean solution.

The best solution I have is to interpose my own "CC", which looks at what is being compile and adds the correct compiler options for the right files before calling the real compiler. This is hacky and inflexible.

Re:Pillow-SIMD: improving the performance of image processing by wiredfool on Friday May 13, 2016 @02:50PM (#11692413)
I'm curious how scpiy and numpy manage it. I'm pretty sure that they have solved some of this before.
Re:Pillow-SIMD: improving the performance of image processing by tavert on Friday May 13, 2016 @03:39PM (#11692733)
Entirely handled by the underlying BLAS library, OpenBLAS and MKL have this feature but few if any other libraries do. I believe FFTW has something similar, but scipy doesn't use FFTW.
Re:Pillow-SIMD: improving the performance of image processing by dalke on Friday May 13, 2016 @03:14PM (#11692580)
In my short search, I didn't see evidence that either package has run-time dispatch based on the processor type.

I don't see "cpuid" used in the scipy code base, and the only intrinsic I found is specifically in a MS Windows #ifdef.

Numpy doesn't use cpuid. It does have compile-time options for intrinsics, but not run-time.