From: Bruce Dawson <bruced@valvesoftware.com>
To: 'Doug Evans' <dje@google.com>
Cc: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>,
gdb-patches <gdb-patches@sourceware.org>
Subject: RE: New feature "source-id"
Date: Tue, 18 Mar 2014 17:44:00 -0000 [thread overview]
Message-ID: <2AC155A009400B4C8B05D518E4819AEF1A347F4C@exchange10.valvesoftware.com> (raw)
In-Reply-To: <CADPb22QJ7bQdn+0hHYLw_f-wkTOzjFykBHuHRf9DKOrPDu1OrA@mail.gmail.com>
I better understand what you are doing now with the .c file now. Previously I had assumed that you would be compiling it and then linking the .o file along with all of the others.
Now I am confused about *why* you are compiling it. If you have a text file that has the source information then why not just add it as a custom section directly? What is the value in compiling it into a .o file first?
> I can imagine generating a .c file (say, could even be .S) from the post-link binary that contains source information
Don't forget that this text file is generated from both the source files listed in the post-link binary *and* from the version control information for these files.
-----Original Message-----
From: Doug Evans [mailto:dje@google.com]
Sent: Monday, March 17, 2014 6:39 PM
To: Bruce Dawson
Cc: Gerhard Gappmeier; gdb-patches
Subject: Re: New feature "source-id"
...
I can imagine generating a .c file (say, could even be .S) from the post-link binary that contains source information, compile it, and then using objcopy to add the resultant section with the source information into the resultant binary. The key here being that source file information gets put in a specific section so it's easy to do this. If one is splitting the debug information into a separate file, one could objcopy --add-section the source-file-section there instead.
There's no real "relinking" here. I don't see the difference with what you're doing now.
...
next prev parent reply other threads:[~2014-03-18 17:44 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-15 10:49 Gerhard Gappmeier
2014-03-15 17:32 ` Doug Evans
2014-03-15 20:06 ` Eli Zaretskii
2014-03-16 2:34 ` Doug Evans
2014-03-16 9:43 ` Gerhard Gappmeier
2014-03-16 16:22 ` Doug Evans
2014-03-16 16:34 ` Eli Zaretskii
2014-03-17 8:49 ` Gerhard Gappmeier
2014-03-17 12:25 ` Matt Rice
2014-03-17 19:01 ` Gerhard Gappmeier
2014-03-18 0:25 ` Doug Evans
2014-03-18 0:48 ` Bruce Dawson
2014-03-18 1:39 ` Doug Evans
2014-03-18 17:44 ` Bruce Dawson [this message]
2014-03-18 17:57 ` Doug Evans
2014-03-18 13:22 ` Mark Wielaard
2014-03-18 14:00 ` Gerhard Gappmeier
2014-03-18 15:03 ` Mark Wielaard
2014-03-18 16:40 ` Gerhard Gappmeier
2014-03-18 17:56 ` Bruce Dawson
2014-05-21 19:30 ` Tom Tromey
2014-05-21 20:42 ` Bruce Dawson
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=2AC155A009400B4C8B05D518E4819AEF1A347F4C@exchange10.valvesoftware.com \
--to=bruced@valvesoftware.com \
--cc=dje@google.com \
--cc=gdb-patches@sourceware.org \
--cc=gerhard.gappmeier@ascolab.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