Profile data for instructions (e.g., branch weights) is automatically preserved via `splice()` which moves the basic blocks along with their instruction metadata. However, entry count is stored as function metadata, which was dropped when creating merged function and thunks. The fix is to explicitly set entry count for both merged function (.Tgm) and thunks via `setEntryCount()`.
22 KiB
22 KiB