[llvm] [BOLT] Update LSDA encoding for x86-64 large code model (PR #190685)

Maksim Panchenko via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 6 15:02:36 PDT 2026


maksfb wrote:

> These section names are convention but they are steeped across the tooling so they are effectively ABI. Reading the x86-64 ABI https://gitlab.com/x86-psABIs/x86-64-ABI/-/tree/master?ref_type=heads (you can find latest PDF there) mentions `.ltext` as "Additional Special Sections for the Medium and Large Code Models"

I'm trying to understand if `.ltext` will always be there for large code model or only under certain conditions.

Additionally, in BOLT we'll need to support cases where the input was just barely under 2GB, but BOLT is adding more code and we need to switch to large code model. But that's an extra. For now we can focus on reliable detection of large code in the input.

Maybe we can check if any LSDA's on the input are encoded using 64 bits and enable large code model?
 

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


More information about the llvm-commits mailing list