[llvm] Implements PGOBBAddrMap in Object and ObjectYAML with tests [1/5] (PR #71750)

Micah Weston via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 22 10:51:15 PST 2023


red1bluelost wrote:

> Thanks for addressing my concerns.
> 
> I wonder if there is any benefit in emitting the PGOAnalysis BB entries next to their BBAddrMap counterparts in the section. I see we are using the Metadata field to emit the successor type (used primarily for succinct decoding/encoding), but we probably shouldn't introduce this kind of coupling.
> 
> Here is an alternative: Emit the entire PGOAnalysisMap entry of each function right after its BBAddrMap (NBlocks and Feature are shared). Define and use your own fancy encoding for successor type and count.

Done. It now encoded PGOAnalysisMap after each BBAddrMap function if it was enabled in Features.

https://github.com/llvm/llvm-project/pull/71750


More information about the llvm-commits mailing list