The old code made it impossible to implement a reverse proxy
with anything less than 4k write granularity to the backends.
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/7060059
The spec talks explicitly about rune literals but the
respective production is still called char_lit for
historic reasons. Updated the two occurences.
Fixes#4602.
R=rsc, iant, r, ken
CC=golang-dev
https://golang.org/cl/7070048
A constant node of type uintptr with a nil literal could
happen in two cases: []int(nil)[1:] and
uintptr(unsafe.Pointer(nil)).
Fixes#4614.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/7059043
There exists a test case for this condition, but it only runs on unix systems, which neatly dovetails into the code always using ':' as the list separator.
R=adg, iant
CC=golang-dev
https://golang.org/cl/7057052
ratio isn't 1x1.
Fixes#4259.
The test data was generated by
cjpeg -quality 50 -sample 2x2 video-005.gray.pgm > video-005.gray.q50.2x2.jpeg
cjpeg -quality 50 -sample 2x2 -progressive video-005.gray.pgm > video-005.gray.q50.2x2.progressive.jpeg
similarly to video-005.gray.q50.* from
http://code.google.com/p/go/source/detail?r=51f26e36ba98
the key difference being the "-sample 2x2".
R=rsc
CC=golang-dev
https://golang.org/cl/7069045
There's no b in race detector.
The new flag matches the one in the go command
(go test -race math).
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/7072043
This proposal updates the dashboard builder to avoid relying on the (soon to be removed) support for using go get to download to $GOROOT. The result is
WORKSPACE=$(the value of the -buildRoot flag / $BUILDER_NAME + hg revision)
GOROOT=$WORKSPACE/go
GOPATH=$WORKSPACE
Required for CL 6941058.
R=minux.ma, adg
CC=golang-dev
https://golang.org/cl/7034049
bytes.Equal is simpler to read and should also be faster because
of short-circuiting and assembly implementations.
Change generated automatically using:
gofmt -r 'bytes.Compare(a, b) == 0 -> bytes.Equal(a, b)'
gofmt -r 'bytes.Compare(a, b) != 0 -> !bytes.Equal(a, b)'
R=golang-dev, dave, adg, rsc
CC=golang-dev
https://golang.org/cl/7038051
Closures are incredibly expensive on linux/arm due to
repetitive flush of instruction cache.
go test -short on ODROID-X:
Before:
ok exp/gotype 17.091s
ok go/types 2.225s
After:
ok exp/gotype 7.193s
ok go/types 1.143s
R=dave, minux.ma, rsc
CC=golang-dev, remy
https://golang.org/cl/7062045
This CL adds a flag parser that matches the semantics of Go's
package flag. It also changes the linkers and compilers to use
the new flag parser.
Command lines that used to work, like
8c -FVw
6c -Dfoo
5g -I/foo/bar
now need to be split into separate arguments:
8c -F -V -w
6c -D foo
5g -I /foo/bar
The new spacing will work with both old and new tools.
The new parser also allows = for arguments, as in
6c -D=foo
5g -I=/foo/bar
but that syntax will not work with the old tools.
In addition to matching standard Go binary flag parsing,
the new flag parser generates more detailed usage messages
and opens the door to long flag names.
The recently added gc flag -= has been renamed -complete.
R=remyoudompheng, daniel.morsing, minux.ma, iant
CC=golang-dev
https://golang.org/cl/7035043
More cleanup in preparation for fixing issue 4069.
This CL replaces the three nearly identical copies of the
asmb ELF code with a single asmbelf function in elf.c.
In addition to the ELF code movement, remove the elfstr
array in favor of a simpler lookup, and identify sections by
name throughout instead of computing fragile indices.
The CL also replaces the three nearly identical copies of the
genasmsym code with a single genasmsym function in lib.c.
The ARM linker still compiles and generates binaries,
but I haven't tested the binaries. They may not work.
R=ken2
CC=golang-dev
https://golang.org/cl/7062047
The Plan 9 symbol table format defines big-endian symbol values
for portability, but we want to be able to generate an ELF object file
and let the host linker link it, as part of the solution to issue 4069.
The symbol table itself, since it is loaded into memory at run time,
must be filled in by the final host linker, using relocation directives
to set the symbol values. On a little-endian machine, the linker will
only fill in little-endian values during relocation, so we are forced
to use little-endian symbol values.
To preserve most of the original portability of the symbol table
format, we make the table itself say whether it uses big- or
little-endian values. If the table begins with the magic sequence
fe ff ff ff 00 00
then the actual table begins after those six bytes and contains
little-endian symbol values. Otherwise, the table is in the original
format and contains big-endian symbol values. The magic sequence
looks like an "end of table" entry (the fifth byte is zero), so legacy
readers will see a little-endian table as an empty table.
All the gc architectures are little-endian today, so the practical
effect of this CL is to make all the generated tables little-endian,
but if a big-endian system comes along, ld will not generate
the magic sequence, and the various readers will fall back to the
original big-endian interpretation.
R=ken2
CC=golang-dev
https://golang.org/cl/7066043
A few USED(xxx) additions and a couple of deletions of variable
initialisations that go unused. One questionable correction,
mirrored in 8l/asm.c, where the result of invocation of a function
shouldn't be used.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/6736054
RFC5424 specifies a version number (currently 1) after the facility and
severity in a syslog message (e.g. <7>1 TIMESTAMP ...). This causes
rsyslog to fail to parse syslog message because the rest of the message
is not fully compliant with RFC5424.
For the widest compatibility, drop the version (messages are in the
RFC3164 BSD syslog format (e.g. <7>TIMESTAMP ...). Have tested this with
syslog-ng, rsyslog and syslogd.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/7036050
TimeoutHandler was changed from "ns int64" to "dt time.Duration" on
Nov 30, 2011, but the godoc still refers to "ns".
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/7031050
* Extended deadline to 30 seconds
* Added logging of the duration of each package import
* Fail the test immediately if directories cannot be read
R=gri, minux.ma
CC=golang-dev
https://golang.org/cl/7030055
A composite literal may be parenthesized when
used as operand for the unary operator &.
R=rsc, iant, r, ken
CC=golang-dev
https://golang.org/cl/6996053