Rename non_ir_ref to non_ir_ref_regular

Since the flag is now set only for regular object refs.

include/
	* bfdlink.h (struct bfd_link_hash_entry <non_ir_ref>): Rename to
	non_ir_ref_regular.
bfd/
	* elf-m10300.c: Rename occurrences of non_ir_ref.
	* elf32-arm.c: Likewise.
	* elf32-bfin.c: Likewise.
	* elf32-cr16.c: Likewise.
	* elf32-cris.c: Likewise.
	* elf32-d10v.c: Likewise.
	* elf32-dlx.c: Likewise.
	* elf32-fr30.c: Likewise.
	* elf32-frv.c: Likewise.
	* elf32-hppa.c: Likewise.
	* elf32-i370.c: Likewise.
	* elf32-i386.c: Likewise.
	* elf32-iq2000.c: Likewise.
	* elf32-lm32.c: Likewise.
	* elf32-m32c.c: Likewise.
	* elf32-m32r.c: Likewise.
	* elf32-m68hc1x.c: Likewise.
	* elf32-m68k.c: Likewise.
	* elf32-mcore.c: Likewise.
	* elf32-metag.c: Likewise.
	* elf32-microblaze.c: Likewise.
	* elf32-moxie.c: Likewise.
	* elf32-msp430.c: Likewise.
	* elf32-mt.c: Likewise.
	* elf32-nios2.c: Likewise.
	* elf32-or1k.c: Likewise.
	* elf32-ppc.c: Likewise.
	* elf32-rl78.c: Likewise.
	* elf32-s390.c: Likewise.
	* elf32-score.c: Likewise.
	* elf32-score7.c: Likewise.
	* elf32-sh.c: Likewise.
	* elf32-tic6x.c: Likewise.
	* elf32-tilepro.c: Likewise.
	* elf32-v850.c: Likewise.
	* elf32-vax.c: Likewise.
	* elf32-xstormy16.c: Likewise.
	* elf32-xtensa.c: Likewise.
	* elf64-alpha.c: Likewise.
	* elf64-hppa.c: Likewise.
	* elf64-ia64-vms.c: Likewise.
	* elf64-mmix.c: Likewise.
	* elf64-ppc.c: Likewise.
	* elf64-s390.c: Likewise.
	* elf64-sh64.c: Likewise.
	* elf64-x86-64.c: Likewise.
	* elflink.c: Likewise.
	* elfnn-aarch64.c: Likewise.
	* elfnn-ia64.c: Likewise.
	* elfnn-riscv.c: Likewise.
	* elfxx-mips.c: Likewise.
	* elfxx-sparc.c: Likewise.
	* elfxx-tilegx.c: Likewise.
	* linker.c: Likewise.
ld/
	* plugin.c: Rename occurrences of non_ir_ref.
This commit is contained in:
Alan Modra 2017-05-16 07:58:14 +09:30
parent 4070765b1a
commit bc4e12ded1
59 changed files with 128 additions and 62 deletions

View file

