[PATCH v3] gas: support --gsframe=no

Sam James sam@gentoo.org
Tue Jul 15 07:01:01 GMT 2025


Jan Beulich <jbeulich@suse.com> writes:

> On 15.07.2025 02:58, Sam James wrote:
>> Being able to explicitly disable SFrames on the command line is useful,
>> especially when looking at a gas that enables SFrames by default. The
>> binutils testsuite will benefit from this as there's testcases that don't
>> expect their presence.
>> 
>> In summary:
>> * Nothing is passed       => no SFrames (no change from before)
>> * --gsframe is passed     => SFrames    (no change from before)
>> * --gsframe=yes is passed => SFrames    (previously rejected)
>> * --gsframe-no  is passed => no SFrames (previously rejected)
>> 
>> 	PR gas/33125
>> 	* gas/as.c (parse_args): Accept --gsframe=no, --gsframe=yes.
>> ---
>> I've pushed this after discussing with Indu off-list and reaching
>> consensus. Thanks.
>
> Yet documentation was left unaltered.

I'll handle that later today. I'm sorry for the omission - I'd opened a
tab for it and clearly didn't go back to it.

>
>> --- a/gas/as.c
>> +++ b/gas/as.c
>> @@ -311,7 +311,8 @@ Options:\n\
>>    fprintf (stream, _("\
>>                            generate GNU Build notes if none are present in the input\n"));
>>    fprintf (stream, _("\
>> -  --gsframe               generate SFrame stack trace information\n"));
>> +  --gsframe=[no|yes]      whether to generate SFrame stack trace information\n\
>> +                          (default: no)\n"));
>
> To be honest, I'm not entirely happy about the spelling here: It suggests
> that the prior form (without any argument) isn't valid anymore. Yet I
> didn't understand you to mean to deprecate that form ... (Note that the
> behavior here is indeed different from that for --elf-stt-common and
> --generate-missing-build-notes, which both require an argument.) See e.g.
> the help text for --compress-debug-sections.

I'll look at handling this too and send a patch for you to look at. Thanks.

>
> Jan


More information about the Binutils mailing list