You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
BOLT may never run the tentative code layout for cold BBs.
However, it might later require the addresses of cold BBs to compute
PC-relative jumps between hot and cold fragments of a function. Since
the addresses were never estimated, it uses 0x0 for cold BBs, resulting
in incorrect estimated addresses for any instructions within them.
As a result, LongJump often expands a branch that would otherwise fit in
a single instruction into a short jump.
For example, `relaxStub` might expand from:
```armasm
b .Ltmp1234
```
to:
```armasm
adrp x16, .Ltmp1234
add x16, x16, :lo12:.Ltmp1234
br x16
```
While this expansion is not wrong, it is unnecessary. Moreover, in some
large binaries this expansion has lead to runtime crashes. This should
be investigated further, as such expansions should not cause crashes.
0 commit comments