1
0
mirror of https://github.com/golang/go synced 2024-09-24 23:10:12 -06:00
Commit Graph

5319 Commits

Author SHA1 Message Date
Evan Shaw
76cbbc8a95 big: Add Lsh and Value; convert pidigits to use big
This yields a pretty significant performance boost to pidigits and there are still some improvements to be made. Here are my numbers:

amd64 w/ bignum:
pidigits 10000
        gcc -O2 pidigits.c -lgmp        2.10u 0.00s 2.10r
        gc pidigits     22.92u 0.02s 22.97r
        gc_B pidigits   22.62u 0.00s 22.65r

amd64 w/ big:
pidigits 10000
        gcc -O2 pidigits.c -lgmp        2.09u 0.02s 2.11r
        gc pidigits     12.68u 0.04s 12.72r
        gc_B pidigits   12.71u 0.03s 12.75r

386 w/ bignum:
pidigits 10000
        gcc -O2 pidigits.c -lgmp        2.09u 0.00s 2.09r
        gc pidigits     44.30u 0.01s 44.35r
        gc_B pidigits   44.29u 0.03s 44.35r

386 w/ big:
pidigits 10000
        gcc -O2 pidigits.c -lgmp        2.10u 0.00s 2.10r
        gc pidigits     22.70u 0.06s 22.79r
        gc_B pidigits   22.80u 0.09s 22.91r

R=rsc, gri
CC=golang-dev
https://golang.org/cl/881050
2010-04-20 20:39:36 -07:00
Russ Cox
4ba177ae36 gc: print x[y:] correctly
R=ken2
CC=golang-dev
https://golang.org/cl/955041
2010-04-20 17:39:31 -07:00
Russ Cox
20c50cf0f8 runtime: rename cgo2c, *.cgo to goc2c, *.goc
to avoid confusion with real cgo

R=r
CC=golang-dev
https://golang.org/cl/904046
2010-04-20 17:03:25 -07:00
Russ Cox
7295b61cdb reflect: implement Set(nil), SetValue(nil) for PtrValue and MapValue
R=r
CC=golang-dev
https://golang.org/cl/823048
2010-04-20 17:02:08 -07:00
Evan Shaw
73374c93a6 big: Get rid of function pointers and init function
R=rsc, gri
CC=golang-dev
https://golang.org/cl/929041
2010-04-19 19:07:22 -07:00
Andrew Gerrand
8df3121353 godashboard: remove obselete data models and conversion code
R=rsc
CC=golang-dev
https://golang.org/cl/919045
2010-04-20 10:20:15 +10:00
Kyle Consalus
ad2c5a4984 Added strings.FieldsFunc, a generalization of strings.Fields in style of the strings.Trim*Func functions.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/824051
2010-04-19 16:36:50 -07:00
Andrew Gerrand
47c4416b7e godashboard: bz2 compress logs in data store
This results in a 10-20x size reduction per record.
(from ~150kb to ~10kb)

This revision has been pushed live, as I'm in the process of
converting Log records to bz2-compresed CompressedLog records.
I would have waited but we're running seriously low on space
and it seemed like a sane (and reversible) move.

R=rsc
CC=golang-dev
https://golang.org/cl/872048
2010-04-20 09:06:57 +10:00
Evan Shaw
93c750d80a gc benchmark: Update package list
Some old packages on the list were preventing this benchmark from working.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/820045
2010-04-19 15:41:40 -07:00
Russ Cox
d97bbabbaa gc: cmplx typecheck bug fix
Fixes #729.

R=ken2
CC=golang-dev
https://golang.org/cl/875048
2010-04-19 09:21:51 -07:00
Andrew Gerrand
3ffbd57b94 syscall: match linux Setsid function signature to darwin
SETSID does return an errno - any reason why it has been done this
way in zsyscall_linux_* ? Otherwise it should be the same as darwin.

From SETSID(2) on my Linux box:

ERRORS
       On error, -1 is returned, and errno is set.

Fixes #730

R=rsc
CC=golang-dev
https://golang.org/cl/878047
2010-04-19 13:12:11 +10:00
Raif S. Naffah
57e764171c reflect: add FieldByNameFunc
xml: add support for XML marshalling embedded structs.

R=rsc
CC=golang-dev
https://golang.org/cl/837042
2010-04-18 15:22:36 -07:00
Michael Hoisie
13f81feb31 net: fix bugs in packStructValue
packStructValue was cutting off last byte of uint32
in _Dns_msg.Unpack, use packRR for rr types

R=rsc
CC=golang-dev
https://golang.org/cl/844048
2010-04-18 14:46:24 -07:00
Russ Cox
3cfa2c3ddf json: scanner, Compact, Indent, and tests
This is the first of probably four separate CLs
for the new implementation of the json package.

