[llvm] [BOLT] Check if symbol is in data area of function (PR #160143)

Paschalis Mpeis via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 1 08:01:57 PDT 2025


https://github.com/paschalis-mpeis commented:

Hey Ash,

Thanks for the patch! Trying to understand the cases we hit this.

Is this the case where we fail on a symbol in a code-marked region
that follows a data marked region, like `L2` below?

```armasm
.text
.global foo
$d.foo:
foo:
        nop
$x.foo:
L2:
        ret
```

Maybe the below is a more realistic example than the above?
Note that replacing `BL` with a `B` does not trigger it.

```
.text
.global foo
foo:
        adrp    x0, .Lp
        add     x0, x0, :lo12:.Lp
        ldr     w0, [x0]
        bl L2
        ret
$d.L1:
.Lp:
        .word   0x123FFF
$x.L2:
L2:
        ret
```

https://github.com/llvm/llvm-project/pull/160143


More information about the llvm-commits mailing list