[Bug binutils/21725] [2.29 Regression] binutils fails to build glibc-2.24 on aarch64-linux-gnu and arm-linux-gnueabihf

2017-07-11 Thread adconrad at 0c3 dot net
https://sourceware.org/bugzilla/show_bug.cgi?id=21725

Adam Conrad  changed:

   What|Removed |Added

 CC||adconrad at 0c3 dot net

--- Comment #4 from Adam Conrad  ---
Can confirm both comments, the upstream commit pointed to does fix aarch64, and
I can reproduce that identical backtrace on armhf.

-- 
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 binutils/21725] [2.29 Regression] binutils fails to build glibc-2.24 on aarch64-linux-gnu and arm-linux-gnueabihf

2017-07-11 Thread adconrad at 0c3 dot net
https://sourceware.org/bugzilla/show_bug.cgi?id=21725

--- Comment #5 from Adam Conrad  ---
Note that you don't really need to do anything fancy like try to reproduce the
testsuite environment (or, indeed, try to call localedef), just invoking the
freshly-built ld-linux-armhf.so.3 by itself is enough to show the damage.

-- 
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 ld/12762] LTO on Windows is broken (C++)

2017-07-11 Thread spam.martin.schulze at gmx dot de
https://sourceware.org/bugzilla/show_bug.cgi?id=12762

Martin Schulze  changed:

   What|Removed |Added

 CC||spam.martin.schulze at gmx dot 
de

--- Comment #32 from Martin Schulze  ---
I am seeing this issue while cross-compiling Qt 5.9.0 on Arch Linux via
x86_64-w64-mingw32-g++ 7.1.1 with (slim) LTO enabled (the error is reported
when linking Qt5Gui.dll):

$ x86_64-w64-mingw32-g++ -flto-partition=none -Wl,-s -shared
-fno-keep-inline-dllexport -pipe -O3 -std=c++1z -flto=4 -fno-fat-lto-objects
-fuse-linker-plugin -Wl,-subsystem,windows -Wl,--out-implib,/libQt5Gui.a -o ../../lib/Qt5Gui.dll 
.obj/release/qimage_compat.o (symbol from
plugin):(.gnu.linkonce.t._ZTS12QPaintDevice+0x0): multiple definition of
`typeinfo name for QPaintDevice'
.obj/release/qimage_ssse3.o:qimage_ssse3.cpp:(.rdata$_ZTS12QPaintDevice[_ZTS12QPaintDevice]+0x0):
first defined here
.obj/release/qimage_compat.o (symbol from
plugin):(.gnu.linkonce.t._ZTI12QPaintDevice+0x0): multiple definition of
`typeinfo for QPaintDevice'
.obj/release/qimage_ssse3.o:qimage_ssse3.cpp:(.rdata$_ZTI12QPaintDevice[_ZTI12QPaintDevice]+0x0):
first defined here
.obj/release/qimage_compat.o (symbol from
plugin):(.gnu.linkonce.t._ZTS6QImage+0x0): multiple definition of `typeinfo
name for QImage'
.obj/release/qimage_ssse3.o:qimage_ssse3.cpp:(.rdata$_ZTS6QImage[_ZTS6QImage]+0x0):
first defined here
.obj/release/qimage_compat.o (symbol from
plugin):(.gnu.linkonce.t._ZTI6QImage+0x0): multiple definition of `typeinfo for
QImage'
.obj/release/qimage_ssse3.o:qimage_ssse3.cpp:(.rdata$_ZTI6QImage[_ZTI6QImage]+0x0):
first defined here
.obj/release/qaccessible.o (symbol from
plugin):(.gnu.linkonce.t._ZTS7QPixmap+0x0): multiple definition of `typeinfo
name for QPixmap'
.obj/release/qdrawhelper_ssse3.o:qdrawhelper_ssse3.cpp:(.rdata$_ZTS7QPixmap[_ZTS7QPixmap]+0x0):
first defined here
.obj/release/qaccessible.o (symbol from
plugin):(.gnu.linkonce.t._ZTI7QPixmap+0x0): multiple definition of `typeinfo
for QPixmap'
.obj/release/qdrawhelper_ssse3.o:qdrawhelper_ssse3.cpp:(.rdata$_ZTI7QPixmap[_ZTI7QPixmap]+0x0):
first defined here

I tried -flto-partition=none without success while
-Wl,-allow-multiple-definition seems to have worked.

-- 
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/21751] New: Gold: GC of C++ functions behaves differently than LD.BFD with KEEP(*(.eh_frame))

2017-07-11 Thread jan.smets at nokia dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=21751

Bug ID: 21751
   Summary: Gold: GC of C++ functions behaves differently than
LD.BFD with KEEP(*(.eh_frame))
   Product: binutils
   Version: 2.29
Status: UNCONFIRMED
  Severity: enhancement
  Priority: P2
 Component: gold
  Assignee: ccoutant at gmail dot com
  Reporter: jan.smets at nokia dot com
CC: ian at airs dot com
  Target Milestone: ---

$ cat call.c main.c  unused.cpp 
void call(void)
{
// nothing
}
extern void call(void);

int main(void)
{
call();
return 0;
}
void unused(void)
{
// nothing
}