The scanner is the core of the new implementation.
The other CLs would be the new decoder,
the new encoder, and support for JSON streams.

R=r
CC=golang-dev
https://golang.org/cl/802051
2010-04-18 14:45:08 -07:00
Rob Pike
3f7da4f861 rpc: Add Close() method to rpc.Client to allow graceful connection teardown.
Fixes #675.

R=rsc, msolo
CC=golang-dev
https://golang.org/cl/882049
2010-04-16 16:17:47 -07:00
Kai Backman
0b2e0265ae the android runner script
this is a version synthesized from rsc's, dean's and my
	versions. changes and updates:

	- embeds the retval script and pushes a new version to the
          device if needed
	- passes arguments correctly to the program on the device
	- export GOARCH, GOTRACEBACK and GOGC from the local
          environment to the device.
	- added times.out support to run-arm

	enabled a few tests that are now passing and moved the
	GOGC=off workaround to run-arm.

R=dpx
CC=golang-dev, rsc
https://golang.org/cl/880046
2010-04-16 13:06:45 +03:00
Andrew Gerrand
a8c18e14ef add Sam Thorogood (of Google Inc.) to CONTRIBUTORS
R=r
CC=golang-dev
https://golang.org/cl/890048
2010-04-16 17:40:49 +10:00
Evan Shaw
9ca10b0a5c exp/eval: Always read float literals as base 10
We were letting bignum decide, which caused problems with float literals with a leading 0.

R=gri
CC=golang-dev
https://golang.org/cl/816047
2010-04-15 19:53:35 -07:00
Evan Shaw
ff922fe15a go/ast: Update comment to mention imaginary literals
R=gri
CC=golang-dev
https://golang.org/cl/846050
2010-04-15 18:06:22 -07:00
Evan Shaw
39a2e82ee6 exp/eval: Implement x[lo:]
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/908044
2010-04-15 18:04:24 -07:00
Russ Cox
a318f9d3a4 flag: eliminate unnecessary structs
R=r
CC=golang-dev
https://golang.org/cl/872045
2010-04-15 15:25:46 -07:00
Andrei Vieru
fffac8072e "godoc -src pkg_name" excludes duplicates entries
$ godoc xml | grep Copy\(\)
func (c CharData) Copy() CharData
func (c Comment) Copy() Comment
func (d Directive) Copy() Directive
func (p ProcInst) Copy() ProcInst
func (e StartElement) Copy() StartElement
--------------------------------------------
$ godoc -src xml | grep Copy\(\)
func (c CharData) Copy() CharData
--------------------------------------------
$ godoc -src xml Copy
func (c CharData) Copy() CharData { return CharData(makeCopy(c)) }
--------------------------------------------
The command "godoc -src pkg_name" should output the interface of the named package, but it excludes all duplicate entries. Also the command "godoc -src pkg_name method_name" will output the source code only for one method even if there are more of them with the same name in the same package. This patch set fixes this issue.

R=gri
CC=golang-dev
https://golang.org/cl/883051
2010-04-15 09:50:37 -07:00
Kai Backman
df3a544085 synchronize ARM runner environment variable with run-arm
R=rsc
CC=golang-dev
https://golang.org/cl/912041
2010-04-15 12:47:49 +03:00
Kai Backman
26e846429d support for printing floats:
fmt.Printf("float32 %f\n", float32(1234.56789))
fmt.Printf("float64 %f\n", float64(1234.56789))
->
float32 1234.567871
float64 1234.567890

this is a snapshot. extended instruction support, corner cases
and fixes coming in subseuent cls.

R=rsc
CC=dpx, golang-dev
https://golang.org/cl/876045
2010-04-15 12:43:49 +03:00
Robert Griesemer
0fd00c8bb7 scanner: implement Peek() to look at the next char w/o advancing
R=rsc
CC=golang-dev
https://golang.org/cl/840045
2010-04-14 21:33:34 -07:00
Russ Cox
1baf35e41f bytes: shuffle implementation, making WriteByte 50% faster
R=r
CC=golang-dev
https://golang.org/cl/920041
2010-04-14 01:52:56 -07:00
Andrew Gerrand
ba1e025fa3 release.2010-04-13 part two
R=rsc, r
CC=golang-dev
https://golang.org/cl/896045
2010-04-14 15:48:48 +10:00
Russ Cox
c3e54f0988 runtime: better trace for fault due to nil pointer call
R=r
CC=golang-dev
https://golang.org/cl/854048
2010-04-13 22:31:47 -07:00
Alex Brainman
035265975f os, syscall: mingw bug fixes
R=rsc
CC=golang-dev
https://golang.org/cl/815044
2010-04-13 22:30:41 -07:00
Russ Cox
6aad41919b go_spec updates
R=r, iant
CC=golang-dev
https://golang.org/cl/921041
2010-04-13 20:55:57 -07:00
Andrew Gerrand
93efe475bf release.2010-04-13
R=rsc, r
CC=golang-dev
https://golang.org/cl/902045
2010-04-14 11:49:47 +10:00
Alex Brainman
b07e4d9511 os: mingw version of Readdir() and Stat() implemented
R=rsc
CC=golang-dev
https://golang.org/cl/851045
2010-04-13 16:30:11 -07:00
Evan Shaw
30f981d980 8l: add DOS stub to PE binaries
R=rsc
CC=golang-dev
https://golang.org/cl/915041
2010-04-13 16:13:53 -07:00
Rob Pike
1b56947f84 netchan: allow client to send as well as receive.
much rewriting and improving, but it's still experimental.

