This patch provides the following infrastructure to enable the use of PGO in inliner:
- Enable the use of block level profile information in inliner
- Incremental update of block frequency information during inlining
- Update the function entry counts of callees when they get inlined into callers.
This is pretty much re-implementing a tiny part of the new pass manager inside the inline cost analysis. That really feels like the wrong approach to me. Notably, this is even named exactly the same as we would want to name a port of BlockFrequencyInfo to the new pass manager.
I don't agree with this approach. Fundamentally, this is not the right long-term design for how the inliner should access profile information, and it actually obstructs getting the right design in place.