[Bug gold/17670] internal error in symval_for_branch, at powerpc.cc:6755 during qt5 build

2014-12-03 Thread pinskia at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17670

Andrew Pinski pinskia at gcc dot gnu.org changed:

   What|Removed |Added

 Status|RESOLVED|REOPENED
 CC||pinskia at gcc dot gnu.org
 Resolution|MOVED   |---

--- Comment #5 from Andrew Pinski pinskia at gcc dot gnu.org ---
Reopening since the linker should not crash on code which violates C++ ODR.

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

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gold/17670] internal error in symval_for_branch, at powerpc.cc:6755 during qt5 build

2014-12-03 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17670

--- Comment #6 from cvs-commit at gcc dot gnu.org cvs-commit at gcc dot 
gnu.org ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project gdb and binutils.

The branch, master has been updated
   via  1611bc4afb0f08f0aff64ec355b8d68e9f4f0a73 (commit)
  from  858339f2b7aafe199c1cd07fc8d4a7c8130aa285 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=1611bc4afb0f08f0aff64ec355b8d68e9f4f0a73

commit 1611bc4afb0f08f0aff64ec355b8d68e9f4f0a73
Author: Alan Modra amo...@gmail.com
Date:   Wed Dec 3 16:17:23 2014 +1030

powerpc gold, work around pr17670

pr17670 is about an assert triggering on a branch to an undefined
weak symbol, the symbol being undefined due to dropping its comdat
group section.  (Well sort of.  The symbol is actually defined in
an .opd section which isn't part of the group, but the code section
the opd entry points at is dropped.)  So don't assert.
Also, don't make long branch stubs to such symbols, and arrange to
have target-reloc.h code warn when applying relocs that use the sym.

PR 17670
* symtab.cc (Symbol::set_undefined): Remove assertion.
* powerpc.cc (Target_powerpc::symval_for_branch): Don't assert
on symbols defined in discarded sections, instead return false.
Rearrange params, update all callers.
(Target_powerpc::Branch_info::make_stub): Don't make stubs for
branches to syms in discarded sections.
(Global_symbol_visitor_opd::operator()): Set discarded opd syms
undefined and flag as discarded.
(Target_powerpc::Relocate::relocate): Localize variable.

---

Summary of changes:
 gold/ChangeLog  |   13 +
 gold/powerpc.cc |   54 +++---
 gold/symtab.cc  |1 -
 3 files changed, 44 insertions(+), 24 deletions(-)

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

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gold/17670] internal error in symval_for_branch, at powerpc.cc:6755 during qt5 build

2014-12-03 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=17670

--- Comment #7 from cvs-commit at gcc dot gnu.org cvs-commit at gcc dot 
gnu.org ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project gdb and binutils.

The branch, binutils-2_25-branch has been updated
   via  feba93770920f91760d6390541221b75ba5c95f3 (commit)
  from  b6cc44453451b1ac6ca22d83875a6c3583ceec3d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=feba93770920f91760d6390541221b75ba5c95f3

commit feba93770920f91760d6390541221b75ba5c95f3
Author: Alan Modra amo...@gmail.com
Date:   Wed Dec 3 16:17:23 2014 +1030

powerpc gold, work around pr17670

pr17670 is about an assert triggering on a branch to an undefined
weak symbol, the symbol being undefined due to dropping its comdat
group section.  (Well sort of.  The symbol is actually defined in
an .opd section which isn't part of the group, but the code section
the opd entry points at is dropped.)  So don't assert.
Also, don't make long branch stubs to such symbols, and arrange to
have target-reloc.h code warn when applying relocs that use the sym.

PR 17670
* symtab.cc (Symbol::set_undefined): Remove assertion.
* powerpc.cc (Target_powerpc::symval_for_branch): Don't assert
on symbols defined in discarded sections, instead return false.
Rearrange params, update all callers.
(Target_powerpc::Branch_info::make_stub): Don't make stubs for
branches to syms in discarded sections.
(Global_symbol_visitor_opd::operator()): Set discarded opd syms
undefined and flag as discarded.
(Target_powerpc::Relocate::relocate): Localize variable.

---

Summary of changes:
 gold/ChangeLog  |   13 +
 gold/powerpc.cc |   54 +++---
 gold/symtab.cc  |1 -
 3 files changed, 44 insertions(+), 24 deletions(-)

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

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gold/17670] internal error in symval_for_branch, at powerpc.cc:6755 during qt5 build

2014-12-03 Thread amodra at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=17670

Alan Modra amodra at gmail dot com changed:

   What|Removed |Added

 Status|REOPENED|RESOLVED
 CC|amodra at gmail dot com|
 Resolution|--- |FIXED
   Target Milestone|--- |2.25

--- Comment #8 from Alan Modra amodra at gmail dot com ---
fixed

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

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gold/17670] internal error in symval_for_branch, at powerpc.cc:6755 during qt5 build

2014-12-02 Thread amodra at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=17670

--- Comment #3 from Alan Modra amodra at gmail dot com ---
I don't know enough C++ to say anything authoritive about the testcase but it
seems to me that either the testcase is invalid or mainline g++ is broken,
probably the latter.

The reason I say that is that qmimeglobpattern.o contains this group
COMDAT group section [1] `.group' [_ZN5QListI7QStringED5Ev] contains 1
sections:
   [Index]Name
   [   11]   .text._ZN5QListI7QStringED2Ev
defining the function _ZN5QListI7QStringED2Ev

and qmimeprovider.o this group
COMDAT group section [1] `.group' [_ZN5QListI7QStringED5Ev] contains 2
sections:
   [Index]Name
   [8]   .text._ZN5QListI7QStringED2Ev
   [   12]   .gcc_except_table._ZN5QListI7QStringED2Ev
defining _ZN5QListI7QStringED1Ev and _ZN5QListI7QStringED2Ev

Since these are comdat groups, the first one is kept and the second dropped,
resulting in _ZN5QListI7QStringED1Ev being undefined.  The sym is weak so that
in itself doesn't cause a link failure, but does result in runtime failure even
on x86_64.  I can simply change the assertion to a condition in powerpc.cc
which will result in exactly the same runtime failure on powerpc..  Now it
happens that _ZN5QListI7QStringED1Ev and _ZN5QListI7QStringED2Ev are aliases in
the second group, but I don't think ld has any business trying to map symbols
across to the kept section.

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

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug gold/17670] internal error in symval_for_branch, at powerpc.cc:6755 during qt5 build

2014-12-02 Thread markus at trippelsdorf dot de
https://sourceware.org/bugzilla/show_bug.cgi?id=17670

Markus Trippelsdorf markus at trippelsdorf dot de changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
URL||https://gcc.gnu.org/bugzill
   ||a/show_bug.cgi?id=64163
 Resolution|--- |MOVED

--- Comment #4 from Markus Trippelsdorf markus at trippelsdorf dot de ---
Moved to https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64163

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

___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils