[BOLT] Track fragment info for all split fragments
authorFabian Parzefall <parzefall@fb.com>
Thu, 25 Aug 2022 01:07:06 +0000 (18:07 -0700)
committerFabian Parzefall <parzefall@fb.com>
Thu, 25 Aug 2022 01:07:09 +0000 (18:07 -0700)
commit9b6e7861aeb9a951a520e41aa4fa3fc2a38b5b36
treea78ff33eacfc2997a95404ddfa6b7ec685ed259a
parent07f63b0ac5c530c808420971734b36b8fa79e687
[BOLT] Track fragment info for all split fragments

To generate all symbols correctly, it is necessary to record the address
of each fragment. This patch moves the address info for the main and
cold fragments from BinaryFunction to FunctionFragment, where this data
is recorded for all fragments.

Reviewed By: rafauler

Differential Revision: https://reviews.llvm.org/D132051
bolt/include/bolt/Core/BinaryFunction.h
bolt/include/bolt/Core/FunctionLayout.h
bolt/lib/Core/BinaryFunction.cpp
bolt/lib/Core/FunctionLayout.cpp
bolt/lib/Profile/BoltAddressTranslation.cpp
bolt/lib/Rewrite/RewriteInstance.cpp