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]

old bfin bug


Hi Binutils hackers,

anything can be done to help fixing this old issue?

https://sourceware.org/bugzilla/show_bug.cgi?id=13391

I can test patches, but I have no clue how to fix it.

There is a patch which was found in old adi toolchain,
but it does not work in all cases:
diff --git a/bfd/elf32-bfin.c b/bfd/elf32-bfin.c
index b3e09bd..660eec5 100644
--- a/bfd/elf32-bfin.c
+++ b/bfd/elf32-bfin.c
@@ -4845,7 +4845,8 @@ bfinfdpic_check_relocs (bfd *abfd, struct
bfd_link_info *info,
 
        case R_BFIN_FUNCDESC:
          picrel->fd++;
-         picrel->relocsfd++;
+         if (bfd_get_section_flags (abfd, sec) & SEC_ALLOC)
+           picrel->relocsfd++;
          break;
 
         /* This relocation describes the C++ object vtable
 * hierarchy.

best regards
 Waldemar


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