[PATCH] aarch64: s390: x86_64: sframe: adjust flex fde hook implementation

Indu Bhagat indu.bhagat@oracle.com
Wed Jan 21 21:41:31 GMT 2026


On 1/21/26 4:10 AM, Jens Remus wrote:
> On 1/21/2026 7:51 AM, Indu Bhagat wrote:
>> A previous commit added new backend hook sframe_support_flex_fde_p by
>> defining a new function for each backend that supports SFrame stack
>> trace format:
>>
>>    commit 2f9b3987db53d7e0606f89bfe2527dd3d0915568
>>    [SFrame-V3] gas: sframe: add new backend hook
>>    sframe_support_flex_fde_p for FLEX FDEs
>>
>> As pointed out in a review comment, simply providing the definition to
>> use true/false (as applicable) is sufficient for the purpose, and helps
>> generate better code.  So do that.
>> https://inbox.sourceware.org/binutils/80404871-53b4-4f5c-9d86-7a3a4d0a920e@suse.com/
>>
>> ChangeLog:
>> 	* gas/config/tc-aarch64.c (aarch64_support_flex_fde_p): Remove.
>> 	* gas/config/tc-aarch64.h (aarch64_support_flex_fde_p): Remove.
>> 	(sframe_support_flex_fde_p): Define to false.
>> 	* gas/config/tc-i386.c (x86_support_flex_fde_p): Remove.
>> 	* gas/config/tc-i386.h (x86_support_flex_fde_p): Remove.
>> 	(sframe_support_flex_fde_p): Define to true.
>> 	* gas/config/tc-s390.c (s390_support_flex_fde_p): Remove.
>> 	* gas/config/tc-s390.h (s390_support_flex_fde_p): Remove.
>> 	(sframe_support_flex_fde_p): Define to true.
>> ---
>>   gas/config/tc-aarch64.c | 8 --------
>>   gas/config/tc-aarch64.h | 3 +--
>>   gas/config/tc-i386.c    | 7 -------
>>   gas/config/tc-i386.h    | 3 +--
>>   gas/config/tc-s390.c    | 8 --------
>>   gas/config/tc-s390.h    | 3 +--
>>   6 files changed, 3 insertions(+), 29 deletions(-)
> 
> LGTM.
> 
> Should the following hooks also be converted to macros?
> 
> support_sframe_p()
> sframe_ra_tracking_p()
> 

Yes, I think sframe_ra_tracking_p () could be made to do the same.  For 
support_sframe_p (), may be not because some targets may conditionally 
enable SFrame by checking for ABI etc.


More information about the Binutils mailing list