aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2013-05-06go1.1rc2go1.1rc2Andrew Gerrand
2013-05-06api: add go1.1.txt; update cmd/api to use itBrad Fitzpatrick
R=golang-dev, adg, r CC=golang-dev https://golang.org/cl/9250043
2013-05-06runtime: fix crash in badsignal()Dmitriy Vyukov
The linker can generate split stack prolog when a textflag 7 function makes an indirect function call. If it happens, badsignal() crashes trying to dereference g. Fixes #5337. R=bradfitz, dave, adg, iant, r, minux.ma CC=adonovan, golang-dev https://golang.org/cl/9226043
2013-05-07runtime: reduce max arena size on windows/amd64 to 32 GiBShenghou Ma
Update #5236 Update #5402 This CL reduces gofmt's committed memory from 545864 KiB to 139568 KiB. Note: Go 1.0.3 uses about 70MiB. R=golang-dev, r, iant, nightlyone CC=golang-dev https://golang.org/cl/9245043
2013-05-06database/sql: remove an unused field from RowsBrad Fitzpatrick
Found while debugging memory usage. Nobody accesses this field anymore. R=golang-dev, i.caught.air, adg, r CC=golang-dev https://golang.org/cl/9108043
2013-05-06doc: add FAQ entry about language changesAndrew Gerrand
R=golang-dev, dsymonds, r CC=golang-dev https://golang.org/cl/9244043
2013-05-07syscall: fix prototype of Fchflags (API change)Shenghou Ma
API change, but the old API is obviously wrong. R=golang-dev, iant, r, rsc CC=golang-dev https://golang.org/cl/9157044
2013-05-06go/doc/example: Fix bug causing false negatives for Example playability.Jeremiah Harmsen
Allows Examples with KeyValue expressions to be playable in godoc. During the traversal of the abstract syntax tree any KeyValueExpr Key.Name was incorrectly being added as an unresolved identifier. Since this identifier could not be provided the Example was marked as unplayable. This updates the AST traversal to skip Keys (but continue traversing the Values). Example of problematic AST now fixed (see L99 where "UpperBound" was being added as a missing identifier): 81 . . . . . . . . . Values: []ast.Expr (len = 1) { 82 . . . . . . . . . . 0: *ast.UnaryExpr { 83 . . . . . . . . . . . OpPos: 12:19 84 . . . . . . . . . . . Op: & 85 . . . . . . . . . . . X: *ast.CompositeLit { 86 . . . . . . . . . . . . Type: *ast.SelectorExpr { 87 . . . . . . . . . . . . . X: *ast.Ident { 88 . . . . . . . . . . . . . . NamePos: 12:20 89 . . . . . . . . . . . . . . Name: "t_proto" 90 . . . . . . . . . . . . . } 91 . . . . . . . . . . . . . Sel: *ast.Ident { 92 . . . . . . . . . . . . . . NamePos: 12:41 93 . . . . . . . . . . . . . . Name: "BConfig" 94 . . . . . . . . . . . . . } 95 . . . . . . . . . . . . } 96 . . . . . . . . . . . . Lbrace: 12:79 97 . . . . . . . . . . . . Elts: []ast.Expr (len = 2) { 98 . . . . . . . . . . . . . 0: *ast.KeyValueExpr { 99 . . . . . . . . . . . . . . Key: *ast.Ident { 100 . . . . . . . . . . . . . . . NamePos: 13:3 101 . . . . . . . . . . . . . . . Name: "UpperBound" 102 . . . . . . . . . . . . . . } 103 . . . . . . . . . . . . . . Colon: 13:13 104 . . . . . . . . . . . . . . Value: *ast.CallExpr { 105 . . . . . . . . . . . . . . . Fun: *ast.SelectorExpr { 106 . . . . . . . . . . . . . . . . X: *ast.Ident { 107 . . . . . . . . . . . . . . . . . NamePos: 13:15 108 . . . . . . . . . . . . . . . . . Name: "proto" 109 . . . . . . . . . . . . . . . . } 110 . . . . . . . . . . . . . . . . Sel: *ast.Ident { 111 . . . . . . . . . . . . . . . . . NamePos: 13:21 112 . . . . . . . . . . . . . . . . . Name: "Float32" 113 . . . . . . . . . . . . . . . . } R=adg CC=gobot, golang-dev, gri https://golang.org/cl/8569045
2013-05-06C: add Jeremiah Harmsen (Google CLA)Andrew Gerrand
R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/9229043
2013-05-06image/png: fix error message to not return width twiceBrad Fitzpatrick
Fixes #5413 R=golang-dev, dave, adg CC=golang-dev https://golang.org/cl/9153045
2013-05-05go/build: document GOOS.go also has implicit GOOS build constraintShenghou Ma
R=golang-dev, i.caught.air, alexb, r CC=golang-dev https://golang.org/cl/9064044
2013-05-03text/template: comment fixKeith Randall
R=golang-dev, minux.ma, r CC=golang-dev https://golang.org/cl/9086043
2013-05-03doc: fix formatting in effective go code snippetAndrew Gerrand
Fixes #5403. R=golang-dev, minux.ma CC=golang-dev https://golang.org/cl/9100046
2013-05-03runtime/cgo: fix build for ARMShenghou Ma
TBR=iant CC=golang-dev https://golang.org/cl/9048048
2013-05-03cmd/ld: add .note.GNU-stack section for external linkingShenghou Ma
Fixes #5392. R=iant, r CC=golang-dev https://golang.org/cl/9119043
2013-05-02regexp: doc fixBrad Fitzpatrick
This must have been from when "error" was a good variable name for an "os.Error". But we use "err" these days. R=golang-dev, dsymonds, r CC=golang-dev https://golang.org/cl/9132045
2013-05-02doc: only U+FEFF is a byte-order mark; U+FFFE is notRuss Cox
R=golang-dev, r CC=golang-dev https://golang.org/cl/9103046
2013-05-02cmd/ld: fix SDYNIMPORT symbol testAlex Brainman
As advised by iant. Fixes windows build. R=golang-dev, r CC=golang-dev, iant https://golang.org/cl/9110044
2013-05-01cmd/ld: fix another unsigned value causing bugs on Plan 9Rob Pike
"The usual conversions" bite again. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/9103044
2013-05-01libmach: fix build on Plan 9David du Colombier
Include libc.h before bio.h in 8.c, because bio.h uses the UTFmax enum, which is declared in libc.h, since the recent switch to 21-bit runes in Plan 9. The 5.c and 6.c files already includes libc.h. R=golang-dev, r CC=golang-dev https://golang.org/cl/9040047
2013-05-01cmd/cgo: correct pragma name in commentIan Lance Taylor
R=rsc, alexb, minux.ma, bradfitz, i.caught.air CC=golang-dev https://golang.org/cl/9082043
2013-05-01runtime/cgo: export symbols in both internal and external link modeIan Lance Taylor
R=rsc, r CC=golang-dev https://golang.org/cl/9060045
2013-05-01cmd/ld: fix syms that are both cgo_import_static & cgo_import_dynamicIan Lance Taylor
This is needed for SWIG when linking in internal mode. In internal mode if a symbol was cgo_import_static we used to forget that it was also cgo_import_dynamic. R=rsc, r CC=golang-dev https://golang.org/cl/9080043
2013-05-01doc: link to Go 1.1 release notesAndrew Gerrand
R=golang-dev, r CC=golang-dev https://golang.org/cl/9047045
2013-04-30net: do not call syscall.Bind twice on windowsAlex Brainman
Fixes #5355. R=golang-dev, mikioh.mikioh, bradfitz, r CC=golang-dev https://golang.org/cl/8966046
2013-04-30cmd/ld: when linking externally, only generate dwarf info for ELFRob Pike
R=golang-dev, iant CC=golang-dev https://golang.org/cl/9025047
2013-04-30cmd/go: undo CL 8119049Russ Cox
Manual undo due to later changes in doc/go1.1.html; cmd/go/test.bash still passes. Rationale, from CL 8119049 review log: This makes the 'go run' command different from every other command. For example, 'go test' does not mean 'go test *.go'. If we were going to handle the no arguments case in 'go run', I would hope that it would scan the current directory to find a package just like 'go build' or 'go test' would, and then it would require that package to be 'package main', and then it would run that package. This would make it match 'go test' and 'go build' and 'go install' and so on. It would mean that if you are working on a command in a directory that is 'go install'able, then 'go run' will run the binary for you. The current CL does not accomplish that when build constraints or file name constraints are involved. For example, if I am working on a program like: $ ls main.go main_386.s main_arm.s main_amd64.s $ Then 'go run' will fail here because the .s files are ignored. If instead I am working on a program like: $ ls main.go main_386.go main_arm.go main_amd64.go $ then 'go run' will fail because too many files are included. I would like to see this command implemented so that it is compatible with the other go subcommands. Since it is too late to do that for Go 1.1, I would like to see this CL reverted, to preserve the option to do it better later. R=golang-dev, iant, r CC=golang-dev https://golang.org/cl/8797049
2013-04-30cmd/ld: emit relocs for DWARF info when doing an external linkIan Lance Taylor
I would like opinions on whether this is a good idea for 1.1. On the one hand it's a moderately important issue. On the other hand this introduces at least the possibility of external linker errors due to the additional relocations and it may be better to wait. I'm fairly confident that the behaviour is unchanged when not using an external linker. Update #5221 This CL is tested lightly on 386 and amd64 and fixes the cases I tested. I have not tested it on Darwin or Windows. R=golang-dev, dave, daniel.morsing, rsc CC=golang-dev https://golang.org/cl/8858047
2013-04-30os/exec: disable TestExtraFilesFDShuffleRob Pike
It's too hard to make portable just now. R=golang-dev, iant CC=golang-dev https://golang.org/cl/9057043
2013-04-30syscall: fix a bug in the shuffling of file descriptors in StartProcess on ↵Cosmos Nicolaou
Linux. R=iant, iant, r, bradfitz CC=golang-dev https://golang.org/cl/8334044
2013-04-30syscall: fix exec_bsd.go to accompany exec_linux.go changesRob Pike
exec_plan9.go too. Those are in CL 8334044 R=golang-dev, iant CC=golang-dev https://golang.org/cl/9055043
2013-04-30cmd/ld: another attempt at the relocation overflow fixRob Pike
R=golang-dev, iant CC=golang-dev https://golang.org/cl/9036046
2013-04-30cmd/ld: fix check for address wrap in relocationRob Pike
PC-relative needs a signed offset; others need unsigned. Also fix signedness of 32-bit relocation on Windows. R=golang-dev, iant CC=golang-dev https://golang.org/cl/9039045
2013-04-30doc/go1.1: remove discussion of "go run" changeAndrew Gerrand
Update #5164 R=golang-dev, dave CC=golang-dev https://golang.org/cl/9049043
2013-04-30cmd/ld: disable relocation range check so build can go green while we debug ↵Rob Pike
the issue. R=golang-dev, dsymonds, dave CC=golang-dev https://golang.org/cl/9038043
2013-04-29cmd/gc: fix some overflows in the compilerRob Pike
Some 64-bit fields were run through 32-bit words, some counts were not checked for overflow, and relocations must fit in 32 bits. Tests to follow. R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/9033043
2013-04-29cmd/ld: fix some 64-bit issuesRob Pike
A few places in the linker pushed 64-bit values through 32-bit holes, including in relocation. Clean them up, and check for a few other overflows as well. Tests to follow. R=dsymonds CC=gobot, golang-dev https://golang.org/cl/9032043
2013-04-30encoding/json: document that marshaling invalid utf-8 sequence will return errorShenghou Ma
Also added docs for InvalidUTF8Error. Fixes #5360. R=golang-dev, adg, r CC=golang-dev https://golang.org/cl/8926046
2013-04-29fmt: fix crash for Printf("%.", 3)Rob Pike
Fixes #5311 R=golang-dev, bradfitz, iant CC=golang-dev https://golang.org/cl/8961050
2013-04-30runtime: fix stack pointer corruption in runtime.cgocallback_gofunc()Shenghou Ma
runtime.setmg() calls another function (cgo_save_gm), so it must save LR onto stack. Re-enabled TestCthread test in misc/cgo/test. Fixes #4863. R=golang-dev, r CC=golang-dev https://golang.org/cl/9019043
2013-04-29fmt: document that if String or Error panics, that value is printedIan Lance Taylor
Fixes #5350. R=r, minux.ma CC=golang-dev https://golang.org/cl/8950043
2013-04-29net/http/httptest: fix incorrectly-named ResponseRecorder exampleAndrew Gerrand
R=golang-dev, minux.ma, r CC=golang-dev https://golang.org/cl/8545047
2013-04-27math/rand: fix typo and add better crash messageBrad Fitzpatrick
R=golang-dev, r CC=golang-dev https://golang.org/cl/9000043
2013-04-28runtime: tune appendCrossover for armDave Cheney
Turns out the optimal value is 8 on cortex-A9 systems (pandaboard) benchmark old ns/op new ns/op delta BenchmarkAppend 907 908 +0.11% BenchmarkAppend1Byte 101 101 +0.00% BenchmarkAppend4Bytes 116 116 +0.00% BenchmarkAppend8Bytes 139 138 -0.72% BenchmarkAppend16Bytes 185 158 -14.59% BenchmarkAppend32Bytes 131 131 +0.00% BenchmarkAppendStr1Byte 72 72 +0.00% BenchmarkAppendStr4Bytes 93 93 -0.21% BenchmarkAppendStr8Bytes 116 116 +0.00% BenchmarkAppendStr16Bytes 161 125 -22.36% BenchmarkAppendStr32Bytes 102 102 +0.00% BenchmarkAppendSpecialCase 613 613 +0.00% R=golang-dev, r CC=golang-dev https://golang.org/cl/8863045
2013-04-26database/sql/driver: try to unstutter Value docsBrad Fitzpatrick
R=golang-dev, r CC=golang-dev https://golang.org/cl/8981043
2013-04-26time: stop 1ns timer in testDmitriy Vyukov
R=golang-dev, adg, r CC=golang-dev https://golang.org/cl/8819046
2013-04-25database/sql: fix driver Conn refcounting with prepared statementsBrad Fitzpatrick
The refcounting of driver Conns was completedly busted and would leak (be held open forever) with any reasonable load. This was a significant regression from Go 1.0. The core of this patch is removing one line: s.db.addDep(dc, s) A database conn (dc) is a resource that be re-created any time (but cached for speed) should not be held open forever with a dependency refcount just because the Stmt (s) is alive (which typically last for long periods of time, like forever). The meat of the patch is new tests. In fixing the real issue, a lot of tests then failed due to the fakedb_test.go's paranoia about closing a fakeConn while it has open fakeStmts on it. I could've ignored that, but that's been a problem in the past for other bugs. Instead, I now track per-Conn open statements and close them when the the conn closes. The proper way to do this would've been making *driverStmt a finalCloser and using the dep mechanism, but it was much more invasive. Added a TODO instead. I'd like to give a way for drivers to opt-out of caring about driver.Stmt closes before a driver.Conn close, but that's a TODO for the future, and that TODO is added in this CL. I know this is very late for Go 1.1, but database/sql is currently nearly useless without this. I'd like to believe all these database/sql bugs in the past release cycle are the result of increased usage, number of drivers, and good feedback from increasingly-capable Go developers, and not the result of me sucking. It's also hard with all the real drivers being out-of-tree, so I'm having to add more and more hooks to fakedb_test.go to simulate things which real drivers end up doing. Fixes #5323 R=golang-dev, snaury, gwenn.kahz, google, r CC=golang-dev https://golang.org/cl/8836045
2013-04-25cmd/gc: initialize t->width in dgcsym() if requiredJan Ziak
Update #5291. R=golang-dev, daniel.morsing, iant, r CC=golang-dev https://golang.org/cl/8663052
2013-04-25undo CL 8954044 / ad3c2ffb16d7Jan Ziak
It works on i386, but fails on amd64 and arm. ««« original CL description runtime: prevent the GC from seeing the content of a frame in runfinq() Fixes #5348. R=golang-dev, dvyukov CC=golang-dev https://golang.org/cl/8954044 »»» R=golang-dev, r CC=golang-dev https://golang.org/cl/8695051
2013-04-25runtime: prevent the GC from seeing the content of a frame in runfinq()Jan Ziak
Fixes #5348. R=golang-dev, dvyukov CC=golang-dev https://golang.org/cl/8954044