[PATCH] gas: sframe: partially process DWARF expressions in CFI_escape
Indu Bhagat
indu.bhagat@oracle.com
Sat Feb 1 01:15:53 GMT 2025
On 1/29/25 9:11 AM, Jens Remus wrote:
> On 28.01.2025 01:57, Indu Bhagat wrote:
>> CFI_escape is most commonly used to include DWARF expressions in the
>> unwind information. One may also use CFI_escape to add OS-specific CFI
>> opcodes. Up until now, SFrame generation process would skip generating
>> SFrame FDE at the mere sight of a CFI_escape opcode.
>>
>> Fine tune the handling of CFI_escape for SFrame generation by explicitly
>> checking for some "harmless" (in context of SFrame generation)
>> CFI_escape DWARF expressions:
>> - DW_CFA_expression affecting non SP/FP registers
>> - DW_CFA_value_expression affecting non SP/FP registers.
>
> Could that be extended to also process the CFI instructions already
> supported by SFrame, such as e.g. DW_CFA_val_offset through
> sframe_xlate_do_val_offset()?
>
We could invoke sframe_xlate_do_val_offset (), we will just have to
craft a new struct cfi_insn_data object just for checking the register...
What is the opinion on copying the necessary conditional into
sframe_xlate_do_expr () for DW_CFA_val_offset ?
> On s390 Glibc for instance uses .cfi_escape to piece together
> .cfi_val_offset due to minimum binutils release requirements.
>
More information about the Binutils
mailing list