]>
Cypherpunks repositories - gostls13.git/log
Rob Pike [Mon, 9 May 2011 13:38:04 +0000 (06:38 -0700)]
gif: fix build
Had bit test wrong on transparency; no excuses.
R=nigeltao
CC=golang-dev
https://golang.org/cl/
4526044
Rob Pike [Mon, 9 May 2011 00:26:16 +0000 (17:26 -0700)]
image/gif: implement transparency.
At least, as I understand it. The spec is unclear about what happens
with a local color map.
R=nigeltao, r2
CC=golang-dev
https://golang.org/cl/
4515045
Rob Pike [Sun, 8 May 2011 21:05:18 +0000 (14:05 -0700)]
go spec: fix up HTML glitches.
Fixes #1786.
R=gri, adg
CC=golang-dev
https://golang.org/cl/
4517043
Rob Pike [Sun, 8 May 2011 21:04:42 +0000 (14:04 -0700)]
effective go: update to new Open signature.
Fixes #1788.
R=rsc, adg
CC=golang-dev
https://golang.org/cl/
4519042
Alex Brainman [Sun, 8 May 2011 06:33:44 +0000 (16:33 +1000)]
syscall: change Overlapped.HEvent type, it is a handle
R=golang-dev, r, r2
CC=golang-dev
https://golang.org/cl/
4471046
Alex Brainman [Sun, 8 May 2011 06:32:00 +0000 (16:32 +1000)]
syscall: fix bug in mksyscall_windows.pl
This change fixes generation of "shadow" variables for bool parameters.
Before the change, it was naming all bool variables with the same name of _p0.
Now it calls them _p0, _p1, ... So the code could compile.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
4479047
Rob Pike [Sun, 8 May 2011 05:57:42 +0000 (22:57 -0700)]
image/gif: GIF decoder
It's incomplete but sufficient to decode 8-bit GIFs without interlacing
or transparency. More to come.
I'll put in more tests as the feature set grows.
R=nigeltao, r2
CC=golang-dev
https://golang.org/cl/
4522041
Nigel Tao [Sun, 8 May 2011 01:57:32 +0000 (18:57 -0700)]
compress/lzw: silently drop implied codes that are too large,
instead of returning an error.
For example, http://www.w3.org/Graphics/GIF/spec-gif89a.txt
explicitly says that GIF encoders can use a full table as is,
without needing to send a clear code.
R=r, dsymonds, nigeltao_gnome, r2
CC=golang-dev
https://golang.org/cl/
4518041
Anschel Schaffer-Cohen [Sat, 7 May 2011 18:05:08 +0000 (11:05 -0700)]
gob: Doc typo fix
Fixes #1785.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/
4496042
Joe Poirier [Sat, 7 May 2011 05:05:04 +0000 (22:05 -0700)]
windows: reset command var to sh for correct error output messages
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
4492043
Roger Peppe [Fri, 6 May 2011 20:35:51 +0000 (13:35 -0700)]
cgo: put CFLAGS before filename argument
This means that the -x flag can work, which could enable
support for other languages (e.g. objective-C).
R=iant, rsc
CC=golang-dev
https://golang.org/cl/
4476049
Dmitry Chestnykh [Fri, 6 May 2011 20:11:07 +0000 (16:11 -0400)]
doc: remove left and right padding in H2 headings.
R=adg, rsc1, rsc
CC=golang-dev
https://golang.org/cl/
4491041
Albert Strasheim [Fri, 6 May 2011 19:29:49 +0000 (15:29 -0400)]
runtime: handle out-of-threads on Linux gracefully
R=rsc
CC=golang-dev
https://golang.org/cl/
4396050
David Symonds [Fri, 6 May 2011 17:00:50 +0000 (10:00 -0700)]
http: fix typo in URL.String doc comment.
R=adg
CC=golang-dev
https://golang.org/cl/
4485046
Alex Brainman [Fri, 6 May 2011 07:15:46 +0000 (17:15 +1000)]
wingui: fix Makefile after rename
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
4477046
Adam Langley [Thu, 5 May 2011 17:44:36 +0000 (13:44 -0400)]
crypto/tls: export the verified chains.
The verified chains are the chains that were actually verified.
R=bradfitz
CC=golang-dev
https://golang.org/cl/
4462046
Adam Langley [Thu, 5 May 2011 17:37:42 +0000 (13:37 -0400)]
crypto/x509: export raw SubjectPublicKeyInfo.
The SPKI will probably be used for identifying public keys in future
HSTS specs.
R=bradfitz
CC=golang-dev
https://golang.org/cl/
4485044
Roger Peppe [Thu, 5 May 2011 17:16:59 +0000 (10:16 -0700)]
image: make AlphaColor.Set conform to usual signature
R=nigeltao, r
CC=golang-dev
https://golang.org/cl/
4471045
Robert Griesemer [Thu, 5 May 2011 16:03:00 +0000 (09:03 -0700)]
go spec: newlines cannot be used inside a char or "" string literal
R=r
CC=golang-dev
https://golang.org/cl/
4462043
Benny Siegert [Thu, 5 May 2011 03:52:55 +0000 (20:52 -0700)]
image/tiff: implement a decoder.
The current iteration can decode 8-bit images in
grayscale, paletted, RGB, RGBA and NRGBA mode. LZW compression
is implemented but does not work on my test images.
Deflate (i.e. zlib) compression with or without a horizontal
predictor is supported.
R=nigeltao, nigeltao_gnome
CC=golang-dev, mpl
https://golang.org/cl/
4240051
Dmitry Chestnykh [Thu, 5 May 2011 03:46:27 +0000 (20:46 -0700)]
image/png: support encoding of paletted images with alpha channel.
Encoder now writes tRNS chunk for non-opaque paletted images.
CL includes new test images (basn3a08-trns.[ps]ng).
R=nigeltao, rsc, r
CC=golang-dev
https://golang.org/cl/
4432078
Ross Light [Wed, 4 May 2011 19:01:33 +0000 (15:01 -0400)]
http/spdy: add type to FlagClearPreviouslyPersistedSettings constant
R=rsc, bradfitz
CC=golang-dev
https://golang.org/cl/
4436074
Nigel Tao [Wed, 4 May 2011 17:17:53 +0000 (10:17 -0700)]
exp/draw: fast paths for drawing a YCbCr or an NRGBA onto an RGBA.
On my laptop, I had an 800x600 jpeg and an 800x600 png (with
transparency). I timed how long it took to draw each image onto an
equivalently sized, zeroed RGBA image.
Previously, the jpeg took 75ms and the png took 70ms, going through
the medium-fast path, i.e. func drawRGBA in draw.go.
After this CL, the jpeg took 14ms, and the png took 21ms with the
Over operator and 12ms with the Src operator.
It's only a rough estimate basd on one image file, but it should
give an idea of the order of magnitude of improvement.
R=rsc, r
CC=adg, golang-dev
https://golang.org/cl/
4468044
Russ Cox [Wed, 4 May 2011 04:26:20 +0000 (00:26 -0400)]
tag release.r57.1
R=adg
CC=golang-dev
https://golang.org/cl/
4468043
Russ Cox [Wed, 4 May 2011 04:14:07 +0000 (00:14 -0400)]
doc: document r57.1
R=adg
CC=golang-dev
https://golang.org/cl/
4471041
Andrew Gerrand [Wed, 4 May 2011 03:45:10 +0000 (20:45 -0700)]
http: fix FormFile nil pointer dereference on missing multipart form
R=rsc
CC=golang-dev
https://golang.org/cl/
4463042
Alex Brainman [Wed, 4 May 2011 03:08:36 +0000 (13:08 +1000)]
net: disable dnsmsg_test on windows
R=golang-dev, bradfitzwork
CC=golang-dev
https://golang.org/cl/
4466041
Alex Brainman [Wed, 4 May 2011 01:16:55 +0000 (11:16 +1000)]
make.bash: remove old bash version of gotest on Windows
The file is called gotest.exe now.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
4444090
Brad Fitzpatrick [Tue, 3 May 2011 18:25:35 +0000 (11:25 -0700)]
http: improve a test
Should prevent failures on slow machines, such as:
http://godashboard.appspot.com/log/
47b5cae591b7ad8908704e327f3b9b41945d7d5fecfc0c8c945d5545ece1a813
Verified the change (on a fast machine) by removing the
existing sleep, in which case the race happens ~50% of the
time with GOMAXPROCS > 1, but recovers gracefully with
retries.
R=rsc
CC=golang-dev
https://golang.org/cl/
4441089
Russ Cox [Tue, 3 May 2011 18:12:46 +0000 (14:12 -0400)]
tag release.r57 step 2
R=r
CC=golang-dev
https://golang.org/cl/
4431088
Russ Cox [Tue, 3 May 2011 18:12:02 +0000 (14:12 -0400)]
tag release.r57
R=r, r2
CC=golang-dev
https://golang.org/cl/
4435083
Russ Cox [Tue, 3 May 2011 17:55:50 +0000 (13:55 -0400)]
doc: release.r57
R=golang-dev, r, adg, r2
CC=golang-dev
https://golang.org/cl/
4457049
Robert Griesemer [Tue, 3 May 2011 16:56:18 +0000 (09:56 -0700)]
gofmt: update test.sh (exclude a file w/ incorrect syntax)
R=iant, iant2
CC=golang-dev
https://golang.org/cl/
4453058
Russ Cox [Tue, 3 May 2011 14:39:11 +0000 (10:39 -0400)]
codereview: add release branch support
Note that if you are working on the upcoming release
branch you have to point your extension path to a
copy of lib/codereview/codereview.py that won't change
as the repository flips between release-branch and default branch.
This warning should only apply to this one branch and only to rsc,
but you never know.
R=adg
CC=golang-dev
https://golang.org/cl/
4446076
Russ Cox [Tue, 3 May 2011 14:38:37 +0000 (10:38 -0400)]
reflect: allow unexported key in Value.MapIndex
Fixes #1748.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
4444087
Brad Fitzpatrick [Tue, 3 May 2011 14:10:48 +0000 (07:10 -0700)]
net: don't crash on unexpected DNS SRV responses
Fixes #1350
R=rsc, bradfitzwork
CC=golang-dev
https://golang.org/cl/
4432089
Gustavo Niemeyer [Tue, 3 May 2011 12:53:04 +0000 (09:53 -0300)]
Make.cmd: create TARGDIR if necessary
Fixes #1771.
R=adg, rsc1
CC=golang-dev
https://golang.org/cl/
4437089
Russ Cox [Tue, 3 May 2011 05:56:23 +0000 (01:56 -0400)]
ld: make ELF binaries with no shared library dependencies static binaries
$ file $GOROOT/bin/{godoc,goyacc}
/home/rsc/g/go/bin/godoc: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), not strpped
/home/rsc/g/go/bin/goyacc: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), statically linked, not stripped
$
Fixes #1758.
R=iant
CC=golang-dev
https://golang.org/cl/
4428079
Andrew Gerrand [Tue, 3 May 2011 03:40:47 +0000 (20:40 -0700)]
doc/install: specify clone -u instead of -r
R=rsc
CC=golang-dev
https://golang.org/cl/
4435081
Brad Fitzpatrick [Tue, 3 May 2011 03:08:27 +0000 (23:08 -0400)]
os: remove race paranoia from Environ(); it's guarded now
R=rsc
CC=golang-dev
https://golang.org/cl/
4426077
Robert Griesemer [Tue, 3 May 2011 01:07:11 +0000 (18:07 -0700)]
godoc: if there is no search box, don't run the respective JS code
Fixes a JS crash which prevented the automatically generated
table of contents to not appear.
R=adg, bradfitz
CC=golang-dev
https://golang.org/cl/
4460041
Robert Griesemer [Tue, 3 May 2011 00:23:18 +0000 (17:23 -0700)]
go spec: clarify semantics of integer division
Fixes #1764.
R=rsc, r, iant, ken2
CC=golang-dev
https://golang.org/cl/
4431082
Rob Pike [Mon, 2 May 2011 22:42:46 +0000 (15:42 -0700)]
image: fix build
accidentally deleted one method
TBR=rsc
R=rsc
CC=golang-dev
https://golang.org/cl/
4438090
Rob Pike [Mon, 2 May 2011 22:10:37 +0000 (15:10 -0700)]
image: add type-specific Set methods and use them when decoding PNG.
This speeds up PNG decode about 20% by avoiding per-pixel interface conversions.
R=nigeltao, rsc
CC=golang-dev
https://golang.org/cl/
4428080
Russ Cox [Mon, 2 May 2011 21:34:22 +0000 (17:34 -0400)]
http/pprof: fix POST reading bug
R=bradfitz
CC=golang-dev
https://golang.org/cl/
4430075
Brad Fitzpatrick [Mon, 2 May 2011 21:22:40 +0000 (14:22 -0700)]
net: default to 127.0.0.1, not localhost, in TestICMP
If localhost resolves to ::1, the IPv4-only test fails.
R=rsc, r2
CC=golang-dev
https://golang.org/cl/
4444084
Brad Fitzpatrick [Mon, 2 May 2011 20:35:28 +0000 (13:35 -0700)]
runtime: maybe fix Windows build broken by cgo setenv CL
R=rsc
CC=golang-dev
https://golang.org/cl/
4428078
Robert Griesemer [Mon, 2 May 2011 20:28:02 +0000 (13:28 -0700)]
godoc: added -index flag to enable/disable search index
Fixes #1647.
R=adg, rsc1, r2, rsc, r
CC=golang-dev
https://golang.org/cl/
4444083
Brad Fitzpatrick [Mon, 2 May 2011 20:01:36 +0000 (13:01 -0700)]
http: fix racy test with a simpler version
This was seen breaking the slow arm5 builder:
http://godashboard.appspot.com/log/
ec54ee302a70c07093e8f5c47454b3eb48768b77e1d8cc7943d8951f8b6696be
The test was unnecessarily complex and didn't benefit from
using httptest.Server. That just got in the way.
R=rsc
CC=golang-dev
https://golang.org/cl/
4439088
Brad Fitzpatrick [Mon, 2 May 2011 19:38:13 +0000 (12:38 -0700)]
os: make Setenv update C environment variables
Fixes #1569
R=rsc, bradfitzwork
CC=golang-dev
https://golang.org/cl/
4456045
Russ Cox [Mon, 2 May 2011 17:55:51 +0000 (13:55 -0400)]
misc/cgo/test: run tests
The new gotest ignores Test functions outside *_test.go files
(the old shell script allowed them), so replace one clumsy hack
with another.
The root problem is that the package makefiles only know
how to run cgo for source files in the package proper, not
for test files. Making it work for test files is probably more
trouble than it's worth.
R=bradfitz
CC=golang-dev
https://golang.org/cl/
4452060
Robert Griesemer [Mon, 2 May 2011 17:05:43 +0000 (10:05 -0700)]
go/printer: make tests follow syntactic restrictions
R=rsc
CC=golang-dev
https://golang.org/cl/
4439087
Robert Griesemer [Mon, 2 May 2011 16:17:46 +0000 (09:17 -0700)]
go/token: faster FileSet.Position implementation
- added a cache for last file looked up: avoids binary
search if the file matches
- don't look up extra line info if not present
(it is almost never present)
- inline one critical binary search call (inlining
provides almost 30% improvement in this case)
Together, these changes make the go/printer benchmark
more than twice as fast (53% improvement). gofmt also
sped up by about the same amount.
Also: removed an unused internal field from FileSet.
Measurements (always best of 5 runs):
* original:
printer.BenchmarkPrint 5
238354200 ns/op (100%)
* using last file cache:
printer.BenchmarkPrint 10
201796600 ns/op (85%)
* avoiding lookup of extra line info:
printer.BenchmarkPrint 10
157072700 ns/op (66%)
* inlining a critical binary search call:
printer.BenchmarkPrint 10
111523500 ns/op (47%)
gofmt (always best of 3 runs):
* before:
time gofmt -l src misc
real 0m33.316s
user 0m31.298s
sys 0m0.319s
* after:
time gofmt -l src misc
real 0m15.889s
user 0m14.596s
sys 0m0.224s
R=r, dfc, bradfitz, rsc1
CC=golang-dev
https://golang.org/cl/
4433086
Robert Griesemer [Mon, 2 May 2011 16:16:31 +0000 (09:16 -0700)]
go spec: restricted expressions may still be parenthesized
No language change.
- added a few examples with parentheses
- added a corresponding sentence to assignments
(this explicitly permits: (_) = 0, currently allowed by 6g,
gofmt, but marked as an error by gccgo).
R=rsc, r, iant
CC=golang-dev
https://golang.org/cl/
4446071
Russ Cox [Mon, 2 May 2011 15:24:32 +0000 (11:24 -0400)]
5a, 6a, 8a, cc: remove old environment variables
Uses of $INCLUDE and $NPROC are left over from Plan 9.
Remove them to avoid causing confusion.
R=golang-dev, r2
CC=golang-dev
https://golang.org/cl/
4445079
Brad Fitzpatrick [Mon, 2 May 2011 15:14:31 +0000 (08:14 -0700)]
multipart: add FileName accessor on Part
R=rsc, adg
CC=golang-dev
https://golang.org/cl/
4426074
Mikio Hara [Mon, 2 May 2011 14:50:12 +0000 (10:50 -0400)]
net: enable SO_REUSEPORT on BSD variants
Fixes #1694.
R=golang-dev, rsc1, rsc
CC=golang-dev
https://golang.org/cl/
4445067
Mikio Hara [Mon, 2 May 2011 14:49:42 +0000 (10:49 -0400)]
net: fix ipv6 test
Fixes #1767.
R=rsc
CC=golang-dev
https://golang.org/cl/
4436073
Russ Cox [Mon, 2 May 2011 14:49:19 +0000 (10:49 -0400)]
runtime, sync/atomic: fix arm cas
Works around bug in kernel implementation on old ARM5 kernels.
Bug was fixed on 26 Nov 2007 (between 2.6.23 and 2.6.24) but
old kernels persist.
Fixes #1750.
R=dfc, golang-dev
CC=golang-dev
https://golang.org/cl/
4436072
Brad Fitzpatrick [Mon, 2 May 2011 14:26:40 +0000 (07:26 -0700)]
jpeg: speed up RGBA encoding ~%50
Avoids image.At(), color.RGBA(), opposing 8 bit shifts,
and min function calls in a loop. Not as pretty as before,
but the pure version is still there to revert back to
later if/when the compiler gets better.
before (best of 5)
jpeg.BenchmarkEncodeRGBOpaque 50
64781360 ns/op 18.97 MB/s
after (best of 5)
jpeg.BenchmarkEncodeRGBOpaque 50
42044300 ns/op 29.23 MB/s
(benchmarked on an HP z600; 16 core Xeon E5520 @ 2.27Ghz)
R=r, r2, nigeltao
CC=golang-dev
https://golang.org/cl/
4433088
Brad Fitzpatrick [Mon, 2 May 2011 14:25:53 +0000 (07:25 -0700)]
png: speed up opaque RGBA encoding
With Linux/8g on a 2006 Mac Mini (1.66 GHz Intel Core Duo,
2KB L1, 2MB L2, 2G main memory), GOMAXPROCS unset:
start:
png.BenchmarkEncodePaletted 50
44772820 ns/op
png.BenchmarkEncodeRGBOpaque 10
208395900 ns/op
png.BenchmarkEncodeRGBA 5
331088000 ns/op
remove interface method calls:
png.BenchmarkEncodePaletted 50
44722880 ns/op
png.BenchmarkEncodeRGBOpaque 10
139042600 ns/op
png.BenchmarkEncodeRGBA 5
334033600 ns/op
flate inline min/max():
png.BenchmarkEncodePaletted 50
40631180 ns/op
png.BenchmarkEncodeRGBOpaque 10
124894900 ns/op
png.BenchmarkEncodeRGBA 5
312099000 ns/op
after adler change:
png.BenchmarkEncodePaletted 50
40181760 ns/op
png.BenchmarkEncodeRGBOpaque 20
121781950 ns/op
png.BenchmarkEncodeRGBA 5
313890800 ns/op
In comparison to 121 ms on this 2006 machine, on my
Core2 Duo 2.66 GHz laptop, the final BenchmarkEncodeRGBOpaque
runs in 27 ms. (these are all for 640x480 images)
R=nigeltao, rsc, r
CC=golang-dev
https://golang.org/cl/
4432077
Brad Fitzpatrick [Mon, 2 May 2011 01:23:39 +0000 (18:23 -0700)]
multipart: return an error on Reader EOF, not (nil, nil)
R=rsc, adg
CC=golang-dev
https://golang.org/cl/
4430074
Evan Shaw [Sun, 1 May 2011 23:35:55 +0000 (09:35 +1000)]
syscall: add Windows file mapping functions and constants
R=brainman, rsc1, rsc
CC=golang-dev
https://golang.org/cl/
4375046
Andrew Gerrand [Sun, 1 May 2011 19:37:20 +0000 (12:37 -0700)]
http: rename ErrBodyReadAferClose to ErrBodyReadAfterClose
R=bradfitz, dsymonds
CC=golang-dev
https://golang.org/cl/
4432085
Brad Fitzpatrick [Sun, 1 May 2011 02:54:36 +0000 (19:54 -0700)]
mime/multipart: fix regression from previous ReadSlice change
The previous change to make multipart use ReadSlice out of
paranoia broke multipart to not deal with large lines in
the bodies.
We should only be paranoid about long lines in the header
sections.
Fixes http://code.google.com/p/camlistore/issues/detail?id=4
R=adg
CC=golang-dev
https://golang.org/cl/
4432083
Brad Fitzpatrick [Sun, 1 May 2011 02:54:08 +0000 (19:54 -0700)]
http: new error for reading a body after it's been closed
R=adg
CC=golang-dev
https://golang.org/cl/
4433094
Robert Griesemer [Fri, 29 Apr 2011 20:06:03 +0000 (13:06 -0700)]
go/parser: accept parenthesized receive operations in select statements
R=rsc
CC=golang-dev
https://golang.org/cl/
4439082
Robert Griesemer [Fri, 29 Apr 2011 19:20:31 +0000 (12:20 -0700)]
undo CL
4428057 /
19e540fc7d7d
The CL introduces inconsistencies with respect to
the use of parentheses/grouping of receive operations.
««« original CL description
spec: narrow syntax for expression and select statements
This is not a language change, it simply expresses the
accepted cases explicitly in the respective productions.
R=rsc, r, iant
CC=golang-dev
https://golang.org/cl/
4428057
»»»
R=golang-dev, rsc1
CC=golang-dev
https://golang.org/cl/
4444080
Brad Fitzpatrick [Fri, 29 Apr 2011 17:42:44 +0000 (10:42 -0700)]
image: png & jpeg encoding benchmarks
No code changes in this CL.
R=r
CC=golang-dev
https://golang.org/cl/
4445074
Ian Lance Taylor [Fri, 29 Apr 2011 17:38:07 +0000 (10:38 -0700)]
http/cgi: pass down environment variables for irix and solaris
Used by gccgo.
R=bradfitz
CC=golang-dev
https://golang.org/cl/
4435080
Robert Griesemer [Fri, 29 Apr 2011 16:49:10 +0000 (09:49 -0700)]
spec: narrow syntax for expression and select statements
This is not a language change, it simply expresses the
accepted cases explicitly in the respective productions.
R=rsc, r, iant
CC=golang-dev
https://golang.org/cl/
4428057
Evan Shaw [Fri, 29 Apr 2011 14:04:28 +0000 (07:04 -0700)]
http/cgi: correctly set request Content-Type
R=bradfitz
CC=golang-dev
https://golang.org/cl/
4433087
Robert Griesemer [Fri, 29 Apr 2011 00:06:34 +0000 (17:06 -0700)]
go/printer: added simple performance benchmark
R=r, dfc, bradfitzwork, bradfitz
CC=golang-dev
https://golang.org/cl/
4441078
Brad Fitzpatrick [Thu, 28 Apr 2011 22:02:32 +0000 (15:02 -0700)]
cgi: set Request.TLS and Request.RemoteAddr for children
R=agl, eds, rsc1, rsc
CC=golang-dev
https://golang.org/cl/
4432079
Evan Shaw [Thu, 28 Apr 2011 20:30:53 +0000 (13:30 -0700)]
cgi: export RequestFromMap
R=rsc, bradfitz
CC=golang-dev
https://golang.org/cl/
4452056
Ross Light [Thu, 28 Apr 2011 20:11:37 +0000 (13:11 -0700)]
http/spdy: new package
R=bradfitz, agl1, rsc
CC=golang-dev
https://golang.org/cl/
4435055
Russ Cox [Thu, 28 Apr 2011 19:43:42 +0000 (15:43 -0400)]
xml: fix reflect error
Fixes #1749.
R=bradfitz
CC=golang-dev
https://golang.org/cl/
4431075
Brad Fitzpatrick [Thu, 28 Apr 2011 18:36:06 +0000 (11:36 -0700)]
http: update cookie doc to reference new RFC 6265
R=rsc, r2
CC=golang-dev
https://golang.org/cl/
4442100
Gustavo Niemeyer [Thu, 28 Apr 2011 17:16:41 +0000 (14:16 -0300)]
syslog: fix skipping of net tests
Also remove some left over copy & paste
in the test of reflect.Copy for arrays.
R=golang-dev, rsc1
CC=golang-dev
https://golang.org/cl/
4431074
Russ Cox [Thu, 28 Apr 2011 17:14:35 +0000 (13:14 -0400)]
gc: preserve original expression for errors
Fixes #1722.
R=ken2
CC=golang-dev
https://golang.org/cl/
4442099
Evan Shaw [Thu, 28 Apr 2011 07:16:15 +0000 (00:16 -0700)]
http: add Header.Write method
R=golang-dev, bradfitz, dsymonds
CC=golang-dev
https://golang.org/cl/
4426069
Andrew Gerrand [Thu, 28 Apr 2011 06:38:01 +0000 (16:38 +1000)]
tag weekly.2011-04-27
R=golang-dev
CC=golang-dev
https://golang.org/cl/
4439081
Andrew Gerrand [Thu, 28 Apr 2011 06:32:51 +0000 (16:32 +1000)]
weekly.2011-04-27
R=rsc
CC=golang-dev
https://golang.org/cl/
4437077
Andrew Gerrand [Thu, 28 Apr 2011 05:21:54 +0000 (15:21 +1000)]
http: add MultipartForm, FormFile, and ParseMultipartForm to Request
R=rsc, bradfitz
CC=golang-dev
https://golang.org/cl/
4431068
Brad Fitzpatrick [Thu, 28 Apr 2011 04:36:11 +0000 (21:36 -0700)]
adler32: speed up ~40% by avoiding bounds checks
before & after:
adler32.BenchmarkGolden 100000 14747 ns/op
adler32.BenchmarkGolden 200000 8761 ns/op
Found by profiling PNG encoding.
R=rsc, bradfitzwork, eds
CC=golang-dev
https://golang.org/cl/
4441073
Russ Cox [Thu, 28 Apr 2011 04:20:37 +0000 (00:20 -0400)]
runtime: fix typo in gc bug fix
This time for sure.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/
4437078
Lorenzo Stoakes [Thu, 28 Apr 2011 04:13:49 +0000 (00:13 -0400)]
gc: correctly handle fields of pointer type to recursive forward references
Previously, whether declaring a type which copied the structure of a type it was referenced in via a pointer field would work depended on whether you declared it before or after the type it copied, e.g. type T2 T1; type T1 struct { F *T2 } would work, however type T1 struct { F *T2 }; type T2 T1 wouldn't.
Fixes #667.
R=rsc
CC=golang-dev
https://golang.org/cl/
4313064
Russ Cox [Thu, 28 Apr 2011 03:21:12 +0000 (23:21 -0400)]
runtime: stack split + garbage collection bug
The g->sched.sp saved stack pointer and the
g->stackbase and g->stackguard stack bounds
can change even while "the world is stopped",
because a goroutine has to call functions (and
therefore might split its stack) when exiting a
system call to check whether the world is stopped
(and if so, wait until the world continues).
That means the garbage collector cannot access
those values safely (without a race) for goroutines
executing system calls. Instead, save a consistent
triple in g->gcsp, g->gcstack, g->gcguard during
entersyscall and have the garbage collector refer
to those.
The old code was occasionally seeing (because of
the race) an sp and stk that did not correspond to
each other, so that stk - sp was not the number of
stack bytes following sp. In that case, if sp < stk
then the call scanblock(sp, stk - sp) scanned too
many bytes (anything between the two pointers,
which pointed into different allocation blocks).
If sp > stk then stk - sp wrapped around.
On 32-bit, stk - sp is a uintptr (uint32) converted
to int64 in the call to scanblock, so a large (~4G)
but positive number. Scanblock would try to scan
that many bytes and eventually fault accessing
unmapped memory. On 64-bit, stk - sp is a uintptr (uint64)
promoted to int64 in the call to scanblock, so a negative
number. Scanblock would not scan anything, possibly
causing in-use blocks to be freed.
In short, 32-bit platforms would have seen either
ineffective garbage collection or crashes during garbage
collection, while 64-bit platforms would have seen
either ineffective or incorrect garbage collection.
You can see the invalid arguments to scanblock in the
stack traces in issue 1620.
Fixes #1620.
Fixes #1746.
R=iant, r
CC=golang-dev
https://golang.org/cl/
4437075
Russ Cox [Thu, 28 Apr 2011 03:21:03 +0000 (23:21 -0400)]
cgo: handle versioned ELF symbols
Fixes #1397.
R=iant
CC=golang-dev
https://golang.org/cl/
4444064
Russ Cox [Thu, 28 Apr 2011 03:20:53 +0000 (23:20 -0400)]
runtime: allow use of >512 MB on 32-bit platforms
runtime: memory allocated by OS not in usable range
runtime: out of memory: cannot allocate
1114112 -byte block (
2138832896 in use)
throw: out of memory
runtime.throw+0x40 /Users/rsc/g/go/src/pkg/runtime/runtime.c:102
runtime.throw(0x1fffd, 0x101)
runtime.mallocgc+0x2af /Users/rsc/g/go/src/pkg/runtime/malloc.c:60
runtime.mallocgc(0x100004, 0x0, 0x1, 0x1, 0xc093, ...)
runtime.mal+0x40 /Users/rsc/g/go/src/pkg/runtime/malloc.c:289
runtime.mal(0x100004, 0x20bc4)
runtime.new+0x26 /Users/rsc/g/go/src/pkg/runtime/malloc.c:296
runtime.new(0x100004, 0x8fe84000, 0x20bc4)
main.main+0x29 /Users/rsc/x.go:11
main.main()
runtime.mainstart+0xf /Users/rsc/g/go/src/pkg/runtime/386/asm.s:93
runtime.mainstart()
runtime.goexit /Users/rsc/g/go/src/pkg/runtime/proc.c:178
runtime.goexit()
----- goroutine created by -----
_rt0_386+0xbf /Users/rsc/g/go/src/pkg/runtime/386/asm.s:80
R=iant, r
CC=golang-dev
https://golang.org/cl/
4444073
Andrew Gerrand [Thu, 28 Apr 2011 03:14:35 +0000 (13:14 +1000)]
mime/multipart: add ReadForm and associated types
R=brad_danga_com, rsc, dfc, r, dchest, bradfitz
CC=golang-dev
https://golang.org/cl/
4439075
Brad Fitzpatrick [Wed, 27 Apr 2011 22:57:22 +0000 (15:57 -0700)]
tar: use ioutil.Discard
This one didn't come up in previous greps.
R=adg
CC=golang-dev
https://golang.org/cl/
4430071
Brad Fitzpatrick [Wed, 27 Apr 2011 22:47:04 +0000 (15:47 -0700)]
ioutil: add Discard, update tree.
This also removes an unnecessary allocation in
http/transfer.go
R=r, rsc1, r2, adg
CC=golang-dev
https://golang.org/cl/
4426066
Brad Fitzpatrick [Wed, 27 Apr 2011 22:36:39 +0000 (15:36 -0700)]
http: put a limit on POST size
R=rsc
CC=golang-dev
https://golang.org/cl/
4432076
Brad Fitzpatrick [Wed, 27 Apr 2011 21:23:25 +0000 (14:23 -0700)]
http: keep gzip reader inside eofsignaler
Fixes #1725
R=rsc
CC=golang-dev
https://golang.org/cl/
4442086
Gustavo Niemeyer [Wed, 27 Apr 2011 21:22:53 +0000 (18:22 -0300)]
reflect: Fix Copy of arrays
R=golang-dev, rsc1
CC=golang-dev
https://golang.org/cl/
4438077
Brad Fitzpatrick [Wed, 27 Apr 2011 21:07:13 +0000 (14:07 -0700)]
cgi: improve Location response handling
Add local URI path support, which isn't as fringe
as I originally thought. (it's supported by Apache)
Send an implicit 302 status on redirects (not 200).
Fixes #1597
R=rsc, r
CC=golang-dev
https://golang.org/cl/
4442089
Peter Mundy [Wed, 27 Apr 2011 19:47:12 +0000 (15:47 -0400)]
runtime: fix mkversion to output valid path separators
In a GOROOT path a backslash is a path separator
not an escape character. For example, `C:\go`.
Fixes gotest error:
version.go:3: unknown escape sequence: g
R=rsc
CC=golang-dev
https://golang.org/cl/
4437076
Evan Shaw [Wed, 27 Apr 2011 19:34:34 +0000 (12:34 -0700)]
http/fcgi: New package
R=golang-dev, bradfitzgo, bradfitzwork, nigeltao, rog
CC=golang-dev
https://golang.org/cl/
4271078
Rob Pike [Wed, 27 Apr 2011 16:59:27 +0000 (09:59 -0700)]
tutorial: replace the forever loops with finite counts in sieve programs.
Fixes #1742.
I hope.
Also this picks up an update to go_tutorial.html that should already have happened.
R=brainman, rsc, peterGo
CC=golang-dev
https://golang.org/cl/
4452050