aboutsummaryrefslogtreecommitdiff
path: root/src/cmd
AgeCommit message (Collapse)Author
2013-10-18go1.2rc2go1.2rc2Andrew Gerrand
2013-10-18api: add go1.2.txt, use in testsAndrew Gerrand
R=golang-dev, iant CC=golang-dev https://golang.org/cl/14860043
2013-10-15cmd/cgo: simpler fix for issue 6506.Shenghou Ma
Replaces CL 14682044. Fixes #6506. R=rsc, iant, dave CC=golang-dev https://golang.org/cl/14717043
2013-10-15cmd/cgo: print the builtin prolog after the per-file preambleRuss Cox
The preamble may want to #define some special symbols and then #include <sys/types.h> itself. The builtin prolog also #includes <sys/types.h>, which would break such a preamble (because the second #include will be a no-op). The use of sys/types.h in the builtin prolog is new since Go 1.1, so this should preserve the semantics of more existing cgo code than we would otherwise. It also fixes src/pkg/syscall/mkall.sh's use of go tool cgo -godefs on some Linux systems. Thanks to fullung@ for identifying the problem. Fixes #6558. R=golang-dev, iant CC=golang-dev https://golang.org/cl/14684044
2013-10-15cmd/cgo: fix Xcode 5 incompatibility for #defined expressionsRuss Cox
Ensure that clang always exits with a non-zero status by giving it something that it always warns about (the statement "1;"). Fixes #6128. R=golang-dev, iant, minux.ma CC=golang-dev https://golang.org/cl/14702043
2013-10-15cmd/cgo: work around bug in clang debug info for builtins like memsetRuss Cox
Fixes #6506. R=golang-dev, r CC=golang-dev https://golang.org/cl/14682044
2013-10-14cmd/gc: fix comment about performing indexing at compile time.Keith Randall
R=golang-dev, r CC=golang-dev https://golang.org/cl/14441070
2013-10-14cmd/api: make it work even when cgo is disabledShenghou Ma
make use of $USER or %USERNAME% to determine the current user. Fixes #6578. R=golang-dev, bradfitz, alex.brainman CC=golang-dev https://golang.org/cl/14649043
2013-10-10cmd/gc: re-word some error messagesShenghou Ma
Fixes #6557. R=golang-dev, rsc, tracey.brendan CC=golang-dev https://golang.org/cl/14432053
2013-10-09cmd/go: add any .c/.cc files to the SWIG shared libraryIan Lance Taylor
Also add the action's object directory to the list of directories we use to find SWIG shared libraries. Fixes #6521. R=golang-dev, minux.ma CC=golang-dev https://golang.org/cl/14369043
2013-10-08cmd/go, runtime: express armv5t architecture constraint differentlyCarl Shapiro
Instead of adding an -march=armv5t flag to the gcc command line, the same effect is obtained with an ".arch armv5t" pseudo op in the assembly file that uses armv5t instructions. R=golang-dev, iant, dave CC=golang-dev https://golang.org/cl/14511044
2013-10-03gofmt: explain why lower bounds aren't automatically simplifiedRobert Hencke
Full credit goes to gri and rsc for their explanations. R=golang-dev, r CC=golang-dev https://golang.org/cl/14229043
2013-10-03cmd/gc: support -installsuffix in the compiler and builderDave Day
Add the -installsuffix flag to gc and {5,6,8}l, which overrides -race for the suffix if both are supplied. Pass this flag from the go tool for build and install. R=rsc CC=golang-dev https://golang.org/cl/14246044
2013-10-02cmd/go: document relative importsRuss Cox
Fixes #3524. R=golang-dev, iant, r CC=golang-dev https://golang.org/cl/14296043
2013-10-02cmd/gc: qualified embedded fields with owner package.Rémy Oudompheng
R=rsc CC=golang-dev https://golang.org/cl/14188044
2013-10-01cmd/dist, build: support building statically linked toolchainShenghou Ma
Added a new $GO_DISTFLAGS to make.bash, and while we're here, added mention $CXX in make.bash (CL 13704044). Fixes #6448. Update #3564 We can pass GO_DISTFLAGS=-s from misc/dist to make.bash so that it will build a statically linked toolchain. (Note: OS X doesn't have the concept of static linking, so don't pass GO_DISTFLAGS=-s for OS X builds) R=adg, rsc, iant CC=golang-dev https://golang.org/cl/13887043
2013-10-01cmd/go: use -installsuffix to determine the includes directory listDave Day
Currently, the directories generaed by includeArgs can have the "_race" suffix added if invoked with -race flag, but ignores -installsuffix if set. R=adg, rsc CC=golang-dev https://golang.org/cl/14174043
2013-09-25cmd/go: "go test -c -test.bench=XX fmt" shouldn't hangShenghou Ma
Fixes #6480. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/13925043
2013-09-24cmd/cgo: fix so that tests pass again when using gccgoIan Lance Taylor
Use the symbol prefixes with the prologue functions when using gccgo. Use an & when referring to a function declared as a variable. Fix the malloc prologue function. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/13878043
2013-09-24cmd/cgo: retain Go pointer passed to C call for duration of callRuss Cox
Fixes #6397. R=golang-dev, bradfitz, iant CC=golang-dev https://golang.org/cl/13858043
2013-09-24cmd/dist, cmd/go: embed default C++ compiler into cmd/goShenghou Ma
Fixes #6426. R=golang-dev, dave, rsc CC=golang-dev https://golang.org/cl/13704044
2013-09-23cmd/cgo: update #cgo docs to reflect realityRuss Cox
The syntax accepted is full build constraints, not just GOOS, GOARCH, and GOOS/GOARCH. R=golang-dev, iant CC=golang-dev https://golang.org/cl/13504048
2013-09-23cmd/ld: fix "_image_base__ not defined" problem for cmd/8l.Shenghou Ma
Fixes #6431. Change suggested by kin.wilson.za. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/13314048
2013-09-22cmd/api: always do API check if hg is availableBrad Fitzpatrick
Fixes #6124 R=golang-dev, minux.ma CC=golang-dev https://golang.org/cl/13500046
2013-09-20cmd/yacc: report correct line for 'default action causes potential type clash'Russ Cox
R=golang-dev, iant CC=golang-dev https://golang.org/cl/13588044
2013-09-20cmd/gc: fix imported and not used error for import .Russ Cox
Fixes issues 6420. R=ken2 CC=golang-dev https://golang.org/cl/13703044
2013-09-20cmd/gc: print expression in 'duplicate case in switch' errorRuss Cox
The line number alone does not help when the line is case '~', '*', '(', ')', '[', ']', '{', '}', '?', ':', ';', ',', '*', '%', '^', '!', '=', '<', '>', '+', '-', '&', '|': R=ken2 CC=golang-dev https://golang.org/cl/13431046
2013-09-20cmd/ld: fix "ld -s" to not discard pclntab.Shenghou Ma
Fixes #6245. R=golang-dev, bradfitz, rsc CC=golang-dev https://golang.org/cl/13751045
2013-09-19cmd/gc: cleanup SWITCH nodes after walk.Rémy Oudompheng
Keeping pointers from the pre-walk phase confuses the race detection instrumentation. Fixes #6418. R=golang-dev, dvyukov, r CC=golang-dev https://golang.org/cl/13368057
2013-09-19cmd/ld: handle IMAGE_SYM_CLASS_LABEL symbols.Shenghou Ma
Was causing "invalid symbol binding" and thus "malformed pe file" error. R=golang-dev, alex.brainman, adg CC=golang-dev https://golang.org/cl/13722050
2013-09-19cmd/go: fix missing __mingw_fprintf symbol for cgo on windowsShenghou Ma
Fixes #5986. R=golang-dev, rsc, alex.brainman CC=golang-dev https://golang.org/cl/13261055
2013-09-18cmd/ld: handle duplicate static symbols in COFF and Mach-O files.Shenghou Ma
Fixes #5740. R=iant, rsc, luisbebop CC=gobot, golang-dev https://golang.org/cl/10345046
2013-09-19cmd/go: write the WORK=/tmp/... line to stderrRob Pike
Unlike the other output from the -x flag, it was going to stdout. Fixes #6362. R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/13746044
2013-09-18cmd/gc: fix set but not used errorDave Cheney
R=rsc, r CC=golang-dev https://golang.org/cl/13749044
2013-09-17cmd/go: add basic docs on calling between Go and C/C++Ian Lance Taylor
This is a framework for docs on the subject more than it is actual docs. The section header in go/doc.go just says "C", not "C/C++," because otherwise godoc doesn't recognize the line as a section header. Fixes #5473. R=golang-dev, r CC=golang-dev https://golang.org/cl/13280050
2013-09-17cmd/gc: eliminate redundant &x.Field nil checksRuss Cox
This eliminates ~75% of the nil checks being emitted, on all architectures. We can do better, but we need a bit more general support from the compiler, and I don't want to do that so close to Go 1.2. What's here is simple but effective and safe. A few small code generation cleanups were required to make the analysis consistent on all systems about which nil checks are omitted, at least in the test. Fixes #6019. R=ken2 CC=golang-dev https://golang.org/cl/13334052
2013-09-17cmd/cgo: rearrange and update documentationIan Lance Taylor
In particular document that the Go tool will look for certain file extensions and compile with them with either the C or the C++ compiler. Fixes #6393. R=golang-dev, r CC=golang-dev https://golang.org/cl/13733043
2013-09-17cmd/6c, cmd/6g, cmd/cc: fix undefined behavior warningsDave Cheney
Update #5764 Like Tribbles, the more you kill, the more spring up in their place. R=rsc CC=golang-dev https://golang.org/cl/13324049
2013-09-16cmd/gc, runtime: inline append in frontend.Rémy Oudompheng
A new transformation during walk turns append calls into a combination of growslice and memmove. benchmark old ns/op new ns/op delta BenchmarkAppend 141 141 +0.00% BenchmarkAppend1Byte 18 11 -39.56% BenchmarkAppend4Bytes 19 10 -42.63% BenchmarkAppend7Bytes 18 10 -42.16% BenchmarkAppend8Bytes 18 10 -40.44% BenchmarkAppend15Bytes 19 11 -41.67% BenchmarkAppend16Bytes 19 11 -41.97% BenchmarkAppend32Bytes 23 14 -38.82% BenchmarkAppendStr1Byte 14 10 -23.78% BenchmarkAppendStr4Bytes 14 11 -21.13% BenchmarkAppendStr8Bytes 14 10 -25.17% BenchmarkAppendStr16Bytes 19 11 -41.45% BenchmarkAppendStr32Bytes 18 14 -19.44% BenchmarkAppendSpecialCase 62 63 +1.77% R=golang-dev, khr, cshapiro, rsc, dave CC=golang-dev https://golang.org/cl/12815046
2013-09-16cmd/nm: make -S listing a bit more accurateRuss Cox
Hide container symbols like text and etext so that the individual pieces inside are shown instead. For example, if text and main.init have the same address, it was a toss-up which name was printed. R=golang-dev, iant CC=golang-dev https://golang.org/cl/13722046
2013-09-16build: disable precise collection of stack framesRuss Cox
The code for call site-specific pointer bitmaps was not ready in time, but the zeroing required without it is too expensive to use by default. We will have to wait for precise collection of stack frames until Go 1.3. The precise collection can be re-enabled by GOEXPERIMENT=precisestack ./all.bash but that will not be the default for a Go 1.2 build. Fixes #6087. R=golang-dev, jeremyjackins, dan.kortschak, r CC=golang-dev https://golang.org/cl/13677045
2013-09-16cmd/cgo: remove inaccurate commentIan Lance Taylor
All these features have in fact been implemented. R=rsc CC=golang-dev https://golang.org/cl/13419049
2013-09-16cmd/gc: do not report fields when looking for methodsRuss Cox
Fixes #6395. R=ken2 CC=golang-dev https://golang.org/cl/13470046
2013-09-16cmd/gc: fix divide by zero error in compilerRuss Cox
Fixes #6399. R=ken2 CC=golang-dev https://golang.org/cl/13253055
2013-09-16cmd/cgo: allow C.malloc(0) alwaysRuss Cox
Because we can, and because it otherwise might crash the program if we think we're out of memory. Fixes #6390. R=golang-dev, iant, minux.ma CC=golang-dev https://golang.org/cl/13345048
2013-09-16cmd/go: document that "main" is a reserved import pathRob Pike
Fixes #6312. R=golang-dev, dave CC=golang-dev https://golang.org/cl/13391049
2013-09-16cmd/nm: put the -S flag in the usage messageRob Pike
The -S flag reports symbol size, but is missing from the usage message. R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/13660046
2013-09-16cmd/gofmt: document -s transformationsAndrew Gerrand
R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/13721043
2013-09-14cmd/gc: don't generate algs for internal map types.Rémy Oudompheng
Fake types describing the internal structure of hashmaps are generated for use by precise GC. Generating hash and eq functions for these fake types slows down the build and wastes space: the go tool binary size is 13MB instead of 12MB, and the package size on amd64 is 48.7MB instead of 45.3MB. R=golang-dev, daniel.morsing, r, khr, rsc, iant CC=golang-dev https://golang.org/cl/13698043
2013-09-13cmd/5l: fix handling of RET.EQ in wrapper functionRuss Cox
Keith is too clever for me. R=ken2 CC=golang-dev, khr https://golang.org/cl/13272050