This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Hi Macro!
On Tue, 2016-07-19 15:09:54 +0100, Maciej W. Rozycki <macro@imgtec.com> wrote:
> Verify that the ISA mode of branch targets is the same as the referring
> relocation, so that an attempt to produce a branch between instructions
> encoded in different ISA modes each causes an error rather than silently
> producing non-functional code. Make sure that no symbol or addend bits
> are silently truncated: terminate with an error if the relocation value
> calculated cannot be encoded in the relocatable field of a branch; for
> REL targets also applying to any intermediate addend.
> [Patch attached compressed, due to its size.]
On gcc21 (compile farm), I'm seeing this with Ubuntu 4.8.4-2ubuntu1~14.04.3:
gcc -DHAVE_CONFIG_H -I. -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas -I. -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas -I../bfd -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/../include -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/.. -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/../bfd -DLOCALEDIR="\"/scratch/4/jbglaw/regular/build/mips-linux/_install_/share/locale\"" -W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Werror -Wwrite-strings -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/../zlib -g -O2 -MT tc-mips.o -MD -MP -MF .deps/tc-mips.Tpo -c -o tc-mips.o `test -f 'config/tc-mips.c' || echo '/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/'`config/tc-mips.c
/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c: In function ‘mips_force_relocation’:
/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c:14807:24: error: comparison between ‘bfd_reloc_code_real_type’ and ‘enum elf_mips_reloc_type’ [-Werror=enum-compare]
if ((fixp->fx_r_type == R_MIPS_PC26_S2
^
/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c:14808:27: error: comparison between ‘bfd_reloc_code_real_type’ and ‘enum elf_mips_reloc_type’ [-Werror=enum-compare]
|| fixp->fx_r_type == R_MIPS_PC21_S2
^
/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c: In function ‘fix_bad_cross_mode_branch_p’:
/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c:14959:17: error: variable ‘opcode’ set but not used [-Werror=unused-but-set-variable]
unsigned long opcode;
^
cc1: all warnings being treated as errors
make[3]: *** [tc-mips.o] Error 1
The first two (R_MIPS_PC21_S2 comparisons) still hold true, the opcode
warning might be gone since the latest change.
MfG, JBG
--
Jan-Benedict Glaw jbglaw@lug-owl.de +49-172-7608481
Signature of: Eine Freie Meinung in einem Freien Kopf
the second : für einen Freien Staat voll Freier Bürger.
Attachment:
signature.asc
Description: Digital signature
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |