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

7166 Commits

Author SHA1 Message Date
Anthony Martin
85f5bb8216 test/bench: a couple fixes to timing.sh
- Skip the gccgo tests if we don't have it
- Add -lm so nbody.c will compile
- Pass 2098 to the meteor test (cf. the shootout site)

R=rsc, r, iant
CC=golang-dev
https://golang.org/cl/3619042
2010-12-15 09:47:13 -05:00
Luuk van Dijk
7a4ce23d65 [68]l and runtime: GDB support for interfaces and goroutines.
R=rsc
CC=golang-dev
https://golang.org/cl/3477041
2010-12-15 12:00:43 +01:00
Nigel Tao
d96685ed6a reflect: remove unnecessary indirection in TestCopy.
R=r
CC=golang-dev
https://golang.org/cl/3642041
2010-12-15 20:54:11 +11:00
Rob Pike
670e77b54d govet: allow directories as arguments, process recursively.
R=gri
CC=golang-dev
https://golang.org/cl/3652041
2010-12-14 17:09:24 -08:00
Ryan Hitchman
5742ded3ad godashboard: support submitting projects with non-ascii names
Fixes #1314.

R=adg, rsc
CC=golang-dev
https://golang.org/cl/3459043
2010-12-15 12:07:30 +11:00
Nigel Tao
fec6ab9726 html: parse "<h1>foo<h2>bar".
R=gri
CC=golang-dev
https://golang.org/cl/3571043
2010-12-15 11:39:56 +11:00
Rob Pike
8132bb1c74 gob: Register should use the original type, not the indirected one.
Fixes a bug reported on golang-nuts.

R=rsc, adg
CC=golang-dev
https://golang.org/cl/3641042
2010-12-14 15:04:52 -08:00
Christopher Wedgwood
56452c53ee govet: on error continue to the next file
R=r, rsc
CC=golang-dev
https://golang.org/cl/3578041
2010-12-14 14:12:22 -08:00
Rob Pike
9f6de01d8d gob: document the byte count used in the encoding of values.
R=rsc
CC=golang-dev
https://golang.org/cl/3641041
2010-12-14 14:04:52 -08:00
Nigel Tao
8b64cd9c5e reflect: add Append and AppendSlice functions.
R=r, nigeltao_gnome, rog, niemeyer
CC=golang-dev
https://golang.org/cl/3529042
2010-12-15 08:50:08 +11:00
Rob Pike
da1cbe5d11 regexp: simplify code for brackets, per rsc suggestion
R=rsc
CC=golang-dev
https://golang.org/cl/3545044
2010-12-14 12:01:35 -08:00
Russ Cox
f620a430f2 compress/flate: implement Flush
This Flush is equivalent to zlib's Z_SYNC_FLUSH.
The addition of the explicit Writer type opens the
door to adding a PartialFlush if needed for SSH
and maybe even FullFlush.  It also opens the door
for a SetDictionary method to be added.

http://www.bolet.org/~pornin/deflate-flush.html
documents the various intricacies of flushing a
DEFLATE stream.

R=agl1, r
CC=golang-dev
https://golang.org/cl/3637041
2010-12-14 14:57:12 -05:00
Rob Pike
8bb9e616ed regexp: speed up by about 30%.
The code used interfaces in a pretty, pedagogical way but not efficiently.
Remove unnecessary interface code for significant speedups.
Before:

	regexp.BenchmarkLiteral	 1000000	      2629 ns/op
	regexp.BenchmarkNotLiteral	  100000	     18131 ns/op
	regexp.BenchmarkMatchClass	  100000	     26647 ns/op
	regexp.BenchmarkMatchClass_InRange	  100000	     27092 ns/op
	regexp.BenchmarkReplaceAll	  100000	     27014 ns/op

After:

	regexp.BenchmarkLiteral	 1000000	      2077 ns/op
	regexp.BenchmarkNotLiteral	  100000	     13738 ns/op
	regexp.BenchmarkMatchClass	  100000	     20418 ns/op
	regexp.BenchmarkMatchClass_InRange	  100000	     20999 ns/op
	regexp.BenchmarkReplaceAll	  100000	     21825 ns/op

There's likely more to do without major surgery, but this is a simple, significant step.

