V3 [PATCH] elf: Allow mixed ordered/unordered inputs for non-relocatable link
Nick Clifton
nickc@redhat.com
Mon Jan 4 13:32:03 GMT 2021
Hi H.J.
>>>> 1. Add pattern to bfd_section for the matching section name pattern in
>>>> linker script and update BFD_FAKE_SECTION.
>>>> 2. Sort the consecutive bfd_indirect_link_order sections with the same
>>>> pattern to allow linker script to overdide input section order.
>>>> 3. Place unordered sections before ordered sections.
>>>> 4. Change the offsets of the indirect input sections only.
The patch looks good to me, but the new tests do cause problems for
a variety of targets. For example:
fido-elf ... LD REGRESSION: ld-elf/pr26256-3a ld-elf/pr26256-3b
fr30-elf ... LD REGRESSION: ld-elf/pr26256-2b
mipsel-linux-gnu ... LD REGRESSION: ld-elf/pr26256-3a ld-elf/pr26256-3b
riscv32-elf ... LD REGRESSION: ld-elf/pr26256-3a ld-elf/pr26256-3b
s390-linux ... LD REGRESSION: ld-elf/pr26256-3a ld-elf/pr26256-3b
score-elf ... LD REGRESSION: ld-elf/pr26256-3a ld-elf/pr26256-3b
(This is just a selection).
The cause appears to be an incorrect assumption about the start address of
the text section:
regexp_diff match failure
regexp "^ 0x[a-f0-9]+ +020103 +.+$"
line " 0x00000020 02010000 03000000 ........"
FAIL: ld-elf/pr26256-3a
regexp_diff match failure
regexp "^ 0x[a-f0-9]+ +020103 +.+$"
aline " 0x00000020 02010000 03000000 ........"
FAIL: ld-elf/pr26256-3b
Could you fix these please ?
Cheers
Nick
More information about the Binutils
mailing list