bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug gold/18845] New: Using emit-relocs and icf ends in assert fail.


From: johan.karlsson at enea dot com
Subject: [Bug gold/18845] New: Using emit-relocs and icf ends in assert fail.
Date: Tue, 18 Aug 2015 08:56:36 +0000

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

            Bug ID: 18845
           Summary: Using emit-relocs and icf ends in assert fail.
           Product: binutils
           Version: 2.25
            Status: NEW
          Severity: normal
          Priority: P2
         Component: gold
          Assignee: ccoutant at gmail dot com
          Reporter: johan.karlsson at enea dot com
                CC: ian at airs dot com
  Target Milestone: ---

Created attachment 8529
  --> https://sourceware.org/bugzilla/attachment.cgi?id=8529&action=edit
The patch that is described in the comment.

test.c:
main(){ return 0; }


CFLAGS="-fuse-ld=gold -Wl,--emit-relocs -Wl,--icf=safe" make test

cc -fuse-ld=gold -Wl,--emit-relocs -Wl,--icf=safe    test.c   -o test
/usr/bin/ld.gold: internal error in do_layout, at ../../gold/object.cc:1723
collect2: error: ld returned 1 exit status
make: *** [test] Error 1


I'm attaching a patch that fixes this problem. It changes so that the
relocation sections are not added until the second pass in do_layout().

I also changed the assert to what I believe is the intended behavior, it is
more in line with the handling of the eh_frame section.

-- 
You are receiving this mail because:
You are on the CC list for the bug.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]