In this article there is an introductionary look into the vDSP and vecLib libraries which are part of the Accelerate framework on Mac OS X. By using properly aligned arrays and manually vectorized code you can increase the performance (5-10 times) of your hot loops by large amounts.
I habe been using the Accelerate framework for some time now, and i can only strongly advice people who are hungry for high performance code to use it.
Its a marvel of design, really easy to use. Also the beauty of this thing is that it just works on both powerpc and x86. It hides completely the underlying hardware, you just don’t need to care on what architecture you code will run, the framework will do all the optmization job relative to vector prgramming for the given architecture and does it extremely well. If you code is universal, well it will optmize for both for each binary out of the box. Nothing else to do, just concentrate on your code.
And in terms of performance, it can really puch your computing intensive code to very high performance, very often giving you two digits increasing factor. Now that the intel chips have a “real” vector unit with true 128 bits path, the Accelarate franework will also give all its potentiel on Intel.
Really great technology……
Too bad that there is no cross-platform equivalent of it
Er… what about Intel IPP (Integrated Performance Primitives) for Mac, Linux and Windows?
http://www.intel.com/cd/software/products/asmo-na/eng/302910.htm
They don’t work on PPC. That’s the whole beauty of vecLib – it’s CPU independent.