Toolkit for Micro-Benchmarking of Assembly Basic Blocks on Modern CPU Architectures

Alexander Batashev · 2023

Performance modeling is crucial for compiler optimizations, yet existing cost models often suffer from inaccuracies and limited applicability across different architectures. This paper introduces an automated open-source toolkit designed to improve the accuracy of cost models for basic blocks in assembly code. We propose an LLVM-based method for efficient basic block extraction, overcoming the limitations of existing dynamic tracing tools. Our toolkit also includes a robust profiling tool that benchmarks basic blocks across multiple architectures, ensuring minimal measurement variance. Additionally, we present a dataset construction tool that converts basic blocks into graph-based representations, suitable for deep learning models like Graph Neural Networks. Our contributions pave the way for more accurate and versatile performance models, thereby enhancing compiler optimizations.

Read the paper · More papers on PaperTik