Utilizing Intel® AVX with Cakewalk SONAR X1

This is a whitepaper (Utilizing Intel® AVX with Cakewalk SONAR X1) which I co-authored with Intel engineer Rajshree Chabukswar, highlighting the advantages of optimizing for the Intel AVX chipset, with a focus on digital audio processing in a modern DAW like SONAR X1.

We’re excited with our synergetic relationship with Intel, which allows us to take  advantage of their bleeding edge technology in ways that directly beneft our users, allowing them to squeeze the most power out of their systems. While the paper is technical and requires an understanding of some low level programming, it also offers insight into the nuts and bolts of whats involved in optimizations for Intel CPU architectures in a modern DAW.

The paper features a real world case study of SONAR X1 code that was optimized in to take advantage of the benefits of the 256 bit AVX instruction set. If you have an Intel CPU from the Sandy Bridge processor family, it supports AVX and SONAR X1 will take advantage of it.
(While AVX is an Intel instruction set, it has also been adopted by AMD will be available in their upcoming Bulldozer processors. )

Code which is optimized for AVX  vectorization capabilities can work with 256-bit vectors, allowing working on 8 32-bit floating point values per iteration. In other words, this is twice the data throughput of earlier SSE instruction set! While this doesn’t necessarily translate to twice as fast, it is a huge step up in performance in many cases as the white paper illustrates.

The first step in any optimization task is what is referred to as “hotspot analysis”. In this phase you identify the bottlenecks in the code or that would benefit most from AVX optimization. We did analysis running through stress test projects and workflows that showed some classic hotspots. Once these were identified, the code was AVX optimized using the new AVX intrinsics available in Visual Studio 2010.

Click below to read the paper or download the PDF from Intel’s site:
Utilizing Intel® AVX with Cakewalk SONAR X1

[ Additional credits to Keith Albright and Bob Currie from Cakewalk, for hotspot analysis, development, and troubleshooting ]

A case for 64 bit Windows

With 64 bit computers becoming mainstream (its hard to find a machine thats not 64 bit capable these days) the question being asked more often is “Should I install a 64 bit operating system or a 32 bit operating system?” While the advantages of a 64 bit OS might be more obvious for those running native 64 bit software, or those who have a need for more than 2GB of memory, its a bit more murky as to whether regular 32 bit applications will also perform well on a 64 bit OS.

A 64 bit capable processor has an increased number of registers, as well as an improved floating point unit (FPU) design with double the number of FPU registers. 64 bit operating systems can take advantages of the expanded register set available to a 64 bit processor. The advantages to this are fewer memory accesses for data that can be stored in registers, leading to faster execution of computationally intensive processes. You can read more about this from this Cakewalk X64 white paper from several years ago.

Here is an interesting benchmark showing that 64 bit windows can perform better even with the same hardware and software. Some of the benchmarks are relevant to digital audio processing as well and so apply to DAW users.

Windows Vista Benchmark: 64-Bit Faster Than 32-Bit

A Closer Look at 32-Bit vs. 64-Bit Windows