[PATCH v2] gas: Fix a testcase broken by new ZSTD support
Jan Beulich
jbeulich@suse.com
Fri Aug 5 08:24:49 GMT 2022
On 05.08.2022 09:45, Tsukasa OI wrote:
> The commit 1369522f36eece1b37139a81f7f2139ba3915172 ("Recognize the new ELF
> compression type for ZSTD.") added the new ELF compression type but it
> accidentally broke a GAS testcase. Since testing for the section type
> "2048" (SHF_COMPRESSED) is not going to be portable in the long term, it
> now tests SHF_STRINGS ("32") instead. ".word 0" should be okay to
> represent no null-terminated strings.
>
> gas/ChangeLog:
>
> * testsuite/gas/elf/section10.s: Use SHF_STRINGS to test. Put an
> empty string in it.
> * testsuite/gas/elf/section10.d: Reflect the changes above.
Hmm, but SHF_STRINGS requires sh_entsize to be set, so the resulting
object file is, strictly speaking, not valid. Perhaps use
SHF_LINK_ORDER then (where the spec leaves room for sh_link being zero),
or SHF_OS_NONCONFORMING (since we don't mean to actually link this
object file into anywhere), or SHF_TLS?
Jan
More information about the Binutils
mailing list