RFC: PR 31964: Add .base64 pseudo-op to gas

Jan Beulich jbeulich@suse.com
Wed Jul 10 08:59:47 GMT 2024


On 10.07.2024 09:23, Nick Clifton wrote:
> Hi Guys,
> 
>   Attached is a patch to add a ".base64" pseudo-op to the assembler.
>   The motivation is to allow tools that create assembler source files
>   (ie compilers) to embed large amounts of binary data without forcing
>   them to use the .incbin directive.  This will be helpful to gcc for
>   example as it needs to embed lots of LTO data in the object files
>   that it is creating.
> 
>   Example of use:
> 
> 	.base64 "aGVsbG8gd29ybGQK", "cGFkZGluZyBoZXJlCg==" 
> 
>   There is no limit on the line length, but all base64 encoded strings
>   must appear on a single line.
> 
>   Any comments ?

The doc addition presently suggests that only one or two strings can
be supplied, due to there not being any use of @dots{}. I further wonder
in how far it is necessary to require comma separated arguments. This
is because of me observing, in the doc change, that e.g. .ascii and
.asciz don't require commas as separators. Requiring commas certainly
has positive aspects (see my scrubber work to deal with e.g. macro
arguments not having such a requirement), so the question is mainly wrt
possible concerns towards overall consistency.

Jan


More information about the Binutils mailing list