R=rsc
CC=golang-dev
https://golang.org/cl/3572042
2010-12-14 11:15:32 -08:00
Robert Griesemer
3fb6d62e3a suffixarray: rename Data() -> Bytes()
R=rsc
CC=golang-dev
https://golang.org/cl/3540042
2010-12-14 10:22:00 -08:00
Anthony Martin
d7340d9c20 http: include DEL in the test for unprintable chars
R=adg, rsc
CC=golang-dev
https://golang.org/cl/3631041
2010-12-14 12:26:30 -05:00
Anthony Martin
add32466bf build: remove intermediate yacc files in Make.ccmd
R=rsc
CC=golang-dev
https://golang.org/cl/3545042
2010-12-14 12:22:40 -05:00
Anthony Martin
6a4b0191c0 crypto/tls: use rand.Reader in cert generation example
R=rsc, agl1
CC=golang-dev
https://golang.org/cl/3536043
2010-12-14 12:22:28 -05:00
Anthony Martin
11b49ff124 smtp: add *tls.Config argument to StartTLS
R=rsc, agl1
CC=golang-dev
https://golang.org/cl/3573044
2010-12-14 12:22:08 -05:00
Russ Cox
d110ae8dd0 runtime: write only to standard error
Will mail a warning to golang-nuts once this is submitted.

R=r, niemeyer
CC=golang-dev
https://golang.org/cl/3573043
2010-12-14 11:52:42 -05:00
Russ Cox
43f459ce51 typo
R=iant
CC=golang-dev
https://golang.org/cl/3582042
2010-12-14 11:33:17 -05:00
Anthony Martin
11a016151b go spec: fix two grammar typos
R=gri
CC=golang-dev
https://golang.org/cl/3580042
2010-12-13 22:19:41 -08:00
Robert Griesemer
6fcae0f044 token/position: provide files iterator
R=golang-dev, r2
CC=golang-dev
https://golang.org/cl/3541044
2010-12-13 17:08:40 -08:00
Robert Griesemer
52c9fb6f3d suffixarray: provide accessor to data
R=r
CC=golang-dev
https://golang.org/cl/3574044
2010-12-13 17:08:01 -08:00
Russ Cox
7ff68b365b go_mem: goroutine exit is not special
R=r
CC=golang-dev
https://golang.org/cl/3628041
2010-12-13 17:08:27 -05:00
Russ Cox
951318c0df runtime: remove paranoid mapping at 0
Too many programs complain that we even try.
This was a bit of security paranoia and not worth
the bother.

Fixes #1340.

R=r, r2
CC=golang-dev
https://golang.org/cl/3579042
2010-12-13 16:57:35 -05:00
Rob Pike
2ef09148a0 time: fix bug in Ticker: shutdown using channel rather than memory
R=rsc
CC=golang-dev
https://golang.org/cl/3609042
2010-12-13 13:52:19 -08:00
Russ Cox
1b31c37428 gc: issue 1231
Fixes #1231.