# build some "default" link script
# /opt/rh/devtoolset-6/root/usr/bin/ld --verbose > /tmp/link_script
# remove the header and footer, remove the SORT (otherwise gold won't accept
it)
# the only thing that is required in the link script is
#  .eh_frame   : ONLY_IF_RO { KEEP (*(.eh_frame)) *(.eh_frame.*) }


/opt/rh/devtoolset-6/root/usr/bin/gcc -ffunction-sections -c call.c -o call.o 
/opt/rh/devtoolset-6/root/usr/bin/gcc -ffunction-sections -c main.c -o main.o 
/opt/rh/devtoolset-6/root/usr/bin/g++ -ffunction-sections -c unused.cpp -o
unused.o -fno-exceptions

LD=ld.gold

/opt/rh/devtoolset-6/root/usr/bin/$LD -r main.o call.o unused.o -o bla.a

echo "unused function is GC'ed"
/opt/rh/devtoolset-6/root/usr/bin/$LD --gc-sections --print-gc-sections bla.a
-o test.exe -e main
echo
/opt/rh/devtoolset-6/root/usr/bin/$LD --gc-sections --print-gc-sections main.o
call.o unused.o -o test.exe -e main

echo "unused function is *NOT* GC'ed"
/opt/rh/devtoolset-6/root/usr/bin/$LD --gc-sections --print-gc-sections bla.a
-o test.exe  -T /tmp/link_script -e main
echo
/opt/rh/devtoolset-6/root/usr/bin/$LD --gc-sections --print-gc-sections main.o
call.o unused.o -o test.exe  -T /tmp/link_script -e main

# ld.gold + link script (-T) where the script has 
#   .eh_frame   : ONLY_IF_RO { KEEP (*(.eh_frame)) *(.eh_frame.*) }
# ld.bfd behaves 'as expected'

unused.o has

Relocation section '.rela.eh_frame' at offset 0x1b8 contains 1 entries:
  Offset  Info   Type   Sym. ValueSym. Name +
Addend
0020  00050002 R_X86_64_PC32  .text._Z6unusedv
+ 0

Let's call it a feature as the script explicitly said to KEEP eh_frame and as a
result everything that eh_framer references. But it may not be what end users
expect. Plus, LD.BFD happily removed the 'unused' function.

-- 
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/21491] --fix-cortex-a53-843419 Errata workaround can produce broken images

2017-07-11 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=21491

--- Comment #1 from cvs-commit at gcc dot gnu.org  ---
The master branch has been updated by Han Shen :

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

commit df2f63a6a0fc19c54e58aab8afe262baf3cb1a3c
Author: Han Shen 
Date:   Mon Jul 10 15:23:05 2017 -0700

Fixing for PR gold/21491 - Errata workaround can produce broken images.

The problem is caused by the fact that gold is relocating the stubs
for an entire output section when it processes the relocations for a
particular input section that happened to be designated as the stub
table "owner". The Relocate_task for that input section may or may not
run before the Relocate_task for another input section that contains
the code that needs the erratum fix, but doesn't "own" the stub
table. If it runs before (or might even race with) that other task, it
ends up with a copy of the unrelocated original instruction.

In other words - when calling fix_errata() from
do_relocate_sections(), gold is going through the list of errata stubs
that are associated only with that object. This routine updates the
stored original instruction and replaces it in the output view with a
branch to the stub. Later, as gold is going through the object file's
input sections, it then checks for stub tables "owned" by each input
section, and writes out all the stubs from that stub table, regardless
of what object file each stub is associated with.

Fixed by relocating the erratum stub only after the corresponding
errata spot is fixed. That is to have fix_errata() call
Stub_table::relocate_erratum_stub() for each stub.

gold/ChangeLog
2017-07-06  Han Shen  

PR gold/21491

* aarch64.cc (Erratum_stub::invalidate_erratum_stub): New method.
(Erratum_stub::is_invalidated_erratum_stub): New method.
(Stub_table::relocate_reloc_stub): Renamed from "relocate_stub".
(Stub_table::relocate_reloc_stubs): Renamed from "relocate_stubs".
(Stub_table::relocate_erratum_stub): New method.
(AArch64_relobj::fix_errata_and_relocate_erratum_stubs): Renamed from
"fix_errata".
(Target_aarch64::relocate_reloc_stub): Renamed from "relocate_stub".

-- 
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/21491] --fix-cortex-a53-843419 Errata workaround can produce broken images

2017-07-11 Thread ccoutant at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=21491

Cary Coutant  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 CC||ccoutant at gmail dot com
 Resolution|--- |FIXED

--- Comment #2 from Cary Coutant  ---
Fixed on trunk. Does this need to be backported?

-- 
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/21491] --fix-cortex-a53-843419 Errata workaround can produce broken images

2017-07-11 Thread shenhan at google dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=21491

--- Comment #3 from Han Shen  ---
(In reply to Cary Coutant from comment #2)
> Fixed on trunk. Does this need to be backported?

Yes, considering the severity of the bug.

-- 
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 binutils/21732] String-concatenated message can not be translated

2017-07-11 Thread amodra at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=21732

Alan Modra  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2017-07-12
 CC||amodra at gmail dot com
 Ever confirmed|0   |1

--- Comment #1 from Alan Modra  ---
For anyone looking at this bug, note that strings split to keep source line
lengths below 80 chars are happily combined and appear in the .pot files. 
Preprocessor tokens like DWARF_VMA_FMT are definitely a problem.

-- 
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