Sunday, 15 January 2012

c - openMP and how to check cache behavior parallelism -


I am parallelizing the loops in my code to customize it using openmp

I've heard that openmp also shows some good or bad cache behavior - how do I see these cache interactions to arrange good cache behavior for my openmp omp pragma loop program?

OpenMP can not be used to obtain information about the cache usage of your program Depending on your platform, there are some tools that will give insight into cache behavior.

On the Linux system you can use.

perf stat -e cache-context, cash-milliseconds & lt; Your-exe & gt;

Statistics about cash-mirrors show that too many incidents can be used (see for more information). Common occurrences are collected if you just run:

perf stat & lt; Your-exe & gt;

Another device that can be used for Windows even though it only works with Intel CPUs, then collect additional information such as supported memory bandwidth (on supported models) Could.

However, the tools can help you measure your program's cache usage, but it did not improve. You need to manually optimize your code and check again that the cache reduction has been reduced.


No comments:

Post a Comment