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]

Re: Release 2.22: Next week ... (m68hc11 testsuite)


On Thu, 2011-12-29 at 15:45 +0000, James Murray wrote:
> That's a big problem as it seems there's a long-standing critical bug
> that they would have exposed.
> 
>  This essential trampoline code
> is not being emitted.

After extensive investigation I found that the broke between 2.16 and
2.17

Specifically this patch to elflink.c committed on 2006-08-15 ~19.30
----------------------------------------------------------
--- src-old/bfd/elflink.c 2011-12-30 01:32:04.000000000 +0000
+++ src-old2/bfd/elflink.c 2011-12-30 01:35:01.000000000 +0000
@@ -4058,13 +4058,13 @@
 	    isym->st_other = (STV_HIDDEN
 			      | (isym->st_other & ~ELF_ST_VISIBILITY (-1)));
 
-	  if (isym->st_other != 0 && !dynamic)
+	  if (ELF_ST_VISIBILITY (isym->st_other) != 0 && !dynamic)
 	    {
 	      unsigned char hvis, symvis, other, nvis;
 
-	      /* Take the balance of OTHER from the definition.  */
-	      other = (definition ? isym->st_other : h->other);
-	      other &= ~ ELF_ST_VISIBILITY (-1);
+	      /* Only merge the visibility. Leave the remainder of the
+		 st_other field to elf_backend_merge_symbol_attribute.  */
+	      other = h->other & ~ELF_ST_VISIBILITY (-1);
 
 	      /* Combine visibilities, using the most constraining one.  */
 	      hvis   = ELF_ST_VISIBILITY (h->other);
----------------------------------------------------------

The accompanying bfd ChangeLog entry says:
----------------------------------------------------------
 2006-08-15  Thiemo Seufer  <ths@mips.com>
             Nigel Stephens  <nigel@mips.com>

	* elf32-mips.c, elf64-mips.c, elfn32-mips.c
	(elf_backend_merge_symbol_attribute): Define.
	* elflink.c (elf_link_add_object_symbols): Merge only the ELF
	visibility flags.
	* elfxx-mips.c (_bfd_mips_elf_merge_symbol_attribute): New function.
----------------------------------------------------------

What does this mean and what needs doing to get the m68hc11 trampoline
code back?

regards

James Murray


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]