From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/1029 Path: news.gmane.org!not-for-mail From: Ivan Kanakarakis Newsgroups: gmane.linux.lib.musl.general Subject: Re: _GLOBAL_OFFSET_TABLE_ in ldso/*/start.s? Date: Sat, 9 Jun 2012 02:21:39 +0300 Message-ID: References: <10988613.MPE7PukreT@main.pennware.com> <20120608223138.GW163@brightrain.aerifal.cx> <1607F838-B823-40E7-882F-B4D24852AE94@pennware.com> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=e89a8ff1c2e8faf6b004c1fe4479 X-Trace: dough.gmane.org 1339197744 23984 80.91.229.3 (8 Jun 2012 23:22:24 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 8 Jun 2012 23:22:24 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-1030-gllmg-musl=m.gmane.org@lists.openwall.com Sat Jun 09 01:22:23 2012 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1Sd8Va-0005Do-Is for gllmg-musl@plane.gmane.org; Sat, 09 Jun 2012 01:22:22 +0200 Original-Received: (qmail 30103 invoked by uid 550); 8 Jun 2012 23:22:22 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 30095 invoked from network); 8 Jun 2012 23:22:22 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=Q8q6mgr0JTkEAM7cFiZAJmx7nLy3l6qGOn9YkBgwg4A=; b=SB5FPqXAYaPh5Qq796NeCGm74Nh4e0etks91UJ3PVaEpJrvijvHS6e2HAMZQO4mvgz wwA9POrQZNcs1KVbzrmAbRjcNAqpUu2fQ4RE0QqZAKbqat2F3AWzv3a6ik47Wc27FcSZ w3G5eoldUKm1Dy7Z7pFYI03PUAHZCquxsPy8oY8hyRVLfixoRu4dgZFu0zuxz/UxpJ+L u3TeQI4tTqhEWZMfqt8yhDzelTXVPIrrXmyBWlNmnsO+fdL6JhF2PrfWGCaoA1knKhay +TpxsJbJD344+f9JEWDIW7HOIG9U9odW9nu97graeAPz9p5IiF9gS1RrXzbbLbml6s4N sgSg== In-Reply-To: <1607F838-B823-40E7-882F-B4D24852AE94@pennware.com> Xref: news.gmane.org gmane.linux.lib.musl.general:1029 Archived-At: --e89a8ff1c2e8faf6b004c1fe4479 Content-Type: text/plain; charset=ISO-8859-1 many online books out there, people tend to like "Pro Git" [0] that was merged with the community git book and "git ready" [1] [0]: http://git-scm.com/book [1]: http://gitready.com/ very simple stuff to get you started looking at changes, would be: $ git clone git://git.etalabs.net/musl $ cd musl # see the history for the repo $ git log # see the history for a file $ git log -- Makefile # see only the last 5 commits/changes to a file by line $ git log -5 --oneline -- WHATSNEW # see diff between current state and a commit/point in the past $ git diff 2d3e2a7 # see diff between two states $ git diff 8a35dee 2d3e2a7 # show info (message and diff from its previous state) about a commit/change $ git show 83023d1 On 9 June 2012 01:43, Richard Pennington wrote: > Thanks Rich. Becoming familiar with git is definitely on my todo list. > > -Rich > > Sent from my iPhone > > On Jun 8, 2012, at 5:31 PM, Rich Felker wrote: > > > On Fri, Jun 08, 2012 at 03:54:46PM -0500, Richard Pennington wrote: > >> What is the purpose of the _GLOBAL_OFFSET_TABLE_ reference in these > files? It > >> doesn't seem to be used by __dynlink(), although it seems to be passed > a a > >> third parameter. > > > > If you check git, you'll see that this code was removed. A much older > > version of __dynlink took a third argument that was the base address > > of the GOT, which was used to find a pointer to _DYNAMIC in the first > > GOT slot (traditionally, it was stored there). Then people started > > reporting crashes when linking with a non-binutils linker (gold? or > > something from clang/llvm? I don't remember...) that didn't follow > > this practice, so I replaced it with more elaborate code to find > > _DYNAMIC. The unneeded code in the asm was not removed until much > > later. I actually have a new idea for simplifying/replacing some of > > the C code, but it won't affect the asm. > > > > By the way, it might be a good idea to familiarize yourself with git > > or even the gitweb interface. Questions like the one you had just now > > can usually be answered quickly by checking the history of the > > relevant files. > > > > Rich > -- *Ivan c00kiemon5ter V Kanakarakis* >:3 --e89a8ff1c2e8faf6b004c1fe4479 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
many online books out there,=A0people tend=A0
to like "= Pro Git" [0] that was merged with
the=A0community git book a= nd "git ready" [1]

=A0 [1]:=A0http://gitready.com/


very simple stuff to get you started= =A0
looking at changes, would be:

$ git = clone git://git.etalabs.net/musl
$ cd musl

# see the history for the repo=A0
$ git lo= g=A0

# see the history for a file
$ git = log -- Makefile

# see only the last 5 commits/chan= ges to a file by line
$ git log -5 --oneline -- WHATSNEW

# see diff= between current state and a commit/point in the past
$ git diff= =A02d3e2a7

# see dif= f between two states
$ git diff=A08a35dee 2d3e2a7

# show info (mes= sage and diff from its previous state) about a commit/change
$ gi= t show=A083023d1



On 9 June 2012 01:43, Richard Pennington <rich@pennware.com>= wrote:
Thanks Rich. Becoming familiar with git is definitely on my todo list.

-Rich

Sent from my iPhone

On Jun 8, 2012, at 5:31 PM, Rich Felker <dalias@aerifal.cx> wrote:

> On Fri, Jun 08, 2012 at 03:54:46PM -0500, Richard Pennington wrote: >> What is the purpose of the _GLOBAL_OFFSET_TABLE_ reference in thes= e files? It
>> doesn't seem to be used by __dynlink(), although it seems to b= e passed a a
>> third parameter.
>
> If you check git, you'll see that this code was removed. A much ol= der
> version of __dynlink took a third argument that was the base address > of the GOT, which was used to find a pointer to _DYNAMIC in the first<= br> > GOT slot (traditionally, it was stored there). Then people started
> reporting crashes when linking with a non-binutils linker (gold? or > something from clang/llvm? I don't remember...) that didn't fo= llow
> this practice, so I replaced it with more elaborate code to find
> _DYNAMIC. The unneeded code in the asm was not removed until much
> later. I actually have a new idea for simplifying/replacing some of > the C code, but it won't affect the asm.
>
> By the way, it might be a good idea to familiarize yourself with git > or even the gitweb interface. Questions like the one you had just now<= br> > can usually be answered quickly by checking the history of the
> relevant files.
>
> Rich



--
=
Ivan c00kiemon5ter V Kanakarakis =A0>:3=A0
<= br>
--e89a8ff1c2e8faf6b004c1fe4479--