R=ken2
CC=golang-dev
https://golang.org/cl/3627041
2010-12-13 16:51:19 -05:00
Russ Cox
dc9a3b2791 gc: align structs according to max alignment of fields
cc: same
runtime: test cc alignment (required moving #define of offsetof to runtime.h)
fix bug260

Fixes #482.
Fixes #609.

R=ken2, r
CC=golang-dev
https://golang.org/cl/3563042
2010-12-13 16:22:19 -05:00
Russ Cox
287e45e241 json: check for invalid UTF-8
Fixes #1250.

R=r
CC=golang-dev
https://golang.org/cl/3562042
2010-12-13 15:51:11 -05:00
Russ Cox
3a2ba994b6 build: add a few missing --no-print-directory
Reported by W. Michael Petullo <mike@flyn.org>

Fixes #1269.

R=r, r2
CC=golang-dev
https://golang.org/cl/3618041
2010-12-13 15:50:57 -05:00
Russ Cox
318c1eeb32 godefs: guard against structs with pad fields
Fixes #1162.

R=r
CC=golang-dev
https://golang.org/cl/3619041
2010-12-13 15:50:47 -05:00
Russ Cox
9e26c4bd1a gc: complex(0)
Fixes #1232.

R=ken2
CC=golang-dev
https://golang.org/cl/3621041
2010-12-13 15:34:45 -05:00
Russ Cox
88cf5564fc ld: missing prototype
R=ken2
CC=golang-dev
https://golang.org/cl/3620041
2010-12-13 15:26:52 -05:00
Russ Cox
603f9feeec gc: another shift bug
Fixes #1316.

R=ken2
CC=golang-dev
https://golang.org/cl/3575042
2010-12-13 13:42:51 -05:00
Russ Cox
9da73612ed cgo: do not reset tag generator between files
Clean up an error message and error exit too.
Insert blank line after "DO NOT EDIT" comment
to keep it from being a doc comment.

Fixes #1213.
Fixes #1222.

R=r
CC=golang-dev
https://golang.org/cl/3608042
2010-12-13 13:20:04 -05:00
Russ Cox
e7a0f67603 gc: introduce explicit alignments
No semantic changes here, but working
toward being able to align structs based
on the maximum alignment of the fields
inside instead of having a fixed alignment
for all structs (issue 482).

R=ken2
CC=golang-dev
https://golang.org/cl/3617041
2010-12-13 11:57:41 -05:00
Russ Cox
96db724cfc gc: emit reflect correct reflect types
Fixes #1169.

R=ken2
CC=golang-dev
https://golang.org/cl/3595043
2010-12-13 10:05:20 -05:00
Russ Cox
c7c16175e0 ld: allow .o files with no symbols
Don't crash in dwarf for foreign functions.

R=ken2
CC=golang-dev
https://golang.org/cl/3576043
2010-12-13 10:05:07 -05:00
Russ Cox
cc1556d9a2 runtime/linux/386: set FPU to 64-bit precision
Fixes #550.

R=r
CC=golang-dev
https://golang.org/cl/3469044
2010-12-13 10:04:53 -05:00
Alex Brainman
84713d46f6 syscall: remove terminating \r and \n from windows error messages
R=rsc, peterGo
CC=golang-dev
https://golang.org/cl/3095042
2010-12-13 17:02:01 +11:00
Wei Guangjing
e04ef7769e Fix windows build.
R=brainman, rsc
CC=golang-dev
https://golang.org/cl/3533041
2010-12-13 16:41:02 +11:00
Gustavo Niemeyer
1f6b6ca9ba A selection of trivials.
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/3606043
2010-12-12 14:16:37 -08:00
Robert Griesemer
5e54e93675 godoc: improved textual search
- improved search result page
- clicking on files shows highlighted search phrase
  (.go files loose their godoc-specific formatting and
  highlighting in this mode - a better solution is in
  the works)
- support for textual results
- fixed bug with non-URL escaped URL parameter (Query)

R=rsc, adg
CC=golang-dev
https://golang.org/cl/3585041
2010-12-12 13:13:07 -08:00
Eoghan Sherry
40ff071e9b 5g/8g, 8l, ld, prof: fix output of 32-bit values
If an %lld argument can be 32 or 64 bits wide, cast to vlong.
If always 32 bits, drop the ll.
Fixes #1336.

R=brainman, rsc
CC=golang-dev
https://golang.org/cl/3580041
2010-12-12 14:40:19 -05:00
Nigel Tao
73fd298901 reflect: rename reflect.ArrayCopy to be reflect.Copy.
R=r
CC=golang-dev
https://golang.org/cl/3601041
2010-12-12 20:27:29 +11:00
Mikio Hara
7ec69c179d gofmt -s -w src
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/3592041
2010-12-11 13:49:45 -08:00
Robert Griesemer
055650daa4 godoc: first cut at textual search
To enable use -fulltext flag; e.g.: godoc -v -fulltext -http=:7777

Enabling the fulltext index will use significantly more memory as
the text of all source code, the respective suffixarray, and the
file set data structure is kept in memory. At the moment there is
about 6Mb of source code (~1400 files) indexed under GOROOT.
Source code + suffix array together consume 5*(size of source) or
about 30Mb. The file set data structure consumes about 4b/src line.
By default only up to 5000 results are shown for now.

The presentation of the results needs tuning. In particular,
if a string is found, clicking on the respective file does not
highlight them, yet.

At the moment, only Go source files are indexed. Eventually,
the full text index should encompass other files as well.

R=rsc, adg
CC=golang-dev
https://golang.org/cl/3182043
2010-12-10 14:40:22 -08:00
Russ Cox
9282a768cf math: s/MinFloat/SmallestNonzeroFloat/
R=r, gri
CC=golang-dev
https://golang.org/cl/3547042
2010-12-10 11:39:09 -08:00
Russ Cox
e454af4d64 cgo: avoid self-interference of global names
Fixes #1332.

R=iant, iant2
CC=golang-dev
https://golang.org/cl/3555041
2010-12-10 11:32:58 -08:00
Russ Cox
4324a31376 nm: silently ignore .o files in .a files
Update #1334.

R=r
CC=golang-dev
https://golang.org/cl/3553041
2010-12-10 11:32:48 -08:00