- 02 Mar, 2016 13 commits
-
-
Tamir Duberstein authored
This promotes a connection hang during TLS handshake to a proper error. This doesn't fully address #14539 because the error reported in that case is a write-on-socket-not-connected error, which implies that an earlier error during connection setup is not being checked, but it is an improvement over the current behaviour. Updates #14539. Change-Id: I0571a752d32d5303db48149ab448226868b19495 Reviewed-on: https://go-review.googlesource.com/19990Reviewed-by:
Adam Langley <agl@golang.org>
-
David Crawshaw authored
It looks like the compiler still uses the Cfunc flag for functions marked as //go:systemstack, but if I'm reading this right, that doesn't apply here and the linker no longer needs Cfunc. Change-Id: I63b9192c2f52f41401263c29dc8dfd8be8a901a1 Reviewed-on: https://go-review.googlesource.com/20105 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by:
Russ Cox <rsc@golang.org>
-
Joe Tsai authored
Unlike RFC 1951 (DEFLATE), bzip2 does not use zero-length Huffman codes to indicate that the symbol is missing. Instead, bzip2 uses a sparse bitmap to indicate which symbols are present. Thus, it is undefined what happens when a length of zero is used. Thus, fix the parsing logic so that the length cannot ever go below 1-bit similar to how the C logic does things. To confirm that the C bzip2 utility chokes on this data: $ echo "425a6836314159265359b1f7404b000000400040002000217d184682ee48 a70a12163ee80960" | xxd -r -p | bzip2 -d bzip2: Data integrity error when decompressing For reference see: bzip2-1.0.6/decompress.c:320 Change-Id: Ic1568f8e7f80cdea51d887b4d712cc239c2fe85e Reviewed-on: https://go-review.googlesource.com/20119 Run-TryBot: Joe Tsai <joetsai@digital-static.net> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Matthew Dempsky <mdempsky@google.com>
-
Mohit Agarwal authored
Updates #11041 Change-Id: I12c20beab75d7981efe470eb418e4b58dc8eb066 Reviewed-on: https://go-review.googlesource.com/20002Reviewed-by:
Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
David Crawshaw authored
Change-Id: Ic99bd63c96b1eba5cc2b5cd2be3a575890a02996 Reviewed-on: https://go-review.googlesource.com/20103 Run-TryBot: David Crawshaw <crawshaw@golang.org> Reviewed-by:
Dave Cheney <dave@cheney.net> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
David Crawshaw authored
This per-symbol table was written with the strategy: 1. record offset and write fake header 2. write body 3. seek back to fake header 4. write real header This CL collects the per-symbol body into a []byte, then writes the real header followed by the body to the output file. This saves two seeks per-symbol and overwriting the fake header. Small performance improvement (3.5%) in best-of-ten links of godoc: tip: real 0m1.132s user 0m1.256s this: real 0m1.090s user 0m1.210s I'm not sure if the performance measured here alone justifies it, but I think this is an easier to read style of code. Change-Id: I1663901eb7c2ee330591b8b6550cdff0402ed5dc Reviewed-on: https://go-review.googlesource.com/20074Reviewed-by:
Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
David Crawshaw authored
Used by DWARF writer changes in a followup CL. Change-Id: I6ec40dcfeaba909d9b8f6cf2603bc5b85c1fa873 Reviewed-on: https://go-review.googlesource.com/20073Reviewed-by:
Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: David Crawshaw <crawshaw@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Keith Randall authored
Do some easy TODOs. Move a bunch of other TODOs into bugs. Change-Id: Iaba9dad6221a2af11b3cbcc512875f4a85842873 Reviewed-on: https://go-review.googlesource.com/20114 Run-TryBot: Todd Neal <todd@tneal.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Todd Neal <todd@tneal.org>
-
Brad Fitzpatrick authored
Fixes parsing regression from https://golang.org/cl/19931 which added the URL.ForceQuery field. Fixes #14573 Change-Id: I89575cab3f778b1bf78b2389623c866450b26943 Reviewed-on: https://go-review.googlesource.com/20116 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Andrew Gerrand <adg@golang.org>
-
Robert Griesemer authored
Change-Id: Ifa65a35418c2b5a2c517c0d9bbe37f472091e759 Reviewed-on: https://go-review.googlesource.com/20115 Run-TryBot: Robert Griesemer <gri@golang.org> Reviewed-by:
Matthew Dempsky <mdempsky@google.com>
-
Marvin Stenger authored
This commit modifies the style of a error message in case of -shadow. Previously such a message would look like: foo.go:42: declaration of err shadows declaration at shadow.go:13: Changes of the commit include highlighting the variable name and removing the ": "(space intended) at the end of the line: foo.go:42: declaration of "err" shadows declaration at shadow.go:13 Fixes #14585. Change-Id: Ia6a6bf396668dcba9a24f025a08d8826db31f434 Reviewed-on: https://go-review.googlesource.com/20093Reviewed-by:
Rob Pike <r@golang.org>
-
Brad Fitzpatrick authored
The tree's pretty inconsistent about single space vs double space after a period in documentation. Make it consistently a single space, per earlier decisions. This means contributors won't be confused by misleading precedence. This CL doesn't use go/doc to parse. It only addresses // comments. It was generated with: $ perl -i -npe 's,^(\s*// .+[a-z]\.) +([A-Z]),$1 $2,' $(git grep -l -E '^\s*//(.+\.) +([A-Z])') $ go test go/doc -update Change-Id: Iccdb99c37c797ef1f804a94b22ba5ee4b500c4f7 Reviewed-on: https://go-review.googlesource.com/20022Reviewed-by:
Rob Pike <r@golang.org> Reviewed-by:
Dave Day <djd@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Ian Lance Taylor authored
The size calculation has been wrong since this code was first committed in https://golang.org/cl/3120. The effect was that the compiler always allocated a temporary buffer on the stack for a non-escaping string concatenation. This turns out to make no practical difference, as the compiler always allocates a buffer of the same size (32 bytes) and the runtime only uses the temporary buffer if the concatenated strings fit (check is in rawstringtmp in runtime/string.go). The effect of this change is to avoid generating a temporary buffer on the stack that will not be used. Change-Id: Id632bfe3d6c113c9934c018a2dd4bcbf1784a63d Reviewed-on: https://go-review.googlesource.com/20112 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Brad Fitzpatrick <bradfitz@golang.org>
-
- 01 Mar, 2016 23 commits
-
-
Ian Lance Taylor authored
This check seems to apply to all code instrumentation, not just -race. Fixes #14589. Change-Id: I16ae07749ede7c1e6ed06f472711638d195034ac Reviewed-on: https://go-review.googlesource.com/20113 Run-TryBot: Ian Lance Taylor <iant@golang.org> Reviewed-by:
Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Marvin Stenger <marvin.stenger94@gmail.com>
-
Brad Fitzpatrick authored
This is a subset of https://golang.org/cl/20022 with only the copyright header lines, so the next CL will be smaller and more reviewable. Go policy has been single space after periods in comments for some time. The copyright header template at: https://golang.org/doc/contribute.html#copyright also uses a single space. Make them all consistent. Change-Id: Icc26c6b8495c3820da6b171ca96a74701b4a01b0 Reviewed-on: https://go-review.googlesource.com/20111 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by:
Ian Lance Taylor <iant@golang.org> Reviewed-by:
Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Robert Griesemer authored
Also: Use same ordering of tokens in the various tables/maps. Change-Id: Ief84c6ca3da36213ace6b2c10b513e2ca16318ab Reviewed-on: https://go-review.googlesource.com/20110 Run-TryBot: Robert Griesemer <gri@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Matthew Dempsky <mdempsky@google.com>
-
Keith Randall authored
SSA is a real compiler now, don't trigger on function names. Change-Id: Iaf6dd78248c1b6ca2630275bd59f7ea7b7576497 Reviewed-on: https://go-review.googlesource.com/20088Reviewed-by:
David Chase <drchase@google.com> Run-TryBot: David Chase <drchase@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Gerrit Code Review authored
-
Keith Randall authored
Merge dev.ssa branch back into master. Change-Id: Ie6fac3f8d355ab164f934415fe4fc7fcb8c3db16
-
Rob Pike authored
Correctness, Frequency, Precision. Change-Id: I7f202c220aef8512d611dc04a4370b4a237f217c Reviewed-on: https://go-review.googlesource.com/20003Reviewed-by:
Russ Cox <rsc@golang.org>
-
David Chase authored
Static branch predictions (which guide block ordering) are adjusted based on: loop/not-loop (favor looping) abnormal-exit/not (avoid panic) call/not-call (avoid call) ret/default (treat returns as rare) This appears to make no difference in performance of real code, meaning the compiler itself. The earlier version of this has been stripped down to help make the cost of this only-aesthetic-on-Intel phase be as cheap as possible (we probably want information about inner loops for improving register allocation, but because register allocation follows close behind this pass, conceivably the information could be reused -- so we might do this anyway just to normalize output). For a ./make.bash that takes 200 user seconds, about .75 second is reported in likelyadjust (summing nanoseconds reported with -d=ssa/likelyadjust/time ). Upstream predictions are respected. Includes test, limited to build on amd64 only. Did several iterations on the debugging output to allow some rough checks on behavior. Debug=1 logging notes agree/disagree with earlier passes, allowing analysis like the following: Run on make.bash: GO_GCFLAGS=-d=ssa/likelyadjust/debug \ ./make.bash >& lkly5.log grep 'ranch prediction' lkly5.log | wc -l 78242 // 78k predictions grep 'ranch predi' lkly5.log | egrep -v 'agrees with' | wc -l 29633 // 29k NEW predictions grep 'disagrees' lkly5.log | wc -l 444 // contradicted 444 times grep '< exit' lkly5.log | wc -l 10212 // 10k exit predictions grep '< exit' lkly5.log | egrep 'disagrees' | wc -l 5 // 5 contradicted by previous prediction grep '< exit' lkly5.log | egrep -v 'agrees' | wc -l 702 // 702-5 redundant with previous prediction grep '< call' lkly5.log | egrep -v 'agrees' | wc -l 16699 // 16k new call predictions grep 'stay in loop' lkly5.log | egrep -v 'agrees' | wc -l 3951 // 4k new "remain in loop" predictions Fixes #11451. Change-Id: Iafb0504f7030d304ef4b6dc1aba9a5789151a593 Reviewed-on: https://go-review.googlesource.com/19995 Run-TryBot: David Chase <drchase@google.com> Reviewed-by:
Keith Randall <khr@golang.org>
-
Matthew Dempsky authored
Add a blank line before the "package ssa" lines so the "autogenerated don't edit" comments don't end up in godoc output. Change-Id: I82bf90d52d426ce1a8e21483fc8f47b3689259c7 Reviewed-on: https://go-review.googlesource.com/20086Reviewed-by:
Keith Randall <khr@golang.org>
-
David Crawshaw authored
Change-Id: I1ece7463d35efba0e8d2b1e61727dd25283ff720 Reviewed-on: https://go-review.googlesource.com/20059Reviewed-by:
Matthew Dempsky <mdempsky@google.com> Run-TryBot: David Crawshaw <crawshaw@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Alexandru Moșoi authored
* Decreases the generated code slightly. * Similar to phiopt pass from gcc, except it only handles booleans. Handling Eq/Neq had no impact on the generated code. name old time/op new time/op delta Template 453ms ± 4% 451ms ± 4% ~ (p=0.468 n=24+24) GoTypes 1.55s ± 1% 1.55s ± 2% ~ (p=0.287 n=24+25) Compiler 6.53s ± 2% 6.56s ± 1% +0.46% (p=0.050 n=23+23) MakeBash 45.8s ± 2% 45.7s ± 2% ~ (p=0.866 n=24+25) name old text-bytes new text-bytes delta HelloSize 676k ± 0% 676k ± 0% ~ (all samples are equal) CmdGoSize 8.07M ± 0% 8.07M ± 0% -0.03% (p=0.000 n=25+25) Change-Id: Ia62477b7554127958a14cb27f85849b095d63663 Reviewed-on: https://go-review.googlesource.com/20090Reviewed-by:
Keith Randall <khr@golang.org> Run-TryBot: Alexandru Moșoi <alexandru@mosoi.ro> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Alexandru Moșoi authored
* This is a very basic form of straight line strength reduction. * Removes one multiplication from a[b].c++; a[b+1].c++ * It increases pressure on the register allocator because CSE creates more copies of the multiplication sizeof(a[0])*b. Change-Id: I686a18e9c24cc6f8bdfa925713afed034f7d36d0 Reviewed-on: https://go-review.googlesource.com/20091 Run-TryBot: Alexandru Moșoi <alexandru@mosoi.ro> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Keith Randall <khr@golang.org>
-
Ilya Tocar authored
Writing to low 8/16 bits of register creates false dependency Generate 32-bit operations when possible. Change-Id: I8eb6c1c43a66424eec6baa91a660bceb6b80d1d3 Reviewed-on: https://go-review.googlesource.com/19506Reviewed-by:
Keith Randall <khr@golang.org> Run-TryBot: Ilya Tocar <ilya.tocar@intel.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Matthew Dempsky authored
Change-Id: I5546c4e8092ef61648cdae9c04288bb7d6f32476 Reviewed-on: https://go-review.googlesource.com/20084 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by:
Dave Cheney <dave@cheney.net> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Martin Möhrmann authored
Use only reflect.TypeOf to detect if argument is a string. The wasString return is only needed in doPrint with the 'v' verb. This type of string detection is handled correctly by reflect.TypeOf which is used already in doPrint for identifying a string argument. Remove now obsolete wasString computations and return values. Change-Id: Iea2de7ac0f5c536a53eec63f7e679d628f5af8dc Reviewed-on: https://go-review.googlesource.com/19976 Run-TryBot: Rob Pike <r@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Rob Pike <r@golang.org>
-
Matthew Dempsky authored
Updates #13940. Change-Id: I41974c292dd981d82ac03b9b8b406713445362c3 Reviewed-on: https://go-review.googlesource.com/20081 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by:
Brad Fitzpatrick <bradfitz@golang.org>
-
Matthew Dempsky authored
Change-Id: I99c737415a082df883a9c12cdb43bdd5a1b9a8ad Reviewed-on: https://go-review.googlesource.com/20082Reviewed-by:
Brad Fitzpatrick <bradfitz@golang.org>
-
Matthew Dempsky authored
Also, relocate related const and type definitions from go.go. Change-Id: Ieb9b672da8dd510ca67022b4f7ae49a778a56579 Reviewed-on: https://go-review.googlesource.com/20080 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by:
Dave Cheney <dave@cheney.net> Reviewed-by:
Keith Randall <khr@golang.org>
-
Matthew Dempsky authored
Change-Id: I2d8efef333f2441da6742e125e23ff57c9853ebd Reviewed-on: https://go-review.googlesource.com/20078 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Dave Cheney <dave@cheney.net>
-
Matthew Dempsky authored
Change-Id: I42f370b987fcc85201f7aaa055b9e58ee9b9a99e Reviewed-on: https://go-review.googlesource.com/20079 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by:
Dave Cheney <dave@cheney.net> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
nwidger authored
Fixes #14371 Change-Id: I8e9e4b2b89083f5a947e791c011912fdf365a11e Reviewed-on: https://go-review.googlesource.com/19996Reviewed-by:
Andrew Gerrand <adg@golang.org>
-
Keith Randall authored
Add writeback code to each return location which copies the final result back to the correct stack location. Cgo plays tricky games by taking the address of a in f(a int) (b int) and then using that address to modify b. So for cgo-generated Go code, disable the SSAing of output args. Update #14511 Change-Id: I95cba727d53699d31124eef41db0e03935862be9 Reviewed-on: https://go-review.googlesource.com/19988Reviewed-by:
Todd Neal <todd@tneal.org> Run-TryBot: Keith Randall <khr@golang.org> Reviewed-by:
Ian Lance Taylor <iant@golang.org>
-
Ian Lance Taylor authored
Fixes #14570. Change-Id: Ief84a14585bfc209e38cdf15702c2f54ba759714 Reviewed-on: https://go-review.googlesource.com/20057 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:
Michael Hudson-Doyle <michael.hudson@canonical.com>
-
- 29 Feb, 2016 4 commits
-
-
Shahar Kohanim authored
In best of 10, linking cmd/go shows a ~10% improvement. tip: real 0m1.152s user 0m1.005s this: real 0m1.065s user 0m0.924s Change-Id: I303a20b94332feaedc1033c453247a0e4c05c843 Reviewed-on: https://go-review.googlesource.com/19978Reviewed-by:
David Crawshaw <crawshaw@golang.org>
-
Gerrit Code Review authored
-
Josh Bleecher Snyder authored
The cache gets a 62% hit rate while compiling the standard library. name old time/op new time/op delta Template 449ms ± 2% 443ms ± 4% -1.40% (p=0.006 n=23+25) GoTypes 1.54s ± 1% 1.50s ± 2% -2.53% (p=0.000 n=22+22) Compiler 5.51s ± 1% 5.39s ± 1% -2.29% (p=0.000 n=23+25) name old alloc/op new alloc/op delta Template 90.4MB ± 0% 90.0MB ± 0% -0.45% (p=0.000 n=25+25) GoTypes 334MB ± 0% 331MB ± 0% -1.05% (p=0.000 n=25+25) Compiler 1.12GB ± 0% 1.10GB ± 0% -1.57% (p=0.000 n=25+24) name old allocs/op new allocs/op delta Template 681k ± 0% 682k ± 0% +0.26% (p=0.000 n=25+25) GoTypes 2.23M ± 0% 2.23M ± 0% +0.05% (p=0.000 n=23+24) Compiler 6.46M ± 0% 6.46M ± 0% +0.02% (p=0.000 n=24+25) Change-Id: I2629c291892827493d7b55ec4d83f6973a2ab133 Reviewed-on: https://go-review.googlesource.com/20026Reviewed-by:
Keith Randall <khr@golang.org> Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> Reviewed-by:
Alexandru Moșoi <alexandru@mosoi.ro> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Keith Randall authored
(Last?) Semi-regular merge from tip to dev.ssa. Conflicts: src/cmd/compile/internal/gc/closure.go src/cmd/compile/internal/gc/gsubr.go src/cmd/compile/internal/gc/lex.go src/cmd/compile/internal/gc/pgen.go src/cmd/compile/internal/gc/syntax.go src/cmd/compile/internal/gc/walk.go src/cmd/internal/obj/pass.go Change-Id: Ib5ea8bf74d420f4902a9c6208761be9f22371ae7
-