Extended performance accounting using Valgrind tool

Modern workloads, parallel or sequential, usually suffer from insufficient memory and computing performance. Common trends to improve workload performance include the utilizations of complex functional units or coprocessors, which are able not only to provide accelerated computations but also indepe...

Повний опис

Збережено в:
Бібліографічні деталі
Дата:2021
Автори: Rahozin, D.V., Doroshenko, A.Yu.
Формат: Стаття
Мова:English
Опубліковано: Інститут програмних систем НАН України 2021
Назва видання:Проблеми програмування
Теми:
Онлайн доступ:http://dspace.nbuv.gov.ua/handle/123456789/180666
Теги: Додати тег
Немає тегів, Будьте першим, хто поставить тег для цього запису!
Назва журналу:Digital Library of Periodicals of National Academy of Sciences of Ukraine
Цитувати:Extended performance accounting using Valgrind tool / D.V. Rahozin, A.Yu. Doroshenko // Проблеми програмування. — 2021. — № 2. — С. 54-62. — Бібліогр.: 12 назв. — англ.

Репозитарії

Digital Library of Periodicals of National Academy of Sciences of Ukraine
id irk-123456789-180666
record_format dspace
institution Digital Library of Periodicals of National Academy of Sciences of Ukraine
collection DSpace DC
language English
topic Інструментальні засоби і середовища програмування
Інструментальні засоби і середовища програмування
spellingShingle Інструментальні засоби і середовища програмування
Інструментальні засоби і середовища програмування
Rahozin, D.V.
Doroshenko, A.Yu.
Extended performance accounting using Valgrind tool
Проблеми програмування
description Modern workloads, parallel or sequential, usually suffer from insufficient memory and computing performance. Common trends to improve workload performance include the utilizations of complex functional units or coprocessors, which are able not only to provide accelerated computations but also independently fetch data from memory generating complex address patterns, with or without support of control flow operations. Such coprocessors usually are not adopted by optimizing compilers and should be utilized by special application interfaces by hand. On the other hand, memory bottlenecks may be avoided with proper use of processor prefetch capabilities which load necessary data ahead of actual utilization time, and the prefetch is also adopted only for simple cases making programmers to do it usually by hand. As workloads are fast migrating to embedded applications a problem raises how to utilize all hardware capabilities for speeding up workload at moderate efforts. This requires precise analysis of memory access patterns at program run time and marking hot spots where the vast amount of memory accesses is issued. Precise memory access model can be analyzed via simulators, for example Valgrind, which is capable to run really big workload, for example neural network inference in reasonable time. But simulators and hardware performance analyzers fail to separate the full amount of memory references and cache misses per particular modules as it requires the analysis of program call graph. We are extending Valgrind tool cache simulator, which allows to account memory accesses per software modules and render realistic distribution of hot spot in a program. Additionally the analysis of address sequences in the simulator allows to recover array access patterns and propose effective prefetching schemes. Motivating samples are provided to illustrate the use of Valgrind tool.
format Article
author Rahozin, D.V.
Doroshenko, A.Yu.
author_facet Rahozin, D.V.
Doroshenko, A.Yu.
author_sort Rahozin, D.V.
title Extended performance accounting using Valgrind tool
title_short Extended performance accounting using Valgrind tool
title_full Extended performance accounting using Valgrind tool
title_fullStr Extended performance accounting using Valgrind tool
title_full_unstemmed Extended performance accounting using Valgrind tool
title_sort extended performance accounting using valgrind tool
publisher Інститут програмних систем НАН України
publishDate 2021
topic_facet Інструментальні засоби і середовища програмування
url http://dspace.nbuv.gov.ua/handle/123456789/180666
citation_txt Extended performance accounting using Valgrind tool / D.V. Rahozin, A.Yu. Doroshenko // Проблеми програмування. — 2021. — № 2. — С. 54-62. — Бібліогр.: 12 назв. — англ.
series Проблеми програмування
work_keys_str_mv AT rahozindv extendedperformanceaccountingusingvalgrindtool
AT doroshenkoayu extendedperformanceaccountingusingvalgrindtool
first_indexed 2023-10-18T22:50:32Z
last_indexed 2023-10-18T22:50:32Z
_version_ 1796156575648317440
spelling irk-123456789-1806662021-10-14T01:26:25Z Extended performance accounting using Valgrind tool Rahozin, D.V. Doroshenko, A.Yu. Інструментальні засоби і середовища програмування Modern workloads, parallel or sequential, usually suffer from insufficient memory and computing performance. Common trends to improve workload performance include the utilizations of complex functional units or coprocessors, which are able not only to provide accelerated computations but also independently fetch data from memory generating complex address patterns, with or without support of control flow operations. Such coprocessors usually are not adopted by optimizing compilers and should be utilized by special application interfaces by hand. On the other hand, memory bottlenecks may be avoided with proper use of processor prefetch capabilities which load necessary data ahead of actual utilization time, and the prefetch is also adopted only for simple cases making programmers to do it usually by hand. As workloads are fast migrating to embedded applications a problem raises how to utilize all hardware capabilities for speeding up workload at moderate efforts. This requires precise analysis of memory access patterns at program run time and marking hot spots where the vast amount of memory accesses is issued. Precise memory access model can be analyzed via simulators, for example Valgrind, which is capable to run really big workload, for example neural network inference in reasonable time. But simulators and hardware performance analyzers fail to separate the full amount of memory references and cache misses per particular modules as it requires the analysis of program call graph. We are extending Valgrind tool cache simulator, which allows to account memory accesses per software modules and render realistic distribution of hot spot in a program. Additionally the analysis of address sequences in the simulator allows to recover array access patterns and propose effective prefetching schemes. Motivating samples are provided to illustrate the use of Valgrind tool. Сучасні паралельні або послідовні програми-навантаження (workloads) звичайно мають обмеження за швидкодією процесора або запотужністю каналів пам’яті. Також сучасною тенденцією є залучення спеціалізованих сопроцесорів для підвищення швидкодії програм-навантажень, які виконують не тількі обчислення, але й доступ до пам’яті зі складною адресацією. Такі сопроцесори практично неможливо використати за допомогою компілятора, лише ручним кодуванням програми. Обмеження за потужністю каналу пам’яті також може вирішуватися складною системою передвибірки даних з пам’яті у кеш-пам’ять процесора, але компілятор теж може оптимізувати передвибірку лише у простих випадках побудови коду. Оскільки програми-навантаження дуже швидко мігрують у бік вбудованих обчислень, виникає проблема спрощення використання вбудованих сопроцесорів для підвищення швидкодії. Це потребує аналізу послідовностей доступу до пам’яті та визначення вузьких місць у коді програми. Точний аналіз доступу можливий за допомогою симуляторів, наприклад Valgrind, який дозволяє аналізувати великі програми-навантаження, наприклад, вивід у нейромережах і за адекватний час. Наявні симулятори та засоби аналізу навантаження процесора не дозволяють коректно визначати навантаження у прив’язці до програмних компонентів, оскільки це потребує аналізу графу викликів у програмі. Тому ми розширюємо симулятор Valgrind можливостями аналізу прив’язки доступу до пам’яті до конкретних програмних модулів і визначенням уточнених вузьких місць доступу до пам’яті. Додатково аналіз послідовності адрес доступу до пам’яті дозволяє визначати шаблони доступу до масивів і рекомендувати використання певних алгоритмів передвибірки даних до кеш-пам’яті. Додаються ілюстративні приклади використання симулятора Valgrind. 2021 Article Extended performance accounting using Valgrind tool / D.V. Rahozin, A.Yu. Doroshenko // Проблеми програмування. — 2021. — № 2. — С. 54-62. — Бібліогр.: 12 назв. — англ. 1727-4907 DOI: https://doi.org/10.15407/pp2021.02.054 http://dspace.nbuv.gov.ua/handle/123456789/180666 681.3 en Проблеми програмування Інститут програмних систем НАН України