From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: Pedro Alves <palves@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [patch+7.5.1] Work around PR libc/13097 "linux-vdso.so.1" #3
Date: Fri, 23 Nov 2012 12:40:00 -0000 [thread overview]
Message-ID: <20121123123952.GA15371@host2.jankratochvil.net> (raw)
In-Reply-To: <50AF65E1.1090308@redhat.com>
On Fri, 23 Nov 2012 13:02:41 +0100, Pedro Alves wrote:
> Won't real file based DSOs in the loader list _always_ be full paths,
> never relative paths? I'd think we could always ignore DSOs whose
> path doesn't start with '/', everywhere.
:|gcc -shared -fPIC -o x.so -x c -;echo 'main(){}'|gcc -o x ./x.so -x c -;gdb ./x -ex start -ex 'p *_r_debug.r_map' -ex 'p *_r_debug.r_map.l_next' -ex 'p *_r_debug.r_map.l_next.l_next' -ex 'p *_r_debug.r_map.l_next.l_next.l_next' -ex 'p *_r_debug.r_map.l_next.l_next.l_next.l_next' -ex 'p *_r_debug.r_map.l_next.l_next.l_next.l_next.l_next'
$1 = {l_addr = 0, l_name = 0x37e3a1bd69 "", l_ld = 0x600778, l_next = 0x37e3c23818, l_prev = 0x0}
$2 = {l_addr = 140737363566592, l_name = 0x37e3a1bd69 "", l_ld = 0x7ffff7ffe488, l_next = 0x7ffff7ffd648, l_prev = 0x37e3c23288}
$3 = {l_addr = 140737352024064, l_name = 0x7ffff7ffd640 "./x.so", l_ld = 0x7ffff7ffc5e8, l_next = 0x7ffff7dd5000, l_prev = 0x37e3c23818}
^^^^^^^^
$4 = {l_addr = 0, l_name = 0x7ffff7ffdb60 "/lib64/libc.so.6", l_ld = 0x37e45b0b40, l_next = 0x37e3c22998, l_prev = 0x7ffff7ffd648}
$5 = {l_addr = 0, l_name = 0x400200 "/lib64/ld-linux-x86-64.so.2", l_ld = 0x37e3c21de8, l_next = 0x0, l_prev = 0x7ffff7dd5000}
So file based solibs do not have to start with '/'.
Besides that there is no standard for any such rule and I consider this patch
only as a workaround of a WONTFIXed glibc PR. In such case I believe the
impact should be minimal.
Maybe there is even a way how to make l_name really "x.so" above, not sure.
Jan
next prev parent reply other threads:[~2012-11-23 12:40 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-22 20:17 Jan Kratochvil
2012-11-23 11:30 ` Luis Gustavo
2012-11-23 11:41 ` Jan Kratochvil
2012-11-23 11:59 ` Luis Machado
2012-11-23 12:03 ` Pedro Alves
2012-11-23 12:40 ` Jan Kratochvil [this message]
2012-11-23 14:05 ` Luis Machado
2012-11-23 14:07 ` Jan Kratochvil
2012-11-23 16:01 ` Pedro Alves
2012-11-23 16:12 ` Mark Kettenis
2012-11-23 16:17 ` Jan Kratochvil
2012-11-23 16:23 ` Pedro Alves
2012-11-23 17:28 ` Joel Brobecker
2012-11-23 18:17 ` Jan Kratochvil
2012-11-23 18:22 ` Pedro Alves
2012-11-27 21:58 ` Mike Frysinger
2012-11-27 23:00 ` Matt Rice
2012-11-28 1:12 ` Pedro Alves
2012-11-28 20:39 ` Mike Frysinger
2012-11-28 22:44 ` Jan Kratochvil
2012-11-29 1:07 ` Mike Frysinger
2012-11-23 12:43 ` Mark Kettenis
2012-11-23 16:30 ` H.J. Lu
2012-11-23 18:19 ` Pedro Alves
2012-11-23 18:43 ` Jan Kratochvil
2012-11-25 18:15 ` Jan Kratochvil
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20121123123952.GA15371@host2.jankratochvil.net \
--to=jan.kratochvil@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=palves@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox