gentooLTO icon indicating copy to clipboard operation
gentooLTO copied to clipboard

BOLT'ing Gentoo For Greater Performance

Open sheerluck opened this issue 4 years ago • 3 comments

https://twitter.com/search?q=bolt%20llvm

sheerluck avatar Jan 14 '22 07:01 sheerluck

From what I can gather, this needs a profiling stage, just like PGO. That means that the package would have to be built twice, and between the first and second build a test suite should be ran to generate the profiling data that BOLT and PGO rely on.

Portage doesn't have support to do this easily, especially since many projects don't come with (good) test suites that can be ran on everyone's machines. As such, I expect this to become a USE flag for specific packages in the long run, but nothing that can just be applied to everything in the system.

mid-kid avatar Jan 16 '22 19:01 mid-kid

Think I'm gonna take up this task, looked through the LLVM BOLT guide and it's pretty straightforward. I'd have to create an overlay and setup the BOLTing part for each pkg (gcc, clang etc.). Then we'd have to add that to the README.

Would this be something that could be approved by the maintainer? @InBetweenNames

svetlyr avatar Mar 31 '23 11:03 svetlyr

Just to note: BOLT usually uses a lot of RAM. Also, for the best results you need to have hardware with LBR (or BRS) support - in this case, perf reports bring more information to BOLT.

Would be really helpful to check opened BOLT issues in LLVM repo. Recently, I've created a bunch of them :) Also, could be helpful to check AutoFDO (with PROPELLER extension) - they share kinda similar to BOLT ideas and approaches.

zamazan4ik avatar Apr 24 '23 23:04 zamazan4ik