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

Issue 6489067: code review 6489067: cmd/8g: import componentgen from 6g. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 8 months ago by remyoudompheng
Modified:
11 years, 8 months ago
Reviewers:
CC:
nigeltao, rsc, golang-dev, remy_archlinux.org
Visibility:
Public.

Description

cmd/8g: import componentgen from 6g. This makes the compilers code more similar and improves code generation a lot. The number of LEAL instructions generated for cmd/go drops by 60%. % GOARCH=386 go build -gcflags -S -a cmd/go | grep LEAL | wc -l Before: 89774 After: 47548 benchmark old ns/op new ns/op delta BenchmarkAppendFloatDecimal 540 444 -17.78% BenchmarkAppendFloat 1160 1035 -10.78% BenchmarkAppendFloatExp 1060 922 -13.02% BenchmarkAppendFloatNegExp 1053 920 -12.63% BenchmarkAppendFloatBig 1773 1558 -12.13% BenchmarkFormatInt 13065 12481 -4.47% BenchmarkAppendInt 10981 9900 -9.84% BenchmarkFormatUint 3804 3650 -4.05% BenchmarkAppendUint 3506 3303 -5.79% BenchmarkUnquoteEasy 714 683 -4.34% BenchmarkUnquoteHard 5117 2915 -43.03% Update issue 1914.

Patch Set 1 #

Patch Set 2 : diff -r 79225d9f3ced https://go.googlecode.com/hg/ #

Patch Set 3 : diff -r 79225d9f3ced https://go.googlecode.com/hg/ #

Patch Set 4 : diff -r 79225d9f3ced https://go.googlecode.com/hg/ #

Total comments: 2

Patch Set 5 : diff -r 0a0666f2fe86 https://go.googlecode.com/hg/ #

Patch Set 6 : diff -r cad5b70d58b6 https://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+170 lines, -1 line) Patch
M src/cmd/8g/cgen.c View 1 2 3 4 3 chunks +165 lines, -1 line 0 comments Download
M src/cmd/8g/gg.h View 1 1 chunk +1 line, -0 lines 0 comments Download
M src/cmd/8g/ggen.c View 1 2 3 1 chunk +4 lines, -0 lines 0 comments Download

Messages

Total messages: 11
remyoudompheng
Hello golang-dev@googlegroups.com (cc: golang-dev@googlegroups.com, remy@archlinux.org), I'd like you to review this change to https://go.googlecode.com/hg/
11 years, 8 months ago (2012-09-02 08:19:53 UTC) #1
remyoudompheng
Making the igen tweak on 6g also reduces the number of LEAQ (situation described in ...
11 years, 8 months ago (2012-09-02 08:21:30 UTC) #2
remyoudompheng
Hello golang-dev@googlegroups.com (cc: golang-dev@googlegroups.com, remy@archlinux.org), Please take another look.
11 years, 8 months ago (2012-09-02 10:25:59 UTC) #3
remyoudompheng
Added the similar use of componentgen for zeroing. The number of LEAL in cmd/go is ...
11 years, 8 months ago (2012-09-02 10:27:26 UTC) #4
remyoudompheng
Ping.
11 years, 8 months ago (2012-09-05 23:06:24 UTC) #5
nigeltao
https://codereview.appspot.com/6489067/diff/8002/src/cmd/8g/cgen.c File src/cmd/8g/cgen.c (right): https://codereview.appspot.com/6489067/diff/8002/src/cmd/8g/cgen.c#newcode781 src/cmd/8g/cgen.c:781: case OINDREG: 6g's igen doesn't do this. Should the ...
11 years, 8 months ago (2012-09-07 07:51:41 UTC) #6
remyoudompheng
On 2012/09/07 07:51:41, nigeltao wrote: > 6g's igen doesn't do this. Should the "igen is ...
11 years, 8 months ago (2012-09-07 17:34:24 UTC) #7
remyoudompheng
Hello nigeltao@golang.org, rsc@golang.org, golang-dev@googlegroups.com (cc: golang-dev@googlegroups.com, remy@archlinux.org), Please take another look.
11 years, 8 months ago (2012-09-09 08:04:32 UTC) #8
nigeltao
LGTM. Please delete the "Additionnally, igen is tweaked to be a no-op on INDREG registers." ...
11 years, 8 months ago (2012-09-09 09:44:39 UTC) #9
remyoudompheng
Updated the description and added "Update issue 1914." http://codereview.appspot.com/6489067/diff/8002/src/cmd/8g/cgen.c File src/cmd/8g/cgen.c (right): http://codereview.appspot.com/6489067/diff/8002/src/cmd/8g/cgen.c#newcode781 src/cmd/8g/cgen.c:781: case ...
11 years, 8 months ago (2012-09-09 18:21:16 UTC) #10
remyoudompheng
11 years, 8 months ago (2012-09-09 18:30:32 UTC) #11
*** Submitted as http://code.google.com/p/go/source/detail?r=9f6681feef6d ***

cmd/8g: import componentgen from 6g.

This makes the compilers code more similar and improves
code generation a lot.

The number of LEAL instructions generated for cmd/go drops
by 60%.

% GOARCH=386 go build -gcflags -S -a cmd/go | grep LEAL | wc -l
Before:       89774
After:        47548

benchmark                              old ns/op    new ns/op    delta
BenchmarkAppendFloatDecimal                  540          444  -17.78%
BenchmarkAppendFloat                        1160         1035  -10.78%
BenchmarkAppendFloatExp                     1060          922  -13.02%
BenchmarkAppendFloatNegExp                  1053          920  -12.63%
BenchmarkAppendFloatBig                     1773         1558  -12.13%
BenchmarkFormatInt                         13065        12481   -4.47%
BenchmarkAppendInt                         10981         9900   -9.84%
BenchmarkFormatUint                         3804         3650   -4.05%
BenchmarkAppendUint                         3506         3303   -5.79%
BenchmarkUnquoteEasy                         714          683   -4.34%
BenchmarkUnquoteHard                        5117         2915  -43.03%

Update issue 1914.

R=nigeltao, rsc, golang-dev
CC=golang-dev, remy
http://codereview.appspot.com/6489067
Sign in to reply to this message.

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