[RFC] Enhance Partial Inliner by using a general outlining scheme for cold blocks

Hello Graham,

We are also starting some work in the general direction of outlining/function splitting using profiling information. In our case, we are focusing on splitting functions into smaller parts to allow for a better code layout and thus better Icache/ITLB utilization.

It wasn’t clear to me from your description what type of subgraphs those cold regions would generate, and whether you would need to extend the code in CodeExtractor.h/FunctionCloner to support those.

Abdoul-kader keita,

Compiler Engineering @ Facebook, Inc

Thanks,

Hey Kader,

So I’m not sure what you mean by what type of subgraphs. The cold regions would be outlined into its own function (assuming single entry, single exit), and there could be multiple regions we outline from a single function. I currently have a prototype that can do this type of outlining without modifying the CodeExtractor, but the FunctionCloner needed some changes to track multiple outline functions and its corresponding in the parent function.

Graham Yiu
LLVM Compiler Development
IBM Toronto Software Lab
Office: (905) 413-4077 C2-707/8200/Markham
Email: gyiu@ca.ibm.com

graycol.gifkeita abdoul-kader via llvm-dev —08/25/2017 12:48:12 PM—Hello Graham, We are also starting some work in the general direction of