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.
+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>
* elf64-ppc.c (add_symbol_adjust): Transfer non_ir_ref_dynamic.
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
r_type = ELF32_R_TYPE (rel->r_info);
/* PR15323, ref flags aren't set for references in the
same object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
}
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
/* Some relocs require a global offset table. */
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
r_type = ELF32_R_TYPE (rel->r_info);
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- hh->eh.root.non_ir_ref = 1;
+ hh->eh.root.non_ir_ref_regular = 1;
}
r_type = ELF32_R_TYPE (rela->r_info);
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
if (bfd_link_pic (info))
/* It is referenced by a non-shared object. */
h->ref_regular = 1;
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
if (h->type == STT_GNU_IFUNC)
elf_tdata (info->output_bfd)->has_gnu_symbols
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
/* Some relocs require a global offset table. */
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
/* Some relocs require a global offset table. */
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- hh->eh.root.non_ir_ref = 1;
+ hh->eh.root.non_ir_ref_regular = 1;
}
/* Some relocs require a global offset table. */
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (r_type)
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
}
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
}
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
}
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
r_type = ELF32_R_TYPE (rel->r_info);
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
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.
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
/* Create got section and local_got_refcounts array if they
/* PR15323, ref flags aren't set for references in the
same object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
}
/* PR15323, ref flags aren't set for references in the
same object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
}
/* PR15323, ref flags aren't set for references in the same
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);
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (r_type)
/* PR15323, ref flags aren't set for references in the same
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);
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
r_type = ELF32_R_TYPE (rel->r_info);
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF32_R_TYPE (rel->r_info))
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
eh = elf_xtensa_hash_entry (h);
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.root.non_ir_ref = 1;
+ h->root.root.non_ir_ref_regular = 1;
h->root.ref_regular = 1;
}
/* PR15323, ref flags aren't set for references in the same
object. */
- hh->eh.root.non_ir_ref = 1;
+ hh->eh.root.non_ir_ref_regular = 1;
hh->eh.ref_regular = 1;
}
else
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
h->ref_regular = 1;
}
else
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (ELF64_R_TYPE (rel->r_info))
/* Propagate reference flags from entry symbol to function
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.ref_regular |= eh->elf.ref_regular;
fdh->elf.ref_regular_nonweak |= eh->elf.ref_regular_nonweak;
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
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)
sec->has_toc_reloc = 1;
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
/* Create got section and local_got_refcounts array if they
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
/* Some relocs require a global offset table. */
{
/* It is referenced by a non-shared object. */
h->ref_regular = 1;
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
if (h->type == STT_GNU_IFUNC)
elf_tdata (info->output_bfd)->has_gnu_symbols
linker may attach linker created dynamic sections
to the plugin bfd. Symbols defined in linker
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.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak)
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
/* Could be done earlier, if h were already available. */
/* It is referenced by a non-shared object. */
h->ref_regular = 1;
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (bfd_r_type)
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
h->ref_regular = 1;
}
else
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
switch (r_type)
/* PR15323, ref flags aren't set for references in the
same object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
}
/* PR15323, ref flags aren't set for references in the same
object. */
- h->root.non_ir_ref = 1;
+ h->root.non_ir_ref_regular = 1;
}
if (h && h->type == STT_GNU_IFUNC)
/* PR15323, ref flags aren't set for references in the same
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,
otherwise add a warning. */
if ((!info->lto_plugin_active
&& (h->u.undef.next != NULL || info->hash->undefs_tail == h))
- || h->non_ir_ref
+ || h->non_ir_ref_regular
|| h->non_ir_ref_dynamic)
{
(*info->callbacks->warning) (info, string, h->root.string,
+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>
* bfdlink.h (struct bfd_link_hash_entry): Update non_ir_ref
/* Symbol is referenced in a normal regular 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,
as distinct from a LTO IR object file. */
+2017-05-16 Alan Modra <amodra@gmail.com>
+
+ * plugin.c: Rename occurrences of non_ir_ref.
+
2017-05-16 Alan Modra <amodra@gmail.com>
* plugin.c (is_visible_from_outside): Use non_ir_ref_dynamic.
even potentially-referenced, perhaps in a future final link if
this is a partial one, perhaps dynamically at load-time if the
symbol is externally visible. */
- if (blhe->non_ir_ref)
+ if (blhe->non_ir_ref_regular)
res = LDPR_PREVAILING_DEF;
else if (is_visible_from_outside (&syms[n], blhe))
res = def_ironly_exp;
/* To determine which symbols should be resolved LDPR_PREVAILING_DEF
and which LDPR_PREVAILING_DEF_IRONLY, we notice all the symbols as
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,
because we won't necessarily know until later which ones will be
contributed by IR files. */
|| inh->type == bfd_link_hash_new)
{
if ((abfd->flags & DYNAMIC) == 0)
- inh->non_ir_ref = TRUE;
+ inh->non_ir_ref_regular = TRUE;
else
inh->non_ir_ref_dynamic = TRUE;
}
if (ref)
{
if ((abfd->flags & DYNAMIC) == 0)
- h->non_ir_ref = TRUE;
+ h->non_ir_ref_regular = TRUE;
else
h->non_ir_ref_dynamic = TRUE;
}