* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
@ 2011-04-03 17:04 ` hjl.tools at gmail dot com
2011-04-03 17:34 ` vincenzo.innocente at cern dot ch
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2011-04-03 17:04 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
H.J. Lu <hjl.tools at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |hjl.tools at gmail dot com
--- Comment #1 from H.J. Lu <hjl.tools at gmail dot com> 2011-04-03 17:04:43 UTC ---
You can try hjl/lto-mixed branch from
http://git.kernel.org/?p=devel/binutils/hjl/x86.git;a=summary
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
2011-04-03 17:04 ` [Bug lto/48423] " hjl.tools at gmail dot com
@ 2011-04-03 17:34 ` vincenzo.innocente at cern dot ch
2011-04-03 18:06 ` hjl.tools at gmail dot com
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: vincenzo.innocente at cern dot ch @ 2011-04-03 17:34 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #2 from vincenzo Innocente <vincenzo.innocente at cern dot ch> 2011-04-03 17:34:18 UTC ---
thanks hl,
it looks promising.
the thets runs and
nm -C -D libBase.o
shows
0000000000201140 V typeinfo for Base
0000000000000fb3 V typeinfo name for Base
like gold
I will test it more tomorrow.
Will you merge this in next binutil snapshot?
vincenzo
On 3 Apr, 2011, at 7:04 PM, hjl.tools at gmail dot com wrote:
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
>
> H.J. Lu <hjl.tools at gmail dot com> changed:
>
> What |Removed |Added
> ----------------------------------------------------------------------------
> CC| |hjl.tools at gmail dot com
>
> --- Comment #1 from H.J. Lu <hjl.tools at gmail dot com> 2011-04-03 17:04:43 UTC ---
> You can try hjl/lto-mixed branch from
>
> http://git.kernel.org/?p=devel/binutils/hjl/x86.git;a=summary
>
> --
> Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email
> ------- You are receiving this mail because: -------
> You reported the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
2011-04-03 17:04 ` [Bug lto/48423] " hjl.tools at gmail dot com
2011-04-03 17:34 ` vincenzo.innocente at cern dot ch
@ 2011-04-03 18:06 ` hjl.tools at gmail dot com
2011-04-03 20:05 ` vincenzo.innocente at cern dot ch
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2011-04-03 18:06 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> 2011-04-03 18:06:23 UTC ---
(In reply to comment #2)
> thanks hl,
> it looks promising.
> the thets runs and
> nm -C -D libBase.o
> shows
> 0000000000201140 V typeinfo for Base
> 0000000000000fb3 V typeinfo name for Base
> like gold
>
> I will test it more tomorrow.
> Will you merge this in next binutil snapshot?
>
It isn't up to me. But it is in the latest Linux binutils from:
http://www.kernel.org/pub/linux/devel/binutils/
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (2 preceding siblings ...)
2011-04-03 18:06 ` hjl.tools at gmail dot com
@ 2011-04-03 20:05 ` vincenzo.innocente at cern dot ch
2011-05-11 22:07 ` paolo.carlini at oracle dot com
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: vincenzo.innocente at cern dot ch @ 2011-04-03 20:05 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #4 from vincenzo Innocente <vincenzo.innocente at cern dot ch> 2011-04-03 20:05:37 UTC ---
thanks for the hint.
the version on
http://www.kernel.org/pub/linux/devel/binutils/binutils-2.21.51.0.7.x86_64.tar.bz2
seems to be ok
it also produces (as the one in your branch) a correct stacktrace
the version of gold (ld -v GNU gold (Linux/GNU Binutils 2.21.51.0.7.20110306)
1.11)
instead produced still a corrupted stack trace as in 2.2.1 (see below)
I submitted a bug report to binutil using a different test case. let's see if
there is any feedback on that
vincenzo
from gdb when using gold
---------------------------------------------------------------
b bhook
Function "bhook" not defined.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 1 (bhook) pending.
(gdb) run
…..
Breakpoint 1, 0x00007ffff7ec90e0 in bhook () from ./plugD.so
Missing separate debuginfos, use: debuginfo-install
glibc-2.12-1.7.el6_0.4.x86_64
(gdb) where
#0 0x00007ffff7ec90e0 in bhook () from ./plugD.so
#1 0x00007ffff7ec9199 in global constructors keyed to
65535_0_ccdzuBFD.o.3947.2223 () from ./plugD.so
#2 0x00007fffffffd348 in ?? ()
#3 0x00007ffff7ec7778 in ?? () from ./plugD.so
#4 0x00007ffff7ecab60 in __CTOR_LIST__ () from ./plugD.so
#5 0x00007fffffffd310 in ?? ()
#6 0x0000000000403800 in ?? ()
#7 0x00007ffff7ec92f5 in __do_global_ctors_aux () from ./plugD.so
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
--------------------------------------------
same using the "new" ld.bfd
Breakpoint 1, 0x00007ffff78cbfa0 in bhook () from ./plugD.so
Missing separate debuginfos, use: debuginfo-install
glibc-2.12-1.7.el6_0.4.x86_64
(gdb) where
#0 0x00007ffff78cbfa0 in bhook () from ./plugD.so
#1 0x00007ffff78cb889 in global constructors keyed to
65535_0_ccdhvqmO.o.3947.2223 () from ./plugD.so
#2 0x0000003ff520e3ff in _dl_init_internal () from /lib64/ld-linux-x86-64.so.2
#3 0x0000003ff5212b21 in dl_open_worker () from /lib64/ld-linux-x86-64.so.2
#4 0x0000003ff520e016 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#5 0x0000003ff521236a in _dl_open () from /lib64/ld-linux-x86-64.so.2
#6 0x0000003ff5a00f66 in dlopen_doit () from /lib64/libdl.so.2
#7 0x0000003ff520e016 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#8 0x0000003ff5a0129c in _dlerror_run () from /lib64/libdl.so.2
#9 0x0000003ff5a00ee1 in dlopen@@GLIBC_2.2.5 () from /lib64/libdl.so.2
#10 0x000000000040119d in get ()
#11 0x0000000000400e78 in main ()
On 3 Apr, 2011, at 8:06 PM, hjl.tools at gmail dot com wrote:
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
>
> --- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> 2011-04-03 18:06:23 UTC ---
> (In reply to comment #2)
>> thanks hl,
>> it looks promising.
>> the thets runs and
>> nm -C -D libBase.o
>> shows
>> 0000000000201140 V typeinfo for Base
>> 0000000000000fb3 V typeinfo name for Base
>> like gold
>>
>> I will test it more tomorrow.
>> Will you merge this in next binutil snapshot?
>>
>
> It isn't up to me. But it is in the latest Linux binutils from:
>
> http://www.kernel.org/pub/linux/devel/binutils/
>
> --
> Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email
> ------- You are receiving this mail because: -------
> You reported the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (3 preceding siblings ...)
2011-04-03 20:05 ` vincenzo.innocente at cern dot ch
@ 2011-05-11 22:07 ` paolo.carlini at oracle dot com
2011-05-11 22:51 ` hjl.tools at gmail dot com
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: paolo.carlini at oracle dot com @ 2011-05-11 22:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #5 from Paolo Carlini <paolo.carlini at oracle dot com> 2011-05-11 21:19:10 UTC ---
HJ, sorry, I'm not sure to understand the process: do you normally submit this
kind of fix also to the "mainline" binutils? Can Vincenzo do something specific
to help the process? (about the GOLD-related issue (PR48384) I'm asking Ian's
opinion in that audit trail)
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (4 preceding siblings ...)
2011-05-11 22:07 ` paolo.carlini at oracle dot com
@ 2011-05-11 22:51 ` hjl.tools at gmail dot com
2011-05-14 18:38 ` vincenzo.innocente at cern dot ch
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2011-05-11 22:51 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #6 from H.J. Lu <hjl.tools at gmail dot com> 2011-05-11 22:30:32 UTC ---
(In reply to comment #5)
> HJ, sorry, I'm not sure to understand the process: do you normally submit this
> kind of fix also to the "mainline" binutils? Can Vincenzo do something specific
> to help the process? (about the GOLD-related issue (PR48384) I'm asking Ian's
> opinion in that audit trail)
I think the current binutils in CVS is OK.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (5 preceding siblings ...)
2011-05-11 22:51 ` hjl.tools at gmail dot com
@ 2011-05-14 18:38 ` vincenzo.innocente at cern dot ch
2012-05-07 12:31 ` rguenth at gcc dot gnu.org
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: vincenzo.innocente at cern dot ch @ 2011-05-14 18:38 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #7 from vincenzo Innocente <vincenzo.innocente at cern dot ch> 2011-05-14 17:24:12 UTC ---
the snapshot
ftp://sourceware.org/pub/binutils/snapshots/binutils-2.21.51.tar.bz2
from 14/5/11 5:43:00 AM
seems ok for what ld.bdf is concerned (no warning, no crash, export correctly
"vtable and typeinfo")
unwind info is not perfect though:
(this is now with gcc version 4.6.1 20110422 (prerelease) (GCC)
--------------------
ld.bdf
GNU ld (GNU Binutils) 2.21.51.20110514
(gdb) where
#0 0x00007ffff74d4350 in bhook () from ./plugD.so
#1 0x00007ffff74d3c1b in global constructors keyed to
65535_0_ccXmBt7V.o.3972.2223 () from ./plugD.so
#2 0x00007ffff74d4485 in __do_global_ctors_aux () from ./plugD.so
#3 0x00007ffff74d3a33 in _init () from ./plugD.so
#4 0x0000003600000000 in ?? ()
#5 0x000000362d60e495 in _dl_init_internal () from /lib64/ld-linux-x86-64.so.2
#6 0x000000362d612be2 in dl_open_worker () from /lib64/ld-linux-x86-64.so.2
#7 0x000000362d60e0f6 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#8 0x000000362d61244a in _dl_open () from /lib64/ld-linux-x86-64.so.2
#9 0x000000362de00f66 in dlopen_doit () from /lib64/libdl.so.2
#10 0x000000362d60e0f6 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#11 0x000000362de0129c in _dlerror_run () from /lib64/libdl.so.2
#12 0x000000362de00ee1 in dlopen@@GLIBC_2.2.5 () from /lib64/libdl.so.2
#13 0x0000000000401b4d in get ()
#14 0x0000000000603058 in ?? ()
#15 0x00007fffffffd78f in ?? ()
#16 0x0000000000603088 in ?? ()
#17 0x00007ffff7b977f3 in std::basic_string<char, std::char_traits<char>,
std::allocator<char> >::basic_string(char const*, std::allocator<char> const&)
()
from /usr/local/lib64/libstdc++.so.6
#18 0x0000000000401828 in main ()
-----------------------
ld.gold
GNU gold (GNU Binutils 2.21.51.20110514) 1.11
(a bit better than before)
#0 0x00007ffff7ad1020 in bhook () from ./plugD.so
#1 0x00007ffff7ad10db in global constructors keyed to
65535_0_ccG5kmS1.o.3972.2223 () from ./plugD.so
#2 0x00007fffffffd298 in ?? ()
#3 0x00000000ffffd030 in ?? ()
#4 0x00007fffffffd298 in ?? ()
#5 0x00007ffff7ad2ad0 in __CTOR_LIST__ () from ./plugD.so
#6 0x00007fffffffd260 in ?? ()
#7 0x0000000000403800 in ?? ()
#8 0x0000000000403800 in ?? ()
#9 0x00007ffff7ad1245 in __do_global_ctors_aux () from ./plugD.so
#10 0x00007ffff7ad07d3 in _init () from ./plugD.so
#11 0x0000003600000000 in ?? ()
#12 0x000000362d60e495 in _dl_init_internal () from /lib64/ld-linux-x86-64.so.2
#13 0x000000362d612be2 in dl_open_worker () from /lib64/ld-linux-x86-64.so.2
#14 0x000000362d60e0f6 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#15 0x000000362d61244a in _dl_open () from /lib64/ld-linux-x86-64.so.2
#16 0x000000362de00f66 in dlopen_doit () from /lib64/libdl.so.2
#17 0x000000362d60e0f6 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#18 0x000000362de0129c in _dlerror_run () from /lib64/libdl.so.2
#19 0x000000362de00ee1 in dlopen@@GLIBC_2.2.5 () from /lib64/libdl.so.2
#20 0x00000000004016cd in get ()
#21 0x0000000000401858 in main ()
------------------------------------------------------------
ld.bdf from
http://www.kernel.org/pub/linux/devel/binutils/binutils-2.21.51.0.8.x86_64.tar.bz2
GNU ld (Linux/GNU Binutils) 2.21.51.0.8.20110408
Breakpoint 1, 0x00007ffff74d3f30 in bhook () from ./plugD.so
Missing separate debuginfos, use: debuginfo-install
glibc-2.12-1.7.el6_0.5.x86_64
(gdb) where
#0 0x00007ffff74d3f30 in bhook () from ./plugD.so
#1 0x00007ffff74d37fb in global constructors keyed to
65535_0_ccnS2aOK.o.3972.2223 () from ./plugD.so
#2 0x00007ffff74d4065 in __do_global_ctors_aux () from ./plugD.so
#3 0x00007ffff74d3613 in _init () from ./plugD.so
#4 0x0000003600000000 in ?? ()
#5 0x000000362d60e495 in _dl_init_internal () from /lib64/ld-linux-x86-64.so.2
#6 0x000000362d612be2 in dl_open_worker () from /lib64/ld-linux-x86-64.so.2
#7 0x000000362d60e0f6 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#8 0x000000362d61244a in _dl_open () from /lib64/ld-linux-x86-64.so.2
#9 0x000000362de00f66 in dlopen_doit () from /lib64/libdl.so.2
#10 0x000000362d60e0f6 in _dl_catch_error () from /lib64/ld-linux-x86-64.so.2
#11 0x000000362de0129c in _dlerror_run () from /lib64/libdl.so.2
#12 0x000000362de00ee1 in dlopen@@GLIBC_2.2.5 () from /lib64/libdl.so.2
#13 0x000000000040119d in get ()
#14 0x0000000000400e78 in main ()
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (6 preceding siblings ...)
2011-05-14 18:38 ` vincenzo.innocente at cern dot ch
@ 2012-05-07 12:31 ` rguenth at gcc dot gnu.org
2012-05-07 13:04 ` vincenzo.innocente at cern dot ch
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-05-07 12:31 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |WAITING
Last reconfirmed| |2012-05-07
Ever Confirmed|0 |1
--- Comment #8 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-05-07 12:27:30 UTC ---
Not exactly clear what this bug is about ...
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (7 preceding siblings ...)
2012-05-07 12:31 ` rguenth at gcc dot gnu.org
@ 2012-05-07 13:04 ` vincenzo.innocente at cern dot ch
2012-05-07 13:22 ` rguenth at gcc dot gnu.org
2012-05-09 13:29 ` vincenzo.innocente at cern dot ch
10 siblings, 0 replies; 12+ messages in thread
From: vincenzo.innocente at cern dot ch @ 2012-05-07 13:04 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #9 from vincenzo Innocente <vincenzo.innocente at cern dot ch> 2012-05-07 13:01:51 UTC ---
For what "we" are concerned it is obsolete.
1) things changed somehow between 4.6.0 and 4.6.1
2) is not there anymore in 4.7 and 4.8
in any case the original problem was most probably in binutil.
The unwind info issues I think were at some point fixed in lto
Please close it.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (8 preceding siblings ...)
2012-05-07 13:04 ` vincenzo.innocente at cern dot ch
@ 2012-05-07 13:22 ` rguenth at gcc dot gnu.org
2012-05-09 13:29 ` vincenzo.innocente at cern dot ch
10 siblings, 0 replies; 12+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-05-07 13:22 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |RESOLVED
Resolution| |FIXED
--- Comment #10 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-05-07 13:18:26 UTC ---
Good enough for me ;)
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug lto/48423] crash when using lto, linker plugin with bfd ld
2011-04-03 11:27 [Bug lto/48423] New: crash when using lto, linker plugin with bfd ld vincenzo.innocente at cern dot ch
` (9 preceding siblings ...)
2012-05-07 13:22 ` rguenth at gcc dot gnu.org
@ 2012-05-09 13:29 ` vincenzo.innocente at cern dot ch
10 siblings, 0 replies; 12+ messages in thread
From: vincenzo.innocente at cern dot ch @ 2012-05-09 13:29 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48423
--- Comment #11 from vincenzo Innocente <vincenzo.innocente at cern dot ch> 2012-05-09 13:16:30 UTC ---
I found the reference in the binutil bugzilla
http://sourceware.org/bugzilla/show_bug.cgi?id=12629
was fixed by Ian in gold on 2011-06-30.
^ permalink raw reply [flat|nested] 12+ messages in thread