R=rsc
CC=golang-dev
https://golang.org/cl/875045
2010-04-13 13:49:42 -07:00
Rob Pike
effddcadc4 template: use panic/recover to simplify internal error handling.
R=rsc
CC=golang-dev
https://golang.org/cl/824049
2010-04-13 13:28:08 -07:00
Ian Lance Taylor
cd242fb480 Use the copy function rather than a loop.
R=r
CC=golang-dev
https://golang.org/cl/882047
2010-04-13 13:05:29 -07:00
Christopher Wedgwood
d80c78b62f test: minor updates to avoid bitrot
R=rsc, r
CC=golang-dev
https://golang.org/cl/854046
2010-04-12 18:10:29 -07:00
Christopher Wedgwood
74d0302eb9 Remove exp/exception as it's no longer relevant
R=gri, adg
CC=golang-dev, r, rsc
https://golang.org/cl/857048
2010-04-13 10:51:35 +10:00
Rob Pike
c701c38e13 fixes for rpc:
- don't log normal EOF
- fix ServeConn to block as documented

R=rsc, msolo
CC=golang-dev
https://golang.org/cl/886043
2010-04-12 17:14:28 -07:00
Russ Cox
d9254d00f9 gc: zero unnamed return values on entry if func has defer
R=ken2
CC=golang-dev
https://golang.org/cl/891050
2010-04-12 14:28:27 -07:00
Christopher Wedgwood
9149d91888 xml: update documentation to match current coding style
R=rsc, r
CC=golang-dev
https://golang.org/cl/891048
2010-04-12 10:28:50 -07:00
Andrei Vieru
1ab15fac22 fmt format verb %b bug
fmt.Printf("%b", int8(-1)) prints 64 ones instead of 8.
This happens only for signed integers (int8, in16 and int32). I guess it's because of the way the conversion between integer types works. From go spec: "Conversions between integer types. If the value is a signed quantity, it is sign extended to implicit infinite precision ....". And there are several conversions to int64 and uint64 in the fmt package. This pathch solves only half of the problem. On a 32 bit system, an fmt.Printf("%b", int(-1)) should still print 64 ones.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/891049
2010-04-12 10:20:06 -07:00
Rob Pike
8a68b8287b CLA: Andrei Vieru
R=rsc
CC=golang-dev
https://golang.org/cl/890044
2010-04-12 10:11:18 -07:00
Christopher Wedgwood
10f7f80fae json: update documentation to match current coding style
R=rsc
CC=golang-dev
https://golang.org/cl/888045
2010-04-11 22:09:34 -07:00
Russ Cox
c9293f0cc7 gc: compile s == "" as len(s) == 0
R=ken2
CC=golang-dev
https://golang.org/cl/840043
2010-04-11 15:24:44 -07:00
Russ Cox
9475cafa73 gc: distinguish fatal compiler bug from error+exit
R=ken2
CC=golang-dev
https://golang.org/cl/902044
2010-04-11 14:52:06 -07:00
Russ Cox
fe7826858c gc: make sure main.main has correct type
R=ken2
CC=golang-dev
https://golang.org/cl/883049
2010-04-11 14:51:35 -07:00
Evan Shaw
d77010547d debug/elf: Fix doc comments
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/849049
2010-04-11 14:49:44 -07:00
Evan Shaw
fa860653ae exp/eval: Fix example and add target to Makefile
R=rsc
CC=golang-dev
https://golang.org/cl/901042
2010-04-11 12:42:19 -07:00
Christopher Wedgwood
ae729a433f archive/tar: update documentation to match current coding style
R=rsc, r
CC=golang-dev
https://golang.org/cl/903044
2010-04-11 10:29:07 -07:00