Skip to content

Commit 655aca4

Browse files
yozhugithub-actions[bot]
authored andcommitted
Automerge: [BOLT] Don't check address past end of function for data/code marker annotation (#159210)
We want to annotate function with data and code markers whose addresses fall within the range of the function, so setting `CheckPastEnd` to false.
2 parents 5203f28 + 5923004 commit 655aca4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

bolt/lib/Rewrite/RewriteInstance.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1312,7 +1312,9 @@ void RewriteInstance::discoverFileObjects() {
13121312

13131313
// Annotate functions with code/data markers in AArch64
13141314
for (auto &[Address, Type] : MarkerSymbols) {
1315-
auto *BF = BC->getBinaryFunctionContainingAddress(Address, true, true);
1315+
auto *BF = BC->getBinaryFunctionContainingAddress(Address,
1316+
/*CheckPastEnd*/ false,
1317+
/*UseMaxSize*/ true);
13161318

13171319
if (!BF) {
13181320
// Stray marker

0 commit comments

Comments
 (0)