计算机科学 > 机器学习
[提交于 2022年2月10日]
标题:Learning Branch Probabilities in Compiler from Datacenter Workloads
查看原文 PDF 中文 PDF (下批处理) EasyResearch 阅读摘要:Estimating the probability with which a conditional branch instruction is taken is an important analysis that enables many optimizations in modern compilers. When using Profile Guided Optimizations (PGO), compilers are able to make a good estimation of the branch probabilities. In the absence of profile information, compilers resort to using heuristics for this purpose. In this work, we propose learning branch probabilities from a large corpus of data obtained from datacenter workloads. Using metrics including Root Mean Squared Error, Mean Absolute Error and cross-entropy, we show that the machine learning model improves branch probability estimation by 18-50% in comparison to compiler heuristics. This translates to performance improvement of up to 8.1% on 24 out of a suite of 40 benchmarks with a 1% geomean improvement on the suite. This also results in greater than 1.2% performance improvement in an important search application.
提交历史
来自:Easwaran Raman[v1] 2022年2月10日 星期四 12:59:49 UTC