[PATCH] D141931: [BOLT] Consider Code Fragments during regreassign

hezuoqiang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 8 17:07:34 PDT 2023


hzq added a comment.

In D141931#4570722 <https://reviews.llvm.org/D141931#4570722>, @rafauler wrote:

> Thanks! LGTM with some modifications I made to the test file available here: https://pastebin.com/3abP1S5G
>
> I modified the test to fail if the optimization is applied just to main, but not to main.cold, and vice-versa. Please commit this version. I also used basic block labels when generating FDATA instead of hardcoded offsets, so the test is resilient to changes in it. I further modified main.cold to be a global symbol, so the symbol is not stripped when we run llvm-strip. We do need to run llvm-strip because I'm not declaring bb labels as temp symbols anymore (.L1 <https://reviews.llvm.org/L1>, etc), in order to use their names when generating fdata. That's the way we usually write the tests  (function names are globals, bb names are locals but non-temp so we don't need to hardcode fdata).

Thanks very much for your assistance. It has been a great help to me.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D141931/new/

https://reviews.llvm.org/D141931



More information about the llvm-commits mailing list