- 05 Apr, 2019 5 commits
-
-
Keith Randall authored
fdopendir takes ownership of its file descriptor argument. Getdirentries shouldn't do that, so dup the file descriptor before passing to fdopendir. Fixes #31269 Change-Id: Ie36be8fd6c59eb339dcc9f40228d4191fc1e5850 Reviewed-on: https://go-review.googlesource.com/c/go/+/170698 Run-TryBot: Keith Randall <khr@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Tobias Klauser authored
Don't panic with "index out of range" on empty string argument. Fixes golang/go#31277 Change-Id: I005f9523caec76337cb2ec87272a6be4736bce18 Reviewed-on: https://go-review.googlesource.com/c/go/+/170937 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Austin Clements authored
Change-Id: I8a40461b93eab034ed930e0c5e32391f84cdbc5a Reviewed-on: https://go-review.googlesource.com/c/go/+/170799Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Sebastien Binet <seb.binet@gmail.com>
-
Darren Grant authored
Upon unrecovered panic and program termination, process exit code is hard-coded to 2, not set to the parameter passed to panic(). Change-Id: If64b75493227b4fd69c0bbb529f84e6df2d1b93f Reviewed-on: https://go-review.googlesource.com/c/go/+/167709Reviewed-by: Robert Griesemer <gri@golang.org>
-
Jay Conrod authored
load.PackageAndErrors now preloads data used to build load.Package structures. Multiple packages may be preloaded in parallel, so this parallelizes most of the package loading work. The actual package construction and error-checking process is still sequential, since this process needs to detect and report cycles. Fixes #29758 Change-Id: Icf37e6669836ce8aad076e34fd895f97f4f3f9e2 Reviewed-on: https://go-review.googlesource.com/c/go/+/161397 Run-TryBot: Jay Conrod <jayconrod@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Bryan C. Mills <bcmills@google.com>
-
- 04 Apr, 2019 8 commits
-
-
Filippo Valsorda authored
If x does not have an inverse modulo m, and a negative exponent is used, return nil just like ModInverse does now. Change-Id: I8fa72f7a851e8cf77c5fab529ede88408740626f Reviewed-on: https://go-review.googlesource.com/c/go/+/170757 Run-TryBot: Filippo Valsorda <filippo@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
-
Keith Randall authored
The INODE64 variant only exists on 64-bit. Fixes #31262 Change-Id: I528277c9b3312fdb15463ccbea0d537ff300f4ae Reviewed-on: https://go-review.googlesource.com/c/go/+/170837 Run-TryBot: Keith Randall <khr@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Austin Clements authored
This adds an internal runtime debug log. It uses per-M time-stamped ring buffers of binary log records. On panic, these buffers are collected, interleaved, and printed. The entry-point to the debug log is a new "dlog" function. dlog is designed so it can be used even from very constrained corners of the runtime such as signal handlers or inside the write barrier. The facility is only enabled if the debuglog build tag is set. Otherwise, it compiles away to a no-op implementation. The debug log format is also designed so it would be reasonable to decode from a core dump, though this hasn't been implemented. Change-Id: I6e2737c286358e97a0d8091826498070b95b66a3 Reviewed-on: https://go-review.googlesource.com/c/go/+/157997 Run-TryBot: Austin Clements <austin@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Michael Knyszek <mknyszek@google.com>
-
grant authored
This change adds directives to link the res_search function in libSystem. The corresponding Go function is then used in `lookup_darwin.go` for resolution when cgo is disabled. This makes DNS resolution logic more reliable as macOS has some unique quirks such as the `/etc/resolver/` directory for specifying nameservers. Fixes #12524 Change-Id: I367263c4951383965b3ef6491196152f78e614b1 GitHub-Last-Rev: 3c3ff6bfa7e4811f206f3b119a867c841a016e10 GitHub-Pull-Request: golang/go#30686 Reviewed-on: https://go-review.googlesource.com/c/go/+/166297 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Keith Randall <khr@golang.org>
-
Than McIntosh authored
When building as part of the bootstrap process, avoid use of "go:linkname" applied to variables, since this feature is ill-defined/unsupported for gccgo. Updates #30771. Change-Id: Id44d01b5c98d292702e5075674117518cb59e2d0 Reviewed-on: https://go-review.googlesource.com/c/go/+/170737Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Richard Musiol authored
This change adds the GOWASM option "satconv" to enable the generation of experimental saturating (non-trapping) float-to-int conversions. It improves the performance of the conversion by 42%. Previously the conversions had already been augmented with helper functions to have saturating behavior. Now Wasm.rules is always using the new operation names and wasm/ssa.go is falling back to the helpers if the feature is not enabled. The feature is in phase 4 of the WebAssembly proposal process: https://github.com/WebAssembly/meetings/blob/master/process/phases.md More information on the feature can be found at: https://github.com/WebAssembly/nontrapping-float-to-int-conversions/blob/master/proposals/nontrapping-float-to-int-conversion/Overview.md Change-Id: Ic6c3688017054ede804b02b6b0ffd4a02ef33ad7 Reviewed-on: https://go-review.googlesource.com/c/go/+/170119Reviewed-by: Cherry Zhang <cherryyz@google.com> Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Leo Antunes authored
This commit adds a KeepAlive field to ListenConfig and uses it analogously to Dialer.KeepAlive to set TCP KeepAlives per default on Accept() Fixes #23378 Change-Id: I57eaf9508c979e7f0e2b8c5dd8e8901f6eb27fd6 GitHub-Last-Rev: e9e035d53ee8aa3d899d12db08b293f599daecb6 GitHub-Pull-Request: golang/go#31242 Reviewed-on: https://go-review.googlesource.com/c/go/+/170678 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Neven Sajko authored
Rewrote a few lines to be more idiomatic/less assembly-ish. Benchmarked with `go test -bench Float -tags math_big_pure_go`: name old time/op new time/op delta FloatString/100-8 751ns ± 0% 746ns ± 1% -0.71% (p=0.000 n=10+10) FloatString/1000-8 22.9µs ± 0% 22.9µs ± 0% ~ (p=0.271 n=10+10) FloatString/10000-8 1.89ms ± 0% 1.89ms ± 0% ~ (p=0.481 n=10+10) FloatString/100000-8 184ms ± 0% 184ms ± 0% ~ (p=0.094 n=9+9) FloatAdd/10-8 56.4ns ± 1% 56.5ns ± 0% ~ (p=0.170 n=9+9) FloatAdd/100-8 59.7ns ± 0% 59.3ns ± 0% -0.70% (p=0.000 n=8+9) FloatAdd/1000-8 101ns ± 0% 99ns ± 0% -1.89% (p=0.000 n=8+8) FloatAdd/10000-8 553ns ± 0% 536ns ± 0% -3.00% (p=0.000 n=9+10) FloatAdd/100000-8 4.94µs ± 0% 4.74µs ± 0% -3.94% (p=0.000 n=9+10) FloatSub/10-8 50.3ns ± 0% 50.5ns ± 0% +0.52% (p=0.000 n=8+8) FloatSub/100-8 52.0ns ± 0% 52.2ns ± 1% +0.46% (p=0.012 n=8+10) FloatSub/1000-8 77.9ns ± 0% 77.3ns ± 0% -0.80% (p=0.000 n=7+8) FloatSub/10000-8 371ns ± 0% 362ns ± 0% -2.67% (p=0.000 n=10+10) FloatSub/100000-8 3.20µs ± 0% 3.10µs ± 0% -3.16% (p=0.000 n=10+10) ParseFloatSmallExp-8 7.84µs ± 0% 7.82µs ± 0% -0.17% (p=0.037 n=9+9) ParseFloatLargeExp-8 29.3µs ± 1% 29.5µs ± 0% ~ (p=0.059 n=9+8) FloatSqrt/64-8 516ns ± 0% 519ns ± 0% +0.54% (p=0.000 n=9+9) FloatSqrt/128-8 1.07µs ± 0% 1.07µs ± 0% ~ (p=0.109 n=8+9) FloatSqrt/256-8 1.23µs ± 0% 1.23µs ± 0% +0.50% (p=0.000 n=9+9) FloatSqrt/1000-8 3.43µs ± 0% 3.44µs ± 0% +0.53% (p=0.000 n=9+8) FloatSqrt/10000-8 40.9µs ± 0% 40.7µs ± 0% -0.39% (p=0.000 n=9+8) FloatSqrt/100000-8 1.07ms ± 0% 1.07ms ± 0% -0.10% (p=0.017 n=10+9) FloatSqrt/1000000-8 89.3ms ± 0% 89.2ms ± 0% -0.07% (p=0.015 n=9+8) Change-Id: Ibf07c6142719d11bc7f329246957d87a9f3ba3d2 GitHub-Last-Rev: 870a041ab7bb9c24be083114f53653a5f4eed611 GitHub-Pull-Request: golang/go#31220 Reviewed-on: https://go-review.googlesource.com/c/go/+/170449 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
-
- 03 Apr, 2019 17 commits
-
-
Robert Griesemer authored
Before this fix, a mistaken := in a (const/type/var) declaration ended that declaration with an error from which the parser didn't recover well. This low-cost change will provide a better error message and lets the parser recover perfectly. Fixes #31092. Change-Id: Ic4f94dc5e29dd00b7ef6d53a80dded638e3cea80 Reviewed-on: https://go-review.googlesource.com/c/go/+/169958Reviewed-by: Matthew Dempsky <mdempsky@google.com>
-
Keith Randall authored
Getdirentries is implemented with the __getdirentries64 function in libSystem.dylib. That function works, but it's on Apple's can't-be-used-in-an-app-store-application list. Implement Getdirentries using the underlying fdopendir/readdir_r/closedir. The simulation isn't faithful, and could be slow, but it should handle common cases. Don't use Getdirentries in the stdlib, use fdopendir/readdir_r/closedir instead (via (*os.File).readdirnames). Fixes #30933 Update #28984 RELNOTE=yes Change-Id: Ia6b5d003e5bfe43ba54b1e1d9cfa792cc6511717 Reviewed-on: https://go-review.googlesource.com/c/go/+/168479Reviewed-by: Emmanuel Odeke <emm.odeke@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Emmanuel Odeke <emm.odeke@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Keith Randall authored
These new calls should not prevent NOSPLIT promotion, like the old ones. These new calls should not prevent racefuncenter/exit removal. (The latter was already true, as the new calls are not yet lowered to StaticCalls at the point where racefuncenter/exit removal is done.) Add tests to make sure we don't regress (again). Fixes #31219 Change-Id: I3fb6b17cdd32c425829f1e2498defa813a5a9ace Reviewed-on: https://go-review.googlesource.com/c/go/+/170639 Run-TryBot: Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ilya Tocar <ilya.tocar@intel.com>
-
smasher164 authored
Some var declarations return "extra expression" or "missing expression" errors when they should return “assignment mismatch” instead. Change the returned error messages to exhibit the desired behavior. Fixes #30085. Change-Id: I7189355fbb0f976d70100779db4f81a9ae64fb11 Reviewed-on: https://go-review.googlesource.com/c/go/+/161558Reviewed-by: Robert Griesemer <gri@golang.org> Run-TryBot: Robert Griesemer <gri@golang.org>
-
Bryan C. Mills authored
We rely on SSL certificates to verify the identity of origin servers. If an HTTPS server redirects through a plain-HTTP URL, that hop can be compromised. We should allow it only if the user set the -insecure flag explicitly. Fixes #29591 Change-Id: I00639541cca2ca034c01c464385a43b3aa8ee84f Reviewed-on: https://go-review.googlesource.com/c/go/+/156838 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Bryan C. Mills authored
nanomsg.org currently performs an HTTPS-to-HTTP redirect, so this case fails after the fix for #29591. Updates #29591 Change-Id: I6306d378ef213e98c0271258bbc6669bb33f9021 Reviewed-on: https://go-review.googlesource.com/c/go/+/170637 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
-
Brad Fitzpatrick authored
Fixes #31233 Change-Id: I2831d5e6532d3f4ed7eb99af5d6e0e1a41ebac9a Reviewed-on: https://go-review.googlesource.com/c/go/+/170624Reviewed-by: Andrew Bonventre <andybons@golang.org>
-
Romain Baugue authored
Fixes #30688 Change-Id: I8b63feba4b18bc07a09f6fbfaa33c1b3326b40e6 Reviewed-on: https://go-review.googlesource.com/c/go/+/169597Reviewed-by: Rob Pike <r@golang.org>
-
Kenichi Tsunokawa authored
Change-Id: I32b0c02039d8baca1358dac2cc0afd14fa6cd173 GitHub-Last-Rev: d3be7aa039fbe94450c54f2c1dc5a510cf183378 GitHub-Pull-Request: golang/go#31232 Reviewed-on: https://go-review.googlesource.com/c/go/+/170657Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Jay Conrod authored
mvs.BuildList and functions that invoke it directly (UpgradeAll) now return an *mvs.BuildListError when there is an error retrieving the requirements for a module. This new error prints the chain of requirements from the main module to the module where the error occurred. These errors come up most commonly when a go.mod file has an unexpected module path or can't be parsed for some other reason. It's currently difficult to debug these errors because it's not clear where the "bad" module is required from. Tools like "go list -m" and "go mod why" don't work without the build graph. Fixes #30661 Change-Id: I3c9d4683dcd9a5d7c259e5e4cc7e1ee209700b10 Reviewed-on: https://go-review.googlesource.com/c/go/+/166984 Run-TryBot: Jay Conrod <jayconrod@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Bryan C. Mills <bcmills@google.com>
-
Bryan C. Mills authored
The compiler (and race detector) don't interpret locking a file as a synchronization operation, so we add an explicit (and redundant) sync.Mutex to make that property clear. The additional synchronization makes it safe to parallelize the tests in cmd/go/internal/modfetch/coderepo_test.go, which cuts the wall time of that test by around 50%. Updates #30550 Change-Id: Ief3479020ebf9e0fee524a4aae5568697727c683 Reviewed-on: https://go-review.googlesource.com/c/go/+/170597 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Daniel Martí <mvdan@mvdan.cc> Reviewed-by: Jay Conrod <jayconrod@google.com>
-
Clément Chigot authored
As ld on AIX doesn't keep the same layout in .text section, -Wl,-bnoobjreoder must be passed to gcc when building a C program with a Go archive. Change-Id: I89b584cce43ab5792f315192b073923c10d5690e Reviewed-on: https://go-review.googlesource.com/c/go/+/170538 Run-TryBot: Ian Lance Taylor <iant@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
Daniel Martí authored
Decoder.Decode and Unmarshal actually scan the input bytes twice - the first time to check for syntax errors and the length of the value, and the second to perform the decoding. It's in the second scan that we actually tokenize the bytes. Since syntax errors aren't a possibility, we can take shortcuts. In particular, literals such as quoted strings are very common in JSON, so we can avoid a lot of work by special casing them. name old time/op new time/op delta CodeDecoder-8 10.3ms ± 1% 9.1ms ± 0% -11.89% (p=0.002 n=6+6) UnicodeDecoder-8 342ns ± 0% 283ns ± 0% -17.25% (p=0.000 n=6+5) DecoderStream-8 239ns ± 0% 230ns ± 0% -3.90% (p=0.000 n=6+5) CodeUnmarshal-8 11.0ms ± 0% 9.8ms ± 0% -11.45% (p=0.002 n=6+6) CodeUnmarshalReuse-8 10.3ms ± 0% 9.0ms ± 0% -12.72% (p=0.004 n=5+6) UnmarshalString-8 104ns ± 0% 92ns ± 0% -11.35% (p=0.002 n=6+6) UnmarshalFloat64-8 93.2ns ± 0% 87.6ns ± 0% -6.01% (p=0.010 n=6+4) UnmarshalInt64-8 74.5ns ± 0% 71.5ns ± 0% -3.91% (p=0.000 n=5+6) name old speed new speed delta CodeDecoder-8 189MB/s ± 1% 214MB/s ± 0% +13.50% (p=0.002 n=6+6) UnicodeDecoder-8 40.9MB/s ± 0% 49.5MB/s ± 0% +20.96% (p=0.002 n=6+6) CodeUnmarshal-8 176MB/s ± 0% 199MB/s ± 0% +12.93% (p=0.002 n=6+6) Updates #28923. Change-Id: I7a5e2aef51bd4ddf2004aad24210f6f50e01eaeb Reviewed-on: https://go-review.googlesource.com/c/go/+/151042 Run-TryBot: Daniel Martí <mvdan@mvdan.cc> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Matthew Dempsky authored
Updates #23109. Change-Id: I55f7860c868acc948a6397ab6a9295e177724a56 Reviewed-on: https://go-review.googlesource.com/c/go/+/170450 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com>
-
Bryan C. Mills authored
(*mvsReqs).Required assumes that it is safe to mutate the slice returned by (*mvsReqs).required. In most cases, that was true, but in the case of -mod=vendor it resulted in unsynchronized (and potentially interfering) writes to the global vendorList. Fixes #30550 Change-Id: I99bcc2037e0182418b7dfda1002f8b540dbf3a1d Reviewed-on: https://go-review.googlesource.com/c/go/+/170598 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Tobias Klauser authored
splittests already contains most of the tests that cover explode. Add the missing ones and skip the append test for empty results which would otherwise lead to an "index out of range" panic. Change-Id: I2cb922282d2676be9ef85f186513075ae17c0243 Reviewed-on: https://go-review.googlesource.com/c/go/+/170126 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Clément Chigot authored
This commit changes sendmsg, recvmsg to use nsendmsg, nrecvmsg on AIX. These syscalls support the new msghdr structure (with Control and Controllen) which is needed for golang.org/x/net. Also define SockaddrDataLink. Change-Id: I233fbd24f9eb86648e0d4d50c2b56da3626292d0 Reviewed-on: https://go-review.googlesource.com/c/go/+/170537 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
-
- 02 Apr, 2019 10 commits
-
-
Agniva De Sarker authored
Before - $gotip build -gcflags="-d=ssa/check_bce/debug=1" fdct.go idct.go ./fdct.go:89:10: Found IsInBounds ./fdct.go:90:10: Found IsInBounds ./fdct.go:91:10: Found IsInBounds ./fdct.go:92:10: Found IsInBounds ./fdct.go:93:10: Found IsInBounds ./fdct.go:94:10: Found IsInBounds ./fdct.go:95:10: Found IsInBounds ./fdct.go:96:10: Found IsInBounds ./idct.go:77:9: Found IsInBounds ./idct.go:77:27: Found IsInBounds ./idct.go:77:45: Found IsInBounds ./idct.go:78:7: Found IsInBounds ./idct.go:78:25: Found IsInBounds ./idct.go:78:43: Found IsInBounds ./idct.go:78:61: Found IsInBounds ./idct.go:79:13: Found IsInBounds ./idct.go:92:13: Found IsInBounds ./idct.go:93:12: Found IsInBounds ./idct.go:94:12: Found IsInBounds ./idct.go:95:12: Found IsInBounds ./idct.go:97:12: Found IsInBounds ./idct.go:98:12: Found IsInBounds ./idct.go:99:12: Found IsInBounds After - $gotip build -gcflags="-d=ssa/check_bce/debug=1" fdct.go idct.go ./fdct.go:90:9: Found IsSliceInBounds ./idct.go:76:11: Found IsSliceInBounds ./idct.go:145:11: Found IsSliceInBounds name old time/op new time/op delta FDCT-4 1.85µs ± 2% 1.74µs ± 1% -5.95% (p=0.000 n=10+10) IDCT-4 1.94µs ± 2% 1.89µs ± 1% -2.67% (p=0.000 n=10+9) DecodeBaseline-4 1.45ms ± 2% 1.46ms ± 1% ~ (p=0.156 n=9+10) DecodeProgressive-4 2.21ms ± 1% 2.21ms ± 1% ~ (p=0.796 n=10+10) EncodeRGBA-4 24.9ms ± 1% 25.0ms ± 1% ~ (p=0.075 n=10+10) EncodeYCbCr-4 26.1ms ± 1% 26.2ms ± 1% ~ (p=0.573 n=8+10) name old speed new speed delta DecodeBaseline-4 42.5MB/s ± 2% 42.4MB/s ± 1% ~ (p=0.162 n=9+10) DecodeProgressive-4 27.9MB/s ± 1% 27.9MB/s ± 1% ~ (p=0.796 n=10+10) EncodeRGBA-4 49.4MB/s ± 1% 49.1MB/s ± 1% ~ (p=0.066 n=10+10) EncodeYCbCr-4 35.3MB/s ± 1% 35.2MB/s ± 1% ~ (p=0.586 n=8+10) name old alloc/op new alloc/op delta DecodeBaseline-4 63.0kB ± 0% 63.0kB ± 0% ~ (all equal) DecodeProgressive-4 260kB ± 0% 260kB ± 0% ~ (all equal) EncodeRGBA-4 4.40kB ± 0% 4.40kB ± 0% ~ (all equal) EncodeYCbCr-4 4.40kB ± 0% 4.40kB ± 0% ~ (all equal) name old allocs/op new allocs/op delta DecodeBaseline-4 5.00 ± 0% 5.00 ± 0% ~ (all equal) DecodeProgressive-4 13.0 ± 0% 13.0 ± 0% ~ (all equal) EncodeRGBA-4 4.00 ± 0% 4.00 ± 0% ~ (all equal) EncodeYCbCr-4 4.00 ± 0% 4.00 ± 0% ~ (all equal) Updates #24499 Change-Id: I6828d077b851817503a7c1a08235763f81bdadf9 Reviewed-on: https://go-review.googlesource.com/c/go/+/167417 Run-TryBot: Agniva De Sarker <agniva.quicksilver@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Nigel Tao <nigeltao@golang.org>
-
Ian Lance Taylor authored
On darwin/amd64 the runtime method sigctxt.fixsigcode changes SIGSEGV signals so that they are never marked SI_USER. CL 169120 changed the signal handler to call fixsigcode even when the signal is delivered to a non-Go thread. This breaks TestSignalForwardingExternal, so skip it. Change-Id: I6740fb5a8f4f854ca69793537a983a696da3b495 Reviewed-on: https://go-review.googlesource.com/c/go/+/170446 Run-TryBot: Ian Lance Taylor <iant@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Elias Naur authored
The presence of the android_get_device_api_level symbol is used to detect Android Q or later. Use the suggestion by Ryan Prichard and look for it in libc.so and not in the entire program where someone else might have defined it. Manually tested on an Android Q amd64 emulator and arm64 Pixel. Updates #29674 Change-Id: Iaef35d8f8910037b3690aa21f319e216a05a9a73 Reviewed-on: https://go-review.googlesource.com/c/go/+/170127 Run-TryBot: Elias Naur <mail@eliasnaur.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Matthew Dempsky authored
Package unsafe's safety rules require that pointers converted to uintptr must be converted back to pointer-type before being stored into memory. In particular, storing a pointer into a non-pointer-typed expression does not guarantee the pointer stays valid, even if the expression refers to a pointer-typed variable. wasm's StorepNoWB implementation violates these rules by storing a pointer through a uintptr-typed expression. This happens to work today because esc.go is lenient in its implementation of package unsafe's rules, but my escape analysis rewrite follows them more rigorously, which causes val to be treated as a non-leaking parameter. This CL fixes the issue by using a *T-typed expression, where T is marked //go:notinheap so that the compiler still omits the write barrier as appropriate. Updates #23109. Change-Id: I49bc5474dbaa95729e5c93201493afe692591bc8 Reviewed-on: https://go-review.googlesource.com/c/go/+/170323 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com>
-
Joel Sing authored
The certificates argument to verifyServerCertificate must contain at least one certificate. Simplify the intermediate certificate handling code accordingly. Change-Id: I8292cdfb51f418e011d6d97f47d10b4e631aa932 Reviewed-on: https://go-review.googlesource.com/c/go/+/169657Reviewed-by: Filippo Valsorda <filippo@golang.org>
-
Bryan C. Mills authored
- Respect the NETRC environment variable if set. - Ignore lines that contain macro definitions. - Associate the 'machine' token with only the tokens that follow (not precede) it. Updates #29888 Updates #26232 Change-Id: I3128b7d6da2d6492df7c864e165eea1a27384f0f Reviewed-on: https://go-review.googlesource.com/c/go/+/161698 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
-
Matthew Dempsky authored
"leaking closure reference" is redundant for similar reasons as "&x escapes to heap" for OADDR nodes: the reference itself does not allocate, and we already report when the referenced variable is moved to heap. "mark escaped content" is redundant with "leaking param content". Updates #23109. Change-Id: I1ab599cb1e8434f1918dd80596a70cba7dc8a0cf Reviewed-on: https://go-review.googlesource.com/c/go/+/170321 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Alessandro Arzilli authored
Add a new custom attribute to compile units containing the package name of the package (i.e. the name after the 'package' keyword), so that debuggers can know it when it's different from the last segment of the package path. Change-Id: Ieadaab6f47091aabf2f4dc42c8524452eaa6715b Reviewed-on: https://go-review.googlesource.com/c/go/+/163677 Run-TryBot: Alessandro Arzilli <alessandro.arzilli@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Heschi Kreinick <heschi@google.com>
-
Matthew Dempsky authored
For most nodes (e.g., OPTRLIT, OMAKESLICE, OCONVIFACE), escape analysis prints "escapes to heap" or "does not escape" to indicate whether that node's allocation can be heap or stack allocated. These messages are also emitted for OADDR, even though OADDR does not actually allocate anything itself. Moreover, it's redundant because escape analysis already prints "moved to heap" diagnostics when an OADDR node like "&x" causes x to require heap allocation. Because OADDR nodes don't allocate memory, my escape analysis rewrite doesn't naturally emit the "escapes to heap" / "does not escape" diagnostics for them. It's also non-trivial to replicate the exact semantics esc.go uses for OADDR. Since there are so many of these messages, I'm disabling them in this CL by themselves. I modified esc.go to suppress the Warnl calls without any other behavior changes, and then used a shell script to automatically remove any ERROR messages mentioned by run.go in "missing error" or "no match for" lines. Fixes #16300. Updates #23109. Change-Id: I3993e2743c3ff83ccd0893f4e73b366ff8871a57 Reviewed-on: https://go-review.googlesource.com/c/go/+/170319 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com> Reviewed-by: David Chase <drchase@google.com>
-
Mark Ryan authored
AVX-512 instructions that use RIP-relative addressing and require the R bit of the EVEX prefix to be zero, i.e., instructions that use Z8-Z15 or Z24-Z31, are incorrectly encoded by the assembler. The reason is that the location of the offset at which the relative address is to be written is incorrectly computed when the R bit is clear. For example, VMOVUPS bInitX<>+0(SB), Z0 encodes correctly to 62 f1 7c 48 10 05 66 e9 02 00 whereas VMOVUPS bInitX<>+0(SB), Z8 encodes incorrectly to 62 71 7c 48 10 05 00 56 e9 02 00 Note the extra zero byte between the ModR/M byte (05) and the relative address starting with 56. This error results in the first byte of the following instruction being overwritten and typically, a program crash. This commit fixes the issue in the same way that is fixed for VEX encoded instructions, by simply not incrementing the offset for EVEX instructions. Existing test code created for a similar VEX encoding issue (19518) has been modified to also test for the issue addressed by this commit. Fixes #31001 Change-Id: If84719ac22ebb5fb3c42ff96cd32b611ad497414 Reviewed-on: https://go-review.googlesource.com/c/go/+/168562 Run-TryBot: Ilya Tocar <ilya.tocar@intel.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ilya Tocar <ilya.tocar@intel.com>
-