1
0
mirror of https://github.com/golang/go synced 2024-10-04 01:21:21 -06:00
go/src
Hiroshi Ioka 8737dac1f2 strings: make IndexRune faster
re-implement IndexRune by Index which is well optimized to get
performance gain.

name                   old time/op  new time/op  delta
IndexRune-4            30.2ns ± 1%  28.3ns ± 1%   -6.22%  (p=0.000 n=20+19)
IndexRuneLongString-4   156ns ± 1%    49ns ± 1%  -68.72%  (p=0.000 n=19+19)
IndexRuneFastPath-4    10.6ns ± 2%  10.0ns ± 1%   -6.30%  (p=0.000 n=18+18)

Change-Id: Ie663b8f7860ca51892dd4be182fca3caa5f8ae61
Reviewed-on: https://go-review.googlesource.com/28546
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-09-07 01:03:10 +00:00
..
archive archive/tar: reapply Header.Size to regFileReader after merging 2016-09-02 21:58:53 +00:00
bufio
builtin
bytes bytes: make IndexRune faster 2016-09-06 23:32:57 +00:00
cmd cmd/compile: omit some temp panicdivide calls 2016-09-07 00:30:10 +00:00
compress compress/flate: clarify the behavior of Writer.Flush 2016-09-04 03:09:08 +00:00
container container/list: silence vet warnings 2016-08-16 14:35:37 +00:00
context all: use time.Until where applicable 2016-08-30 01:23:46 +00:00
crypto crypto/cipher: enforce message size limits for GCM. 2016-09-02 16:23:15 +00:00
database/sql database/sql: don't hang if the driver Exec method panics 2016-08-29 16:51:56 +00:00
debug all: use testing.GoToolPath instead of "go" 2016-08-30 22:49:11 +00:00
encoding encoding/xml: do not ignore error return from copyValue 2016-08-22 18:01:47 +00:00
errors
expvar
flag flag: improve comment for calling String with zero value 2016-08-23 22:07:43 +00:00
fmt fmt: properly handle early io.EOF Reads in readRune.readByte 2016-07-16 19:14:58 +00:00
go net/http/httputil: make ReverseProxy send nil Body requests when possible 2016-09-02 23:57:58 +00:00
hash hash/crc32: cleanup code and improve tests 2016-08-31 15:17:57 +00:00
html html/template: update security model link 2016-06-23 04:30:07 +00:00
image
index/suffixarray index/suffixarray: add Lookup example 2016-08-21 01:10:22 +00:00
internal internal/testenv: make MustHaveSymlink message friendly 2016-08-24 05:08:52 +00:00
io io: make MultiReader nil exhausted Readers for earlier GC 2016-09-05 21:13:11 +00:00
log log/syslog: document that Dial uses net.Dial parameters, add example 2016-08-19 01:01:47 +00:00
math math: fix sqrt regression on AMD64 2016-09-06 15:45:02 +00:00
mime mime/quotedprintable: add examples 2016-08-29 17:39:21 +00:00
net net/http/httputil: t.Error -> t.Errorf 2016-09-04 22:17:14 +00:00
os os: deduplicate File definition 2016-09-05 21:21:05 +00:00
path path/filepath: handle "C:." correctly in EvalSymlinks on Windows 2016-09-05 00:53:32 +00:00
reflect reflect: cleanup wording for type identity/equality 2016-08-30 22:40:52 +00:00
regexp regexp: reduce mallocs in Regexp.Find* and Regexp.ReplaceAll*. 2016-09-06 17:04:31 +00:00
runtime runtime/debug: enable TestFreeOSMemory on all arches 2016-09-06 21:05:58 +00:00
sort
strconv strconv: fix function name in errors for Atoi 2016-09-04 00:17:58 +00:00
strings strings: make IndexRune faster 2016-09-07 01:03:10 +00:00
sync cmd/compile: intrinsify sync/atomic for amd64 2016-08-30 15:23:23 +00:00
syscall syscall: use MNT_NOWAIT in TestGetfsstat 2016-09-07 00:58:19 +00:00
testing testing: respect benchtime on very fast benchmarks 2016-08-10 19:44:08 +00:00
text text/template: remove unused Tree.parse return value 2016-08-17 22:36:27 +00:00
time time: Add Until helper function 2016-08-30 00:10:47 +00:00
unicode unicode/utf8: reduce bounds checks in EncodeRune 2016-09-03 20:05:36 +00:00
unsafe unsafe: document use of &^ to round/align pointers 2016-08-18 16:45:17 +00:00
vendor/golang_org/x/net vendor: update vendored route 2016-08-24 00:14:58 +00:00
all.bash
all.bat
all.rc
androidtest.bash androidtest.bash: use go list to get pkg dir 2016-08-29 15:24:39 +00:00
bootstrap.bash
buildall.bash
clean.bash
clean.bat
clean.rc
cmp.bash
iostest.bash
make.bash
make.bat
Make.dist
make.rc
naclmake.bash
nacltest.bash
race.bash
race.bat
run.bash
run.bat
run.rc