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

Issue 93380044: code review 93380044: runtime: implement string ops in Go (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 1 month ago by khr
Modified:
10 years, 10 months ago
Reviewers:
gobot, rsc, khr1, bradfitz
CC:
golang-codereviews, dave_cheney.net, bradfitz, minux
Visibility:
Public.

Description

runtime: implement string ops in Go Also implement go:nosplit annotation. Not really needed for now, but we'll definitely need it for other conversions. benchmark old ns/op new ns/op delta BenchmarkRuneIterate 534 474 -11.24% BenchmarkRuneIterate2 535 470 -12.15%

Patch Set 1 #

Patch Set 2 : diff -r 391d6d71c738 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 3 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 4 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 5 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 6 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 7 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 8 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 9 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 10 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 11 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 12 : diff -r c9bcacf2ba33 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 13 : diff -r f866ee1cef9d https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 14 : diff -r f866ee1cef9d https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 15 : diff -r f866ee1cef9d https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 16 : diff -r f866ee1cef9d https://khr%40golang.org@code.google.com/p/go/ #

Total comments: 4

Patch Set 17 : diff -r 62285adb2b50 https://khr%40golang.org@code.google.com/p/go/ #

Total comments: 3

Patch Set 18 : diff -r 62285adb2b50 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 19 : diff -r 62285adb2b50 https://khr%40golang.org@code.google.com/p/go/ #

Patch Set 20 : diff -r 62285adb2b50 https://khr%40golang.org@code.google.com/p/go/ #

Total comments: 8
Unified diffs Side-by-side diffs Delta from patch set Stats (+787 lines, -652 lines) Patch
M src/cmd/gc/fmt.c View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M src/cmd/gc/go.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -0 lines 0 comments Download
M src/cmd/gc/go.y View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -0 lines 0 comments Download
M src/cmd/gc/lex.c View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +4 lines, -0 lines 0 comments Download
M src/cmd/gc/pgen.c View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +2 lines, -0 lines 0 comments Download
M src/cmd/gc/y.tab.c View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -0 lines 0 comments Download
M src/pkg/runtime/asm_386.s View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +6 lines, -0 lines 1 comment Download
M src/pkg/runtime/asm_amd64.s View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +6 lines, -0 lines 1 comment Download
M src/pkg/runtime/asm_amd64p32.s View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +6 lines, -0 lines 1 comment Download
M src/pkg/runtime/asm_arm.s View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +4 lines, -0 lines 1 comment Download
M src/pkg/runtime/error.go View 1 1 chunk +0 lines, -2 lines 0 comments Download
M src/pkg/runtime/race.go View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +3 lines, -0 lines 0 comments Download
A src/pkg/runtime/race0.go View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +11 lines, -0 lines 0 comments Download
R src/pkg/runtime/rune.c View 1 1 chunk +0 lines, -231 lines 0 comments Download
A src/pkg/runtime/rune.go View 1 2 1 chunk +219 lines, -0 lines 0 comments Download
A src/pkg/runtime/string.c View 1 2 3 4 5 6 7 8 1 chunk +199 lines, -0 lines 1 comment Download
A src/pkg/runtime/string.go View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +200 lines, -0 lines 2 comments Download
R src/pkg/runtime/string.goc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +0 lines, -418 lines 0 comments Download
M src/pkg/runtime/string_test.go View 1 2 1 chunk +24 lines, -0 lines 0 comments Download
A src/pkg/runtime/stubs.go View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +30 lines, -0 lines 0 comments Download
A src/pkg/runtime/stubs.goc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +66 lines, -0 lines 1 comment Download

Messages

Total messages: 12
khr
Hello golang-codereviews@googlegroups.com, I'd like you to review this change to https://khr%40golang.org@code.google.com/p/go/
10 years, 12 months ago (2014-06-16 23:52:04 UTC) #1
dave_cheney.net
On 2014/06/16 23:52:04, khr wrote: > Hello mailto:golang-codereviews@googlegroups.com, > > I'd like you to review ...
10 years, 12 months ago (2014-06-17 00:00:13 UTC) #2
bradfitz
Pull nosplit stuff out into its own CL that this one could then depend on? ...
10 years, 12 months ago (2014-06-17 00:14:52 UTC) #3
minux
just looked at the assembly files. you also need to make changes to asm_amd64p32.s. https://codereview.appspot.com/93380044/diff/260001/src/pkg/runtime/asm_arm.s ...
10 years, 12 months ago (2014-06-17 00:17:31 UTC) #4
bradfitz
LGTM I didn't verify rune.c -> rune.go super closely, but assume it's right (precedence, etc) ...
10 years, 12 months ago (2014-06-17 05:23:07 UTC) #5
khr
*** Submitted as https://code.google.com/p/go/source/detail?r=7f0999348917 *** runtime: implement string ops in Go Also implement go:nosplit annotation. ...
10 years, 12 months ago (2014-06-17 06:03:11 UTC) #6
gobot
This CL appears to have broken the windows-amd64-race builder. See http://build.golang.org/log/6d2cf7d788936c0ff8782ef5cafb5589644e3dab
10 years, 12 months ago (2014-06-17 06:05:10 UTC) #7
rsc
LGTM but follow up with fixes https://codereview.appspot.com/93380044/diff/340001/src/pkg/runtime/asm_386.s File src/pkg/runtime/asm_386.s (right): https://codereview.appspot.com/93380044/diff/340001/src/pkg/runtime/asm_386.s#newcode785 src/pkg/runtime/asm_386.s:785: MOVL x+0(FP),AX // ...
10 years, 12 months ago (2014-06-17 16:18:42 UTC) #8
rsc
I should add that you can run go vet to check assembly for other architectures ...
10 years, 12 months ago (2014-06-17 16:24:10 UTC) #9
rsc
https://codereview.appspot.com/93380044/diff/340001/src/pkg/runtime/string.go File src/pkg/runtime/string.go (right): https://codereview.appspot.com/93380044/diff/340001/src/pkg/runtime/string.go#newcode42 src/pkg/runtime/string.go:42: //go:nosplit Are these go:nosplits necessary? I am running into ...
10 years, 10 months ago (2014-08-14 18:21:48 UTC) #10
khr1
These nosplits are not necessary. They just emulate what we had in C and lower ...
10 years, 10 months ago (2014-08-17 04:07:58 UTC) #11
minux
10 years, 10 months ago (2014-08-17 06:13:15 UTC) #12
On Aug 17, 2014 12:07 AM, "Keith Randall" <khr@google.com> wrote:
> These nosplits are not necessary.  They just emulate what we had in C and
lower the function overhead by a tiny bit.
thanks for confirmation, due to lack of optimization, on the power64
branch, their NOSPLIT flags are removed.
Sign in to reply to this message.

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