Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(55)

Issue 4524075: code review 4524075: ld: fix and simplify ELF symbol generation (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
13 years, 11 months ago by ality
Modified:
13 years, 10 months ago
Reviewers:
CC:
rsc, golang-dev
Visibility:
Public.

Description

ld: fix and simplify ELF symbol generation I started looking at this code because the nm in GNU binutils was ignoring the first symbol in the .symtab section. Apparently, the System V ABI reserves the first entry and requires all fields inside to be set to zero. The list of changes is as follows: · reserve the first symbol entry (as noted above) · fix the section indices for .data and .bss symbols · factor out common code for Elf32 and Elf64 · remove the special case for elfsymo in [568]l/asm.c:/^asmb · add the "etext" symbol in 6l · add static symbols

Patch Set 1 #

Patch Set 2 : diff -r 8e99d1651850 https://go.googlecode.com/hg/ #

Patch Set 3 : diff -r 8e99d1651850 https://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+70 lines, -129 lines) Patch
M src/cmd/5l/asm.c View 1 6 chunks +9 lines, -21 lines 0 comments Download
M src/cmd/6l/asm.c View 1 6 chunks +11 lines, -34 lines 0 comments Download
M src/cmd/8l/asm.c View 1 7 chunks +9 lines, -18 lines 0 comments Download
M src/cmd/ld/lib.h View 1 1 chunk +1 line, -2 lines 0 comments Download
M src/cmd/ld/symtab.c View 1 2 chunks +40 lines, -54 lines 0 comments Download

Messages

Total messages: 4
ality
Hello rsc@golang.org (cc: golang-dev@googlegroups.com), I'd like you to review this change to https://go.googlecode.com/hg/
13 years, 11 months ago (2011-05-27 12:38:31 UTC) #1
rsc
LGTM Thanks for cleaning that up.
13 years, 11 months ago (2011-05-31 16:47:07 UTC) #2
ality
rsc@golang.org once said: > LGTM > > Thanks for cleaning that up. Can you please ...
13 years, 11 months ago (2011-06-02 22:00:09 UTC) #3
rsc
13 years, 10 months ago (2011-06-07 18:26:22 UTC) #4
*** Submitted as http://code.google.com/p/go/source/detail?r=ceedefce68ad ***

ld: fix and simplify ELF symbol generation

I started looking at this code because the nm in GNU
binutils was ignoring the first symbol in the .symtab
section.  Apparently, the System V ABI reserves the
first entry and requires all fields inside to be set
to zero.

The list of changes is as follows:

  · reserve the first symbol entry (as noted above)
  · fix the section indices for .data and .bss symbols
  · factor out common code for Elf32 and Elf64
  · remove the special case for elfsymo in [568]l/asm.c:/^asmb
  · add the "etext" symbol in 6l
  · add static symbols

R=rsc
CC=golang-dev
http://codereview.appspot.com/4524075

Committer: Russ Cox <rsc@golang.org>
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b