- 26 Aug, 2015 2 commits
-
-
Michael Hudson-Doyle authored
Previously t.zero always pointed to runtime.zerovalue. Change the hashmap code to always return a runtime pointer directly, and change that pointer to point to a larger buffer if one is needed. (It might be better to only copy from the pointer returned by the mapaccess functions when the value type is small enough and have the compiler insert explicit zeroing for larger value types, but I tried and failed to do this). This removes all uses of the zero field of the type data; the field itself can be removed in a separate change. Fixes #11491 Change-Id: I5b81752ff4067d74a5a281c41e88f151bae0171e Reviewed-on: https://go-review.googlesource.com/13784Reviewed-by: Keith Randall <khr@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Andy Maloney authored
Change-Id: I3889eda72ae0f57117f1d4299e3574f8bf68be67 Reviewed-on: https://go-review.googlesource.com/13310Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
- 25 Aug, 2015 10 commits
-
-
Michael Hudson-Doyle authored
This was always a bit confusing, but it also fixes a problem: runtime.firstmoduledata was always overridden in the linker to be a local symbol but cmd/internal/obj had already rewritten code accessing it to access it via the GOT. This works on amd64, but causes link failures on other platforms (e.g. arm64). Change-Id: I9b8153af74b4d0f092211d63a000d15818f39773 Reviewed-on: https://go-review.googlesource.com/13786Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Ulrich Kunitz authored
The issue 12226 has been caused by the allocation of the same register for the equality check of two byte values. The code in cgen.go freed the register for the second operand before the allocation of the register for the first operand. Fixes #12226 Change-Id: Ie4dc33a488bd48a17f8ae9b497fd63c1ae390555 Reviewed-on: https://go-review.googlesource.com/13771Reviewed-by: Russ Cox <rsc@golang.org>
-
Austin Clements authored
A comparison of the form l == r where l is an interface and r is concrete performs a type assertion on l to convert it to r's type. However, the compiler fails to zero the temporary where the result of the type assertion is written, so if the type is a pointer type and a stack scan occurs while in the type assertion, it may see an invalid pointer on the stack. Fix this by zeroing the temporary. This is equivalent to the fix for type switches from c4092ac3. Fixes #12253. Change-Id: Iaf205d456b856c056b317b4e888ce892f0c555b9 Reviewed-on: https://go-review.googlesource.com/13872Reviewed-by: Russ Cox <rsc@golang.org>
-
Dave Cheney authored
Updates #11336 Follow the lead of amd64 by doing a pointer equality check before comparing string/byte contents on arm64. BenchmarkCompareBytesEqual-8 25.8 26.3 +1.94% BenchmarkCompareBytesToNil-8 9.59 9.59 +0.00% BenchmarkCompareBytesEmpty-8 9.59 9.17 -4.38% BenchmarkCompareBytesIdentical-8 26.3 9.17 -65.13% BenchmarkCompareBytesSameLength-8 16.3 16.3 +0.00% BenchmarkCompareBytesDifferentLength-8 16.3 16.3 +0.00% BenchmarkCompareBytesBigUnaligned-8 1132038 1131409 -0.06% BenchmarkCompareBytesBig-8 1126758 1128470 +0.15% BenchmarkCompareBytesBigIdentical-8 1084366 9.17 -100.00% Change-Id: Id7125c31957eff1ddb78897d4511bd50e79af3f7 Reviewed-on: https://go-review.googlesource.com/13885Reviewed-by: Keith Randall <khr@golang.org>
-
Todd Neal authored
nmspinning has a value range of [0, 2^31-1]. Update the comment to indicate this and fix the comparison so it's not always false. Fixes #11280 Change-Id: Iedaf0654dcba5e2c800645f26b26a1a781ea1991 Reviewed-on: https://go-review.googlesource.com/13877Reviewed-by: Minux Ma <minux@golang.org>
-
Shenghou Ma authored
gobuf.g is a guintptr, so without hex(), it will be printed as a decimal, which is not very helpful and inconsistent with how other pointers are printed. Change-Id: I7c0432e9709e90a5c3b3e22ce799551a6242d017 Reviewed-on: https://go-review.googlesource.com/13879Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
Didier Spezia authored
Simplify slice/map literal expressions. Caught with gofmt -d -s, fixed with gofmt -w -s Reformatted some expressions to improve readability. Change-Id: Iaf123e6bd49162ec45c59297ad3b002ca59443bc Reviewed-on: https://go-review.googlesource.com/13850Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Shenghou Ma authored
While we're at it, also fix a typo. Change-Id: Id436f33cffa5683e2a8450cce5b545960cf2877e Reviewed-on: https://go-review.googlesource.com/13878Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
Todd Neal authored
This is not a functional change. nr is a uint64 and can never be less than zero, remove the no-op comparison. Fixes #11279 Change-Id: Iebb36cc8fe97428b503e65d01b5e67d2b2bc7369 Reviewed-on: https://go-review.googlesource.com/13876 Run-TryBot: Todd Neal <todd@tneal.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Aaron Jacobs authored
The nohup command doesn't work in tmux on darwin. Fixes #5135. Change-Id: I1c21073d8bd54b49dd6b0bad86ef088d6d8e7a5f Reviewed-on: https://go-review.googlesource.com/13883Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
- 24 Aug, 2015 12 commits
-
-
Joe Tsai authored
The URL is shown on go docs and is an eye-sore. For go1.6. Change-Id: I8b8ea3751200d06ed36acfe22f47ebb38107f8db Reviewed-on: https://go-review.googlesource.com/13282Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Dave Cheney authored
Updates #11336 Follow the lead of amd64 do a pointer equality check before comparing string/byte contents on arm. BenchmarkCompareBytesEqual-4 208 211 +1.44% BenchmarkCompareBytesToNil-4 83.6 81.8 -2.15% BenchmarkCompareBytesEmpty-4 80.2 75.2 -6.23% BenchmarkCompareBytesIdentical-4 208 75.2 -63.85% BenchmarkCompareBytesSameLength-4 126 128 +1.59% BenchmarkCompareBytesDifferentLength-4 128 130 +1.56% BenchmarkCompareBytesBigUnaligned-4 14192804 14060971 -0.93% BenchmarkCompareBytesBig-4 12277313 12128193 -1.21% BenchmarkCompareBytesBigIdentical-4 9385046 78.5 -100.00% Change-Id: I5b24620018688c5fe04b6ff6743a24c4ce225788 Reviewed-on: https://go-review.googlesource.com/13881Reviewed-by: Keith Randall <khr@golang.org>
-
Rob Pike authored
In short, %c should just give you the next rune, period. Apparently this is the design. I use the term loosely. Fixes #12275 Change-Id: I6f30bed442c0e88eac2244d465c7d151b29cf393 Reviewed-on: https://go-review.googlesource.com/13821Reviewed-by: Andrew Gerrand <adg@golang.org>
-
Andrew Gerrand authored
Fixes #12299 Change-Id: Id7b73d2935c9f7c0952f833613973ef455d02b0d Reviewed-on: https://go-review.googlesource.com/13858Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Tarmigan Casebolt authored
Unused assignment for `err` encoding/asn1/marshal.go:622:3 Unused assignment for `err` encoding/asn1/marshal.go:650:5 Change-Id: I4226238645ce3640f25124cb405444e61439fd3f Reviewed-on: https://go-review.googlesource.com/13847Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Matt Layher authored
Fixes #11763 Change-Id: Ie291b36a8c29694e80940836d7e6fd96d2d76494 Reviewed-on: https://go-review.googlesource.com/12382Reviewed-by: Mikio Hara <mikioh.mikioh@gmail.com> Run-TryBot: Mikio Hara <mikioh.mikioh@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
-
Tarmigan Casebolt authored
Change-Id: Iaaecd8be9268c923f40cf0e5153cbf79f7015b8d Reviewed-on: https://go-review.googlesource.com/13892Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Marcel van Lohuizen authored
All of Go passes. No changes for the text repo. Fixes #10153 Change-Id: I313369bf471c8974390a6d42075e5c54f6a81750 Reviewed-on: https://go-review.googlesource.com/13667Reviewed-by: Russ Cox <rsc@golang.org> Reviewed-by: Rob Pike <r@golang.org>
-
Tarmigan Casebolt authored
Change-Id: I0b19731a46e4e67a7dd503dd133cafc7678760a7 Reviewed-on: https://go-review.googlesource.com/13890Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Tarmigan Casebolt authored
Change-Id: Ie4f21bcd5849e994c63ec5bbda2dee6f3ec4da12 Reviewed-on: https://go-review.googlesource.com/13891Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Alex Brainman authored
Change-Id: I1b9f6ad322a7f68fa160c4f09d7fb56815e505a7 Reviewed-on: https://go-review.googlesource.com/13828Reviewed-by: Rob Pike <r@golang.org>
-
Dave Cheney authored
Fixes #12214 Change-Id: I82586b54ac7b9c0c71055bb66b921e3efbf4977c Reviewed-on: https://go-review.googlesource.com/13719Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Andrew Gerrand <adg@golang.org>
-
- 23 Aug, 2015 2 commits
-
-
Josh Bleecher Snyder authored
Fixes #11060 Change-Id: I4c6647fc2f103015b67e30dc2cdb6f771526c139 Reviewed-on: https://go-review.googlesource.com/13840Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Mikio Hara authored
It is already validated by isDoaminName. Change-Id: I7a955b632a5143e16b012641cf12bad452900753 Reviewed-on: https://go-review.googlesource.com/13789Reviewed-by: Andrew Gerrand <adg@golang.org>
-
- 22 Aug, 2015 4 commits
-
-
Andrew Gerrand authored
Fixes #11257 Change-Id: I3f75db47b0f8e877d81e3c2dcea01ff747b47685 Reviewed-on: https://go-review.googlesource.com/13779Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Brad Fitzpatrick authored
Fixes #12227 Change-Id: I7c1b93e50736185a641fb637000aae2f15bc04ed Reviewed-on: https://go-review.googlesource.com/13820 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
-
Ingo Oeser authored
Add benchmarks for for sparsely escaped and densely escaped strings. Then speed up the sparse unescaping part heavily by using IndexByte and copy to skip the parts containing no escaping very fast. Unescaping densely escaped strings slower because of the new function call overhead. But sparsely encoded strings are seen more often in the utf8 enabled web. We win part of the speed back by looking up entityName differently. benchmark old ns/op new ns/op delta BenchmarkEscape 31680 31396 -0.90% BenchmarkEscapeNone 6507 6872 +5.61% BenchmarkUnescape 36481 48298 +32.39% BenchmarkUnescapeNone 332 325 -2.11% BenchmarkUnescapeSparse 8836 3221 -63.55% BenchmarkUnescapeDense 30639 32224 +5.17% Change-Id: If606cb01897a40eefe35ba98f2ff23bb25251606 Reviewed-on: https://go-review.googlesource.com/10172Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Justin Nuß authored
The current implementations of MarshalJSON and MarshalText use time.Format which returns a string (converted from a byte slice), only to convert it back to a byte slice. Avoid the conversion (and thus an allocation) by directly appending the formatted time to a preallocated byte slice, using the new AppendFormat function, introduced in golang.org/cl/1760. This reduces the allocations done in Marshal[Text|JSON] by 50%. benchmark old ns/op new ns/op delta BenchmarkMarshalJSON 626 507 -19.01% BenchmarkMarshalText 598 511 -14.55% benchmark old allocs new allocs delta BenchmarkMarshalJSON 2 1 -50.00% BenchmarkMarshalText 2 1 -50.00% benchmark old bytes new bytes delta BenchmarkMarshalJSON 96 48 -50.00% BenchmarkMarshalText 96 48 -50.00% Fixes #11025 Change-Id: I468f78d075a6ecc1cdc839df7fb407fbc6ff2e70 Reviewed-on: https://go-review.googlesource.com/10555Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
- 21 Aug, 2015 10 commits
-
-
Brad Fitzpatrick authored
Safer, more readable, shorter. Change-Id: I5cf1f438e20a3df45fc43cc5c870a533f7c524bf Reviewed-on: https://go-review.googlesource.com/10517Reviewed-by: Minux Ma <minux@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Alberto Donizetti authored
Currently an expression like var v = 0 >> 1000 is rejected by gc with a "stupid shift" error, while gotype compiles it successfully. As suggested by gri on the issue tracker, allow an rsh right operand to be any valid uint value. Fixes #11328 Change-Id: I6ccb3b7f842338d91fd26ae37dd4fa279d7fc440 Reviewed-on: https://go-review.googlesource.com/13777Reviewed-by: Robert Griesemer <gri@golang.org>
-
Robert Griesemer authored
This updates the big package used by the compiler to match the public big package which contains some updates and bug fixes. Obtained by running vendor.bash in the internal/big directory. No manual changes. Change-Id: I299aecc6599d4a745a721ce48def32449640dbb2 Reviewed-on: https://go-review.googlesource.com/13815Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
Robert Griesemer authored
Fixes #12231. Change-Id: I1f07c444623cd864667e21b2fee534eacdc193bb Reviewed-on: https://go-review.googlesource.com/13814Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
David du Colombier authored
When there is no browser available on the system, we should print the URL instead of failing. Change-Id: I4a2b099e17609394273eff150062c285d76bbac1 Reviewed-on: https://go-review.googlesource.com/13774Reviewed-by: Dmitry Vyukov <dvyukov@google.com>
-
Alberto Donizetti authored
Even though the umul/uquo functions expect two valid, finite big.Floats arguments, SetString was calling them with possibly Inf values, which resulted in bogus return values. Replace umul and udiv calls with Mul and Quo calls to fix this. Also, fix two wrong tests. See relevant issue on issue tracker for a detailed explanation. Fixes #11341 Change-Id: Ie35222763a57a2d712a5f5f7baec75cab8189a53 Reviewed-on: https://go-review.googlesource.com/13778Reviewed-by: Robert Griesemer <gri@golang.org>
-
Robert Griesemer authored
This is not a functional change. Also: - minor cleanups, better comments - uniform spelling of noun "zeros" (per OED) Fixes #11277. Change-Id: I1726f358ce15907bd2410f646b02cf8b11b919cd Reviewed-on: https://go-review.googlesource.com/11267Reviewed-by: Alan Donovan <adonovan@google.com> Reviewed-by: Robert Griesemer <gri@golang.org>
-
Hyang-Ah (Hana) Kim authored
I cannot find where it's being used. This addresses a duplicate symbol issue encountered in golang/go#9327. Change-Id: I8efda45a006ad3e19423748210c78bd5831215e0 Reviewed-on: https://go-review.googlesource.com/13615Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
Shawn Walker-Salas authored
CL 9184 changed the runtime and syscall packages to link Solaris binaries directly instead of using dlopen/dlsym but did not remove the unused (and now broken) references to dlopen, dlclose, and dlsym. Fixes #11923 Change-Id: I36345ce5e7b371bd601b7d48af000f4ccacd62c0 Reviewed-on: https://go-review.googlesource.com/13410Reviewed-by: Aram Hăvărneanu <aram@mgk.ro>
-
Rob Pike authored
Change-Id: I5310cef72e714b22bcf2ae9e6fd85dbb7e8a15a2 Reviewed-on: https://go-review.googlesource.com/13787Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-