@ -1,3 +1,60 @@
2017-05-16 Alan Modra <amodra@gmail.com>
* elf-m10300.c: Rename occurrences of non_ir_ref.
* elf32-arm.c: Likewise.
* elf32-bfin.c: Likewise.
* elf32-cr16.c: Likewise.
* elf32-cris.c: Likewise.
* elf32-d10v.c: Likewise.
* elf32-dlx.c: Likewise.
* elf32-fr30.c: Likewise.
* elf32-frv.c: Likewise.
* elf32-hppa.c: Likewise.
* elf32-i370.c: Likewise.
* elf32-i386.c: Likewise.
* elf32-iq2000.c: Likewise.
* elf32-lm32.c: Likewise.
* elf32-m32c.c: Likewise.
* elf32-m32r.c: Likewise.
* elf32-m68hc1x.c: Likewise.
* elf32-m68k.c: Likewise.
* elf32-mcore.c: Likewise.
* elf32-metag.c: Likewise.
* elf32-microblaze.c: Likewise.
* elf32-moxie.c: Likewise.
* elf32-msp430.c: Likewise.
* elf32-mt.c: Likewise.
* elf32-nios2.c: Likewise.
* elf32-or1k.c: Likewise.
* elf32-ppc.c: Likewise.
* elf32-rl78.c: Likewise.
* elf32-s390.c: Likewise.
* elf32-score.c: Likewise.
* elf32-score7.c: Likewise.
* elf32-sh.c: Likewise.
* elf32-tic6x.c: Likewise.
* elf32-tilepro.c: Likewise.
* elf32-v850.c: Likewise.
* elf32-vax.c: Likewise.
* elf32-xstormy16.c: Likewise.
* elf32-xtensa.c: Likewise.
* elf64-alpha.c: Likewise.
* elf64-hppa.c: Likewise.
* elf64-ia64-vms.c: Likewise.
* elf64-mmix.c: Likewise.
* elf64-ppc.c: Likewise.
* elf64-s390.c: Likewise.
* elf64-sh64.c: Likewise.
* elf64-x86-64.c: Likewise.
* elflink.c: Likewise.
* elfnn-aarch64.c: Likewise.
* elfnn-ia64.c: Likewise.
* elfnn-riscv.c: Likewise.
* elfxx-mips.c: Likewise.
* elfxx-sparc.c: Likewise.
* elfxx-tilegx.c: Likewise.
* linker.c: Likewise.
2017-05-16 Alan Modra <amodra@gmail.com> 2017-05-16 Alan Modra <amodra@gmail.com>
* elf64-ppc.c (add_symbol_adjust): Transfer non_ir_ref_dynamic. * elf64-ppc.c (add_symbol_adjust): Transfer non_ir_ref_dynamic.

View file

@ -1094,7 +1094,7 @@ mn10300_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
r_type = ELF32_R_TYPE (rel->r_info); r_type = ELF32_R_TYPE (rel->r_info);

View file

@ -14556,7 +14556,7 @@ elf32_arm_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the /* PR15323, ref flags aren't set for references in the
same object. */ same object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
} }

View file

@ -1191,7 +1191,7 @@ bfin_check_relocs (bfd * abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -738,7 +738,7 @@ cr16_elf_check_relocs (bfd *abfd, struct bfd_link_info *info, asection *sec,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* Some relocs require a global offset table. */ /* Some relocs require a global offset table. */

View file

@ -3178,7 +3178,7 @@ cris_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
r_type = ELF32_R_TYPE (rel->r_info); r_type = ELF32_R_TYPE (rel->r_info);

View file

@ -294,7 +294,7 @@ elf32_d10v_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -454,7 +454,7 @@ elf32_dlx_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -673,7 +673,7 @@ fr30_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -6041,7 +6041,7 @@ elf32_frv_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -1171,7 +1171,7 @@ elf32_hppa_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
hh->eh.root.non_ir_ref = 1; hh->eh.root.non_ir_ref_regular = 1;
} }
r_type = ELF32_R_TYPE (rela->r_info); r_type = ELF32_R_TYPE (rela->r_info);

View file

@ -839,7 +839,7 @@ i370_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
if (bfd_link_pic (info)) if (bfd_link_pic (info))

View file

@ -1971,7 +1971,7 @@ elf_i386_check_relocs (bfd *abfd,
/* It is referenced by a non-shared object. */ /* It is referenced by a non-shared object. */
h->ref_regular = 1; h->ref_regular = 1;
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
if (h->type == STT_GNU_IFUNC) if (h->type == STT_GNU_IFUNC)
elf_tdata (info->output_bfd)->has_gnu_symbols elf_tdata (info->output_bfd)->has_gnu_symbols

View file

@ -486,7 +486,7 @@ iq2000_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -1272,7 +1272,7 @@ lm32_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* Some relocs require a global offset table. */ /* Some relocs require a global offset table. */

View file

@ -689,7 +689,7 @@ m32c_elf_check_relocs
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -3706,7 +3706,7 @@ m32r_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* Some relocs require a global offset table. */ /* Some relocs require a global offset table. */

View file

@ -879,7 +879,7 @@ elf32_m68hc11_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -2590,7 +2590,7 @@ elf_m68k_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -629,7 +629,7 @@ mcore_elf_check_relocs (bfd * abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -2132,7 +2132,7 @@ elf_metag_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
hh->eh.root.non_ir_ref = 1; hh->eh.root.non_ir_ref_regular = 1;
} }
/* Some relocs require a global offset table. */ /* Some relocs require a global offset table. */

View file

