[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with
From: |
palmer at gcc dot gnu.org |
Subject: |
[Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects |
Date: |
Wed, 20 Dec 2023 00:11:57 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=31179
--- Comment #6 from Palmer Dabbelt <palmer at gcc dot gnu.org> ---
(In reply to Andreas Schwab from comment #5)
> There are a lot of SUB_ULEB128 relocations with a non-zero addend in
> installed static archives that will change behaviour with this commit.
>
> $ readelf -Wr /usr/lib64/libc.a | grep -c 'SUB_ULEB128.*[+-] [^0]'
> 17043
> $ readelf -Wr /usr/lib64/gcc/riscv64-suse-linux/13/libgphobos.a | grep -c
> 'SUB_ULEB128.*[+-] [^0]'
> 55318
Awesome, thanks. Nelson and I were getting some confusing error reports, but
this matches what I was trying to fix at the beginning. We might have another
bug, but I think this one we can try to fix.
So I think we can do something like the following:
* Check for binaries with the bug -- I think we want a tag here, but I guess we
could also try and pattern match the +N/+N vs +M/+0.
* If the binary has the bug, then revert to the old linker behavior for
calculating the addresses from the input.
* Always emit correct addends into the output.
Then we can add some some warning when we detect the old inputs, along with
some commandline/autoconf arguments to turn the warnings into errors.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug ld/31179] New: RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, palmer at gcc dot gnu.org, 2023/12/18
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, david.abdurachmanov at gmail dot com, 2023/12/18
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, palmer at gcc dot gnu.org, 2023/12/18
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, rjones at redhat dot com, 2023/12/18
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, david.abdurachmanov at gmail dot com, 2023/12/18
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, palmer at gcc dot gnu.org, 2023/12/19
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, palmer at gcc dot gnu.org, 2023/12/19
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, address@hidden, 2023/12/19
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects,
palmer at gcc dot gnu.org <=
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, nelsonc1225 at sourceware dot org, 2023/12/19
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, nelsonc1225 at sourceware dot org, 2023/12/22
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, palmer at gcc dot gnu.org, 2023/12/22
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, charlie at rivosinc dot com, 2023/12/22
- [Bug ld/31179] RISC-V: The SET/ADD/SUB fix breaks ABI compatibility with 2.41 objects, nelsonc1225 at sourceware dot org, 2023/12/25