We use Codee to identify opportunities to increase memory efficiency through Loop Interchange, taking advantage of sequential memory access patterns and favoring efficient vectorization. Why is Loop Interchange important? Loop interchange is a performance optimization technique that is used to improve the loop’s memory access pattern and potentially enable vectorization. Loop interchange if applied correctly […]
vectorization
Flexibility and Performance: turbocharging loop unswitching
In the previous post we talked about loop unswitching: a technique that the compilers use to make loops faster. Loop unswitching consists of detecting conditional statements whose condition never changes during the execution of the loop (loop invariant conditions) and then moving the condition outside of the loop. Loop unswitching opens the door for other […]
Many ways to speed up your program
There are many approaches to make your program run faster. Some approaches are based on using more efficient libraries, others rely on using the standard library and the language in an efficient manner. Other approaches include using more efficient algorithms. But sometimes, even after we’ve applied all the possible optimizations, the code performance is not […]
Speed up non-vectorizable loops with loop fission
Vectorization is a powerful technique for achieving peak computational performance. However, not all code is easily vectorizable by all compilers. In this post we are going to talk about vectorization of complex non-vectorizable loops. The idea is to split the loop into two loops, one for the vectorizable part and the other for the non-vectorizable […]
Is your algorithm running at peak performance? The roofline model
There are worlds where performance matters. For example HPC world: faster software means less wait time for the scientists. Embedded world: faster software means we can use cheaper silicon to build our product. Game world: faster software means that our game will run on slower CPUs, thus making our game more interesting to people with […]