@ -2315,7 +2315,7 @@ microblaze_elf_check_relocs (bfd * abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (r_type) switch (r_type)

View file

@ -359,7 +359,7 @@ moxie_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
} }

View file

@ -698,7 +698,7 @@ elf32_msp430_check_relocs (bfd * abfd, struct bfd_link_info * info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
} }

View file

@ -458,7 +458,7 @@ mt_elf_check_relocs
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
} }

View file

@ -4734,7 +4734,7 @@ nios2_elf32_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
r_type = ELF32_R_TYPE (rel->r_info); r_type = ELF32_R_TYPE (rel->r_info);

View file

@ -1404,7 +1404,7 @@ or1k_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -4055,7 +4055,7 @@ ppc_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* If a relocation refers to _GLOBAL_OFFSET_TABLE_, create the .got. /* If a relocation refers to _GLOBAL_OFFSET_TABLE_, create the .got.

View file

@ -1328,7 +1328,7 @@ rl78_elf_check_relocs
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -996,7 +996,7 @@ elf_s390_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* Create got section and local_got_refcounts array if they /* Create got section and local_got_refcounts array if they

View file

@ -2842,7 +2842,7 @@ s3_bfd_score_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the /* PR15323, ref flags aren't set for references in the
same object. */ same object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
} }

View file

@ -2651,7 +2651,7 @@ s7_bfd_score_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the /* PR15323, ref flags aren't set for references in the
same object. */ same object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
} }

View file

@ -5823,7 +5823,7 @@ sh_elf_check_relocs (bfd *abfd, struct bfd_link_info *info, asection *sec,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
r_type = sh_elf_optimized_tls_reloc (info, r_type, h == NULL); r_type = sh_elf_optimized_tls_reloc (info, r_type, h == NULL);

View file

@ -2835,7 +2835,7 @@ elf32_tic6x_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (r_type) switch (r_type)

View file

@ -1504,7 +1504,7 @@ tilepro_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
r_type = tilepro_elf_tls_transition (info, r_type, h == NULL); r_type = tilepro_elf_tls_transition (info, r_type, h == NULL);

View file

@ -86,7 +86,7 @@ v850_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
r_type = ELF32_R_TYPE (rel->r_info); r_type = ELF32_R_TYPE (rel->r_info);

View file

@ -591,7 +591,7 @@ elf_vax_check_relocs (bfd *abfd, struct bfd_link_info *info, asection *sec,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -438,7 +438,7 @@ xstormy16_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF32_R_TYPE (rel->r_info)) switch (ELF32_R_TYPE (rel->r_info))

View file

@ -1015,7 +1015,7 @@ elf_xtensa_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
eh = elf_xtensa_hash_entry (h); eh = elf_xtensa_hash_entry (h);

View file

@ -1838,7 +1838,7 @@ elf64_alpha_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.root.non_ir_ref = 1; h->root.root.non_ir_ref_regular = 1;
h->root.ref_regular = 1; h->root.ref_regular = 1;
} }

View file

@ -644,7 +644,7 @@ elf64_hppa_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
hh->eh.root.non_ir_ref = 1; hh->eh.root.non_ir_ref_regular = 1;
hh->eh.ref_regular = 1; hh->eh.ref_regular = 1;
} }
else else

View file

@ -2099,7 +2099,7 @@ elf64_ia64_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
h->ref_regular = 1; h->ref_regular = 1;
} }
else else

View file

@ -2018,7 +2018,7 @@ mmix_elf_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (ELF64_R_TYPE (rel->r_info)) switch (ELF64_R_TYPE (rel->r_info))

View file

