[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I aga
From: |
wilson at gcc dot gnu.org |
Subject: |
[Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol |
Date: |
Wed, 17 Mar 2021 18:18:25 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=27566
Jim Wilson <wilson at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |wilson at gcc dot gnu.org
--- Comment #5 from Jim Wilson <wilson at gcc dot gnu.org> ---
The c.lui case was fixed because a bug turned up in regression testing, and
Ilya Diachkov debugged it and wrote a patch. The tail end of the thread is
here
https://sourceware.org/pipermail/binutils/2019-July/107702.html
Looks like I missed the fact that other cases needed a similar fix. And I
didn't notice the MAXPAGESIZE versus COMMONPAGESIZE issue. it does look like
fixing all 3 places to use MAXPAGESIZE+COMMONPAGESIZE is the correct fix.
GP is computed so that __DATA_BEGIN__+0x800 is the minimum value, so that it
can never overlap rodata section, but apparently that isn't enough in this
case. Maybe gp or __DATA__BEGIN__ aren't being updated until after we use them
because of how relaxation works.
Yes, we can add symbols to the linker script if necessary, but __DATA_BEGIN__
is alraedy in the right place and we should be able to use that. Except it
looks like it might not work in this case.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug ld/27566] New: [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol, address@hidden, 2021/03/11
- [Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol, nelsonc1225 at sourceware dot org, 2021/03/12
- [Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol, nelsonc1225 at sourceware dot org, 2021/03/12
- [Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol, address@hidden, 2021/03/15
- [Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol, address@hidden, 2021/03/15
- [Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol,
wilson at gcc dot gnu.org <=
- [Bug ld/27566] [RISC-V] relocation truncated to fit: R_RISCV_GPREL_I against aymbol, nelsonc1225 at sourceware dot org, 2021/03/26