@ -5118,7 +5118,7 @@ add_symbol_adjust (struct ppc_link_hash_entry *eh, struct bfd_link_info *info)
/* Propagate reference flags from entry symbol to function /* Propagate reference flags from entry symbol to function
descriptor symbol. */ descriptor symbol. */
fdh->elf.root.non_ir_ref |= eh->elf.root.non_ir_ref; fdh->elf.root.non_ir_ref_regular |= eh->elf.root.non_ir_ref_regular;
fdh->elf.root.non_ir_ref_dynamic |= eh->elf.root.non_ir_ref_dynamic; fdh->elf.root.non_ir_ref_dynamic |= eh->elf.root.non_ir_ref_dynamic;
fdh->elf.ref_regular |= eh->elf.ref_regular; fdh->elf.ref_regular |= eh->elf.ref_regular;
fdh->elf.ref_regular_nonweak |= eh->elf.ref_regular_nonweak; fdh->elf.ref_regular_nonweak |= eh->elf.ref_regular_nonweak;
@ -5423,9 +5423,9 @@ ppc64_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
if (eh->is_func && eh->oh != NULL) if (eh->is_func && eh->oh != NULL)
eh->oh->elf.root.non_ir_ref = 1; eh->oh->elf.root.non_ir_ref_regular = 1;
if (h == htab->elf.hgot) if (h == htab->elf.hgot)
sec->has_toc_reloc = 1; sec->has_toc_reloc = 1;

View file

@ -911,7 +911,7 @@ elf_s390_check_relocs (bfd *abfd,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* Create got section and local_got_refcounts array if they /* Create got section and local_got_refcounts array if they

View file

@ -2384,7 +2384,7 @@ sh_elf64_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* Some relocs require a global offset table. */ /* Some relocs require a global offset table. */

View file

@ -2336,7 +2336,7 @@ elf_x86_64_check_relocs (bfd *abfd, struct bfd_link_info *info,
{ {
/* It is referenced by a non-shared object. */ /* It is referenced by a non-shared object. */
h->ref_regular = 1; h->ref_regular = 1;
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
if (h->type == STT_GNU_IFUNC) if (h->type == STT_GNU_IFUNC)
elf_tdata (info->output_bfd)->has_gnu_symbols elf_tdata (info->output_bfd)->has_gnu_symbols

View file

@ -10472,7 +10472,7 @@ elf_link_input_bfd (struct elf_final_link_info *flinfo, bfd *input_bfd)
linker may attach linker created dynamic sections linker may attach linker created dynamic sections
to the plugin bfd. Symbols defined in linker to the plugin bfd. Symbols defined in linker
created sections are not plugin symbols. */ created sections are not plugin symbols. */
if ((h->root.non_ir_ref if ((h->root.non_ir_ref_regular
|| h->root.non_ir_ref_dynamic) || h->root.non_ir_ref_dynamic)
&& (h->root.type == bfd_link_hash_defined && (h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak) || h->root.type == bfd_link_hash_defweak)

View file

@ -7135,7 +7135,7 @@ elfNN_aarch64_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
/* Could be done earlier, if h were already available. */ /* Could be done earlier, if h were already available. */
@ -7191,7 +7191,7 @@ elfNN_aarch64_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* It is referenced by a non-shared object. */ /* It is referenced by a non-shared object. */
h->ref_regular = 1; h->ref_regular = 1;
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (bfd_r_type) switch (bfd_r_type)

View file

@ -2359,7 +2359,7 @@ elfNN_ia64_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
h->ref_regular = 1; h->ref_regular = 1;
} }
else else

View file

@ -539,7 +539,7 @@ riscv_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
switch (r_type) switch (r_type)

View file

@ -8393,7 +8393,7 @@ _bfd_mips_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the /* PR15323, ref flags aren't set for references in the
same object. */ same object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
} }

View file

@ -1477,7 +1477,7 @@ _bfd_sparc_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
if (h && h->type == STT_GNU_IFUNC) if (h && h->type == STT_GNU_IFUNC)

View file

@ -1721,7 +1721,7 @@ tilegx_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
/* PR15323, ref flags aren't set for references in the same /* PR15323, ref flags aren't set for references in the same
object. */ object. */
h->root.non_ir_ref = 1; h->root.non_ir_ref_regular = 1;
} }
r_type = tilegx_elf_tls_transition (info, r_type, h == NULL, r_type = tilegx_elf_tls_transition (info, r_type, h == NULL,

View file

@ -1735,7 +1735,7 @@ _bfd_generic_link_add_one_symbol (struct bfd_link_info *info,
otherwise add a warning. */ otherwise add a warning. */
if ((!info->lto_plugin_active if ((!info->lto_plugin_active
&& (h->u.undef.next != NULL || info->hash->undefs_tail == h)) && (h->u.undef.next != NULL || info->hash->undefs_tail == h))
|| h->non_ir_ref || h->non_ir_ref_regular
|| h->non_ir_ref_dynamic) || h->non_ir_ref_dynamic)
{ {
(*info->callbacks->warning) (info, string, h->root.string, (*info->callbacks->warning) (info, string, h->root.string,

View file

@ -1,3 +1,8 @@
2017-05-16 Alan Modra <amodra@gmail.com>
* bfdlink.h (struct bfd_link_hash_entry <non_ir_ref>): Rename to
non_ir_ref_regular.
2017-05-16 Alan Modra <amodra@gmail.com> 2017-05-16 Alan Modra <amodra@gmail.com>
* bfdlink.h (struct bfd_link_hash_entry): Update non_ir_ref * bfdlink.h (struct bfd_link_hash_entry): Update non_ir_ref

View file

@ -102,7 +102,7 @@ struct bfd_link_hash_entry
/* Symbol is referenced in a normal regular object file, /* Symbol is referenced in a normal regular object file,
as distinct from a LTO IR object file. */ as distinct from a LTO IR object file. */
unsigned int non_ir_ref : 1; unsigned int non_ir_ref_regular : 1;
/* Symbol is referenced in a normal dynamic object file, /* Symbol is referenced in a normal dynamic object file,
as distinct from a LTO IR object file. */ as distinct from a LTO IR object file. */

View file

@ -1,3 +1,7 @@
2017-05-16 Alan Modra <amodra@gmail.com>
* plugin.c: Rename occurrences of non_ir_ref.
2017-05-16 Alan Modra <amodra@gmail.com> 2017-05-16 Alan Modra <amodra@gmail.com>
* plugin.c (is_visible_from_outside): Use non_ir_ref_dynamic. * plugin.c (is_visible_from_outside): Use non_ir_ref_dynamic.

View file

@ -774,7 +774,7 @@ get_symbols (const void *handle, int nsyms, struct ld_plugin_symbol *syms,
even potentially-referenced, perhaps in a future final link if even potentially-referenced, perhaps in a future final link if
this is a partial one, perhaps dynamically at load-time if the this is a partial one, perhaps dynamically at load-time if the
symbol is externally visible. */ symbol is externally visible. */
if (blhe->non_ir_ref) if (blhe->non_ir_ref_regular)
res = LDPR_PREVAILING_DEF; res = LDPR_PREVAILING_DEF;
else if (is_visible_from_outside (&syms[n], blhe)) else if (is_visible_from_outside (&syms[n], blhe))
res = def_ironly_exp; res = def_ironly_exp;
@ -1266,7 +1266,7 @@ plugin_call_cleanup (void)
/* To determine which symbols should be resolved LDPR_PREVAILING_DEF /* To determine which symbols should be resolved LDPR_PREVAILING_DEF
and which LDPR_PREVAILING_DEF_IRONLY, we notice all the symbols as and which LDPR_PREVAILING_DEF_IRONLY, we notice all the symbols as
the linker adds them to the linker hash table. Mark those the linker adds them to the linker hash table. Mark those
referenced from a non-IR file with non_ir_ref or referenced from a non-IR file with non_ir_ref_regular or
non_ir_ref_dynamic as appropriate. We have to notice_all symbols, non_ir_ref_dynamic as appropriate. We have to notice_all symbols,
because we won't necessarily know until later which ones will be because we won't necessarily know until later which ones will be
contributed by IR files. */ contributed by IR files. */
@ -1304,7 +1304,7 @@ plugin_notice (struct bfd_link_info *info,
|| inh->type == bfd_link_hash_new) || inh->type == bfd_link_hash_new)
{ {
if ((abfd->flags & DYNAMIC) == 0) if ((abfd->flags & DYNAMIC) == 0)
inh->non_ir_ref = TRUE; inh->non_ir_ref_regular = TRUE;
else else
inh->non_ir_ref_dynamic = TRUE; inh->non_ir_ref_dynamic = TRUE;
} }
@ -1362,7 +1362,7 @@ plugin_notice (struct bfd_link_info *info,
if (ref) if (ref)
{ {
if ((abfd->flags & DYNAMIC) == 0) if ((abfd->flags & DYNAMIC) == 0)
h->non_ir_ref = TRUE; h->non_ir_ref_regular = TRUE;
else else
h->non_ir_ref_dynamic = TRUE; h->non_ir_ref_dynamic = TRUE;
} }