]> Cypherpunks repositories - gostls13.git/log
gostls13.git
14 years agoruntime: avoid allocation for fixed strings
Russ Cox [Thu, 20 May 2010 04:33:31 +0000 (21:33 -0700)]
runtime: avoid allocation for fixed strings

R=r
CC=golang-dev
https://golang.org/cl/1083041

14 years agodashboard: reintroduce Benchmark model
Andrew Gerrand [Thu, 20 May 2010 00:53:41 +0000 (17:53 -0700)]
dashboard: reintroduce Benchmark model

R=rsc
CC=golang-dev
https://golang.org/cl/1217046

14 years agoos: add Chtimes function
Brad Fitzpatrick [Thu, 20 May 2010 00:48:53 +0000 (17:48 -0700)]
os: add Chtimes function

R=rsc, r
CC=golang-dev
https://golang.org/cl/1103041

14 years agosyscall: add Utimes on Darwin/FreeBSD, add Futimes everywhere
Russ Cox [Thu, 20 May 2010 00:47:57 +0000 (17:47 -0700)]
syscall: add Utimes on Darwin/FreeBSD, add Futimes everywhere

Needed for CL 1103041 and beyond.

R=adg, bradfitzpatrick
CC=bradfitz, golang-dev
https://golang.org/cl/1172042

14 years agobug275: cannot apply real() to a complex array element
Robert Griesemer [Wed, 19 May 2010 20:10:00 +0000 (13:10 -0700)]
bug275: cannot apply real() to a complex array element

R=r, ken2
CC=golang-dev
https://golang.org/cl/1260041

14 years agoruntime: allow large map values
Russ Cox [Wed, 19 May 2010 19:57:47 +0000 (12:57 -0700)]
runtime: allow large map values

Fixes #772.

R=ken2
CC=golang-dev
https://golang.org/cl/1206043

14 years agobig: potential bug fix, cleanups
Robert Griesemer [Wed, 19 May 2010 16:36:50 +0000 (09:36 -0700)]
big: potential bug fix, cleanups

- implemented setWord, use it where setUint64 is wrong
- divLarge: use fast mulWW, divWW; implemented mulWW, divWW
- better assembly code for addMulVVW

R=rsc
CC=golang-dev
https://golang.org/cl/1258042

14 years agofix build - arm tests
Russ Cox [Wed, 19 May 2010 06:27:35 +0000 (23:27 -0700)]
fix build - arm tests

TBR=kaib
CC=golang-dev
https://golang.org/cl/1256042

14 years agofix build - no netchan tests under NaCl
Russ Cox [Wed, 19 May 2010 06:25:07 +0000 (23:25 -0700)]
fix build - no netchan tests under NaCl

TBR=r
CC=golang-dev
https://golang.org/cl/1230042

14 years agobytes: add Trim, TrimLeft, TrimRight, and generic functions
Michael Hoisie [Wed, 19 May 2010 06:01:05 +0000 (23:01 -0700)]
bytes: add Trim, TrimLeft, TrimRight, and generic functions

R=rsc, r
CC=golang-dev
https://golang.org/cl/946045

14 years agogc: Better error when computing remainder of non-int
Evan Shaw [Wed, 19 May 2010 05:41:12 +0000 (22:41 -0700)]
gc: Better error when computing remainder of non-int

Previously the compiler would just emit "internal compiler error" when
trying to compute the remainder of floats or complex types.

R=rsc
CC=golang-dev
https://golang.org/cl/1243041

14 years agomath: amd64 versions of fdim, fmax, fmin
Charles L. Dorian [Wed, 19 May 2010 05:33:50 +0000 (22:33 -0700)]
math: amd64 versions of fdim, fmax, fmin

Uses the SSE2 max, min instructions. Also shorter sqrt_amd64.s

R=rsc
CC=golang-dev
https://golang.org/cl/1216042

14 years agomath: signed zero Sqrt special case
Charles L. Dorian [Wed, 19 May 2010 05:16:01 +0000 (22:16 -0700)]
math: signed zero Sqrt special case

IEEE 754 says: sqrt(-0) = -0

R=rsc
CC=golang-dev
https://golang.org/cl/1098041

14 years agobig: bug fix for division
Robert Griesemer [Tue, 18 May 2010 23:31:49 +0000 (16:31 -0700)]
big: bug fix for division

Fixes #784.

R=rsc
CC=golang-dev
https://golang.org/cl/1196043

14 years ago Trivial optimization.
Kyle Consalus [Tue, 18 May 2010 23:29:24 +0000 (16:29 -0700)]
Trivial optimization.
Cached string indexing in inner loop of Btoui64.

    Before:
    strconv_test.BenchmarkAtoi   5000000           309 ns/op
    strconv_test.BenchmarkAtoiNeg    5000000           325 ns/op
    strconv_test.BenchmarkAtoi64     5000000           465 ns/op
    strconv_test.BenchmarkAtoi64Neg  5000000           469 ns/op

    After:
    strconv_test.BenchmarkAtoi  10000000           182 ns/op
    strconv_test.BenchmarkAtoiNeg   10000000           193 ns/op
    strconv_test.BenchmarkAtoi64    10000000           251 ns/op
    strconv_test.BenchmarkAtoi64Neg 10000000           258 ns/op

R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/1227042

14 years agoAdd Error member to yyLexer type (yyError
Roger Peppe [Mon, 17 May 2010 19:23:48 +0000 (12:23 -0700)]
Add Error member to yyLexer type (yyError
has no access to yylex)

R=ken2, ken3
CC=golang-dev
https://golang.org/cl/813047

14 years agobig: implemented format support for fmt library, MulRange
Robert Griesemer [Sat, 15 May 2010 17:23:41 +0000 (10:23 -0700)]
big: implemented format support for fmt library, MulRange

- support for binary prefix 0b (to match fmt.Format)
- renamed nat.new -> nat.setUint64 for consistency
- more tests

R=r
CC=golang-dev
https://golang.org/cl/1233041

14 years agobuild; allow MAKEFLAGS to be set outside the build scripts
Christopher Wedgwood [Sat, 15 May 2010 17:08:29 +0000 (10:08 -0700)]
build; allow MAKEFLAGS to be set outside the build scripts

R=rsc, r
CC=golang-dev
https://golang.org/cl/1231041

14 years agocmath: add package description
Charles L. Dorian [Sat, 15 May 2010 17:06:54 +0000 (10:06 -0700)]
cmath: add package description

Also update range of Phase and Polar due to signed zero.
[Phase(cmplx(-1, +0)) = pi and Phase(cmplx(-1, -0)) = -pi]

R=rsc, r
CC=golang-dev
https://golang.org/cl/1235041

14 years agogofmt: exclude test w/ illegal syntax from test cases
Robert Griesemer [Fri, 14 May 2010 22:45:53 +0000 (15:45 -0700)]
gofmt: exclude test w/ illegal syntax from test cases

R=adg
CC=golang-dev
https://golang.org/cl/1228041

14 years agogo/printer (gofmt): don't lose mandatory semicolons
Robert Griesemer [Fri, 14 May 2010 22:38:25 +0000 (15:38 -0700)]
go/printer (gofmt): don't lose mandatory semicolons

Fixes #779.

R=r
CC=golang-dev
https://golang.org/cl/1218042

14 years agogo spec: added imaginary literal to semicolon rules (was missing)
Robert Griesemer [Fri, 14 May 2010 20:11:48 +0000 (13:11 -0700)]
go spec: added imaginary literal to semicolon rules (was missing)

- also added links to the respective sections
- reformatted section for better (source html) readability
- added missing closing </li>'s in many places

R=r
CC=golang-dev
https://golang.org/cl/1220041

14 years agoPrevent Printf crashing when giving an extra nil argument.
Roger Peppe [Thu, 13 May 2010 19:49:48 +0000 (12:49 -0700)]
Prevent Printf crashing when giving an extra nil argument.

R=rsc, r
CC=golang-dev
https://golang.org/cl/1195041

14 years agorename 'gordon' to 'gopher'
Andrew Gerrand [Thu, 13 May 2010 18:53:44 +0000 (11:53 -0700)]
rename 'gordon' to 'gopher'

R=r
CC=golang-dev
https://golang.org/cl/1207041

14 years agobug274: test case for issue 777
Robert Griesemer [Thu, 13 May 2010 18:52:04 +0000 (11:52 -0700)]
bug274: test case for issue 777

R=r, iant
CC=golang-dev
https://golang.org/cl/1195042

14 years agohttp: prevent crash if remote server is not responding with "HTTP/"
Robert Griesemer [Tue, 11 May 2010 23:50:20 +0000 (16:50 -0700)]
http: prevent crash if remote server is not responding with "HTTP/"

Fixes #775.

R=rsc
CC=golang-dev
https://golang.org/cl/1180042

14 years agonetchan: be less chatty during gotest
Russ Cox [Tue, 11 May 2010 21:57:08 +0000 (14:57 -0700)]
netchan: be less chatty during gotest

R=r
CC=golang-dev
https://golang.org/cl/1186041

14 years agojson: fix array -> non-array decoding
Russ Cox [Tue, 11 May 2010 21:38:55 +0000 (14:38 -0700)]
json: fix array -> non-array decoding

Fixes #773.

R=adg
CC=golang-dev
https://golang.org/cl/1120042

14 years agodrawGlyphOver optimization.
Nigel Tao [Tue, 11 May 2010 03:35:16 +0000 (13:35 +1000)]
drawGlyphOver optimization.

Timings (as for change 1122043) go from 49ms to 48ms ish. It's
mostly lost in the noise, but it probably doesn't hurt.

R=r
CC=golang-dev
https://golang.org/cl/1179041

15 years agoexp/draw fast path for glyph images.
Nigel Tao [Mon, 10 May 2010 00:32:08 +0000 (10:32 +1000)]
exp/draw fast path for glyph images.

To draw.Draw a 32x32 image.Alpha 10000 times,
Before: 633ms with 10000 mallocs
After: 49ms with 0 mallocs

These times are just blitting an image.Alpha, and do not include
rasterizing a glyph's vector contours to an image.Alpha.

The "generic" test case in draw_test.go tests this fast path.

R=rsc
CC=golang-dev
https://golang.org/cl/1122043

15 years agotemplate: regularize the handling of interfaces, pointers, and
Rob Pike [Sun, 9 May 2010 23:40:38 +0000 (16:40 -0700)]
template: regularize the handling of interfaces, pointers, and
methods when looking up names.
Fixes #764.

R=rsc
CC=golang-dev
https://golang.org/cl/1170041

15 years agojson: accept escaped slash in string scanner
Michael Hoisie [Sun, 9 May 2010 00:34:05 +0000 (17:34 -0700)]
json: accept escaped slash in string scanner

R=rsc
CC=golang-dev
https://golang.org/cl/1173041

15 years agobig: cleanups and performance tuning
Robert Griesemer [Sat, 8 May 2010 20:52:36 +0000 (13:52 -0700)]
big: cleanups and performance tuning

- removed last argument (n) from all core arithmetic routines;
  instead, use the length of the result

- simplified nat.make implementation and chose a better capacity
  for new values, removed a TODO in the process

Changing the constant e from 1 (old) to 4 (new) improved
pidigits -s -n 10000 by ~9% (on a 3.06GHz Intel Core 2 Duo):

user 0m3.882s (old)
user 0m3.549s (new)

R=rsc
CC=golang-dev
https://golang.org/cl/1133043

15 years agobig: more cleanup
Robert Griesemer [Sat, 8 May 2010 01:26:31 +0000 (18:26 -0700)]
big: more cleanup

- pass []Word instead of *Word to core arithmetic functions
- remove dead code

R=rsc
CC=golang-dev
https://golang.org/cl/1154042

15 years agogo spec: simplify section on channel types
Robert Griesemer [Sat, 8 May 2010 01:22:40 +0000 (18:22 -0700)]
go spec: simplify section on channel types

R=rsc, iant, r
CC=golang-dev
https://golang.org/cl/1171041

15 years agocompress: renamings.
Rob Pike [Fri, 7 May 2010 21:32:34 +0000 (14:32 -0700)]
compress: renamings.
NewDeflater -> NewWriter
NewInflater -> NewReader
Deflater -> Compressor
Inflater -> Decompressor

R=rsc
CC=golang-dev
https://golang.org/cl/1166041

15 years agogob: bug fix: errors encoding the payload were not
Rob Pike [Fri, 7 May 2010 20:30:13 +0000 (13:30 -0700)]
gob: bug fix: errors encoding the payload were not
returned to caller.

R=rsc
CC=golang-dev
https://golang.org/cl/1164041

15 years agogob: add an internal commentary example showing how the
Rob Pike [Fri, 7 May 2010 18:44:41 +0000 (11:44 -0700)]
gob: add an internal commentary example showing how the
values are encoded for transmission.

R=rsc
CC=golang-dev
https://golang.org/cl/1146041

15 years agoSave the scheduling state even predawn.
Ian Lance Taylor [Fri, 7 May 2010 05:07:03 +0000 (22:07 -0700)]
Save the scheduling state even predawn.

This permits cgo callbacks to work when run in init code.
Otherwise cgocallback switches to the wrong stack address.

R=rsc
CC=golang-dev
https://golang.org/cl/1123043

15 years agofix build (typo in arith_386.s)
Robert Griesemer [Fri, 7 May 2010 02:16:26 +0000 (19:16 -0700)]
fix build (typo in arith_386.s)

R=rsc
CC=golang-dev
https://golang.org/cl/1139042

15 years agobig: implemented overlap-tolerant shifts in assembly
Robert Griesemer [Fri, 7 May 2010 01:20:01 +0000 (18:20 -0700)]
big: implemented overlap-tolerant shifts in assembly

- no need to make copies in cases of aliases
- removed deprecated internal shift functions
- minor unrelated simplifications

This change improves pidigits -s -n10000 by almost 20%:

user 0m6.156s (old)
user 0m4.999s (new)

(pidigits -s -n20000 goes from ~25s to ~19s)

R=rsc
CC=golang-dev
https://golang.org/cl/1149041

15 years agocodelab/wiki: fix typo in demo URL
Andrew Gerrand [Fri, 7 May 2010 00:16:16 +0000 (10:16 +1000)]
codelab/wiki: fix typo in demo URL

R=r
CC=golang-dev
https://golang.org/cl/1148041

15 years agoruntime.GOMAXPROCS: hack it to have it return the old value.
Rob Pike [Thu, 6 May 2010 18:50:47 +0000 (11:50 -0700)]
runtime.GOMAXPROCS: hack it to have it return the old value.

R=rsc
CC=golang-dev
https://golang.org/cl/1140041

15 years agogob: add test for indirect maps, slices, arrays.
Rob Pike [Thu, 6 May 2010 17:45:18 +0000 (10:45 -0700)]
gob: add test for indirect maps, slices, arrays.
fix a bug in the handling of indirect maps.

R=rsc
CC=golang-dev
https://golang.org/cl/1132042

15 years agogc: distinguish array, slice literal in error messages
Russ Cox [Thu, 6 May 2010 16:34:12 +0000 (09:34 -0700)]
gc: distinguish array, slice literal in error messages

R=ken2
CC=golang-dev
https://golang.org/cl/1138041

15 years agoMake exp/draw/x11 respect $XAUTHORITY.
Nigel Tao [Thu, 6 May 2010 08:41:42 +0000 (18:41 +1000)]
Make exp/draw/x11 respect $XAUTHORITY.

R=rsc, cw, nigeltao_golang
CC=golang-dev
https://golang.org/cl/1134041

15 years agogob: add support for maps.
Rob Pike [Wed, 5 May 2010 23:46:39 +0000 (16:46 -0700)]
gob: add support for maps.
Because maps are mostly a hidden type, they must be
implemented using reflection values and will not be as
efficient as arrays and slices.

R=rsc
CC=golang-dev
https://golang.org/cl/1127041

15 years agopkg/Makefile: add netchan to standard package list
Rob Pike [Wed, 5 May 2010 22:17:26 +0000 (15:17 -0700)]
pkg/Makefile: add netchan to standard package list

R=golang-dev
CC=golang-dev
https://golang.org/cl/1121041

15 years agoCONTRIBUTORS: add Brad Fitzpatrick (Google Inc)
Russ Cox [Wed, 5 May 2010 19:49:59 +0000 (12:49 -0700)]
CONTRIBUTORS: add Brad Fitzpatrick (Google Inc)

R=r, bradfitzpatrick
CC=golang-dev
https://golang.org/cl/1118041

15 years agoConversion from loop to copy().
Kyle Consalus [Wed, 5 May 2010 16:57:53 +0000 (09:57 -0700)]
Conversion from loop to copy().

R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/1072041

15 years agoFix a typo in net/unixsock
Conrad Meyer [Wed, 5 May 2010 16:55:11 +0000 (09:55 -0700)]
Fix a typo in net/unixsock

R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/1113041

15 years agorelease.2010-05-04 tags
Andrew Gerrand [Wed, 5 May 2010 02:13:50 +0000 (12:13 +1000)]
release.2010-05-04 tags

R=rsc
CC=golang-dev
https://golang.org/cl/1112041

15 years agorelease.2010-05-04 weekly.2010-05-04
Andrew Gerrand [Wed, 5 May 2010 02:12:04 +0000 (12:12 +1000)]
release.2010-05-04

R=r, rsc
CC=golang-dev
https://golang.org/cl/1094043

15 years agogo spec: clarification of make arguments,
Robert Griesemer [Wed, 5 May 2010 00:31:40 +0000 (17:31 -0700)]
go spec: clarification of make arguments,
specification of runtime exceptions for
make and division by zero

R=r, rsc, ken2, iant
CC=golang-dev
https://golang.org/cl/1081041

15 years agoallow data statements for simple
Ken Thompson [Tue, 4 May 2010 05:51:30 +0000 (22:51 -0700)]
allow data statements for simple
external variable assignements.

R=rsc
CC=golang-dev
https://golang.org/cl/1094041

15 years agobig: completed set of Int division routines & cleanups
Robert Griesemer [Tue, 4 May 2010 01:48:05 +0000 (18:48 -0700)]
big: completed set of Int division routines & cleanups

- renamed Len -> BitLen, simplified implementation
- renamed old Div, Mod, DivMod -> Que, Rem, QuoRem
- implemented Div, Mod, DivMod (Euclidian definition, more
  useful in a mathematical context)
- fixed a bug in Exp (-0 was possible)
- added extra tests to check normalized results everywhere
- uniformly set Int.neg flag at the end of computations
- minor cosmetic cleanups
- ran all tests

R=rsc
CC=golang-dev
https://golang.org/cl/1091041

15 years agogc: bug264
Russ Cox [Tue, 4 May 2010 00:51:48 +0000 (17:51 -0700)]
gc: bug264

Fixes #692.

R=ken2
CC=golang-dev
https://golang.org/cl/1092041

15 years agotest/bench: import new fasta C reference, update Go, optimizations
Russ Cox [Tue, 4 May 2010 00:47:59 +0000 (17:47 -0700)]
test/bench: import new fasta C reference, update Go, optimizations

OLD fasta -n 25000000
gcc -O2 fasta.c 7.59u 0.06s 7.74r
gc fasta 9.54u 0.15s 9.84r
gc_B fasta 9.48u 0.10s 9.62r

NEW fasta -n 25000000
gcc -O2 fasta.c 2.59u 0.02s 2.66r
gc fasta 3.00u 0.03s 3.09r
gc_B fasta 2.72u 0.03s 2.81r

R=r
CC=golang-dev
https://golang.org/cl/1054041

15 years agoruntime, strconv: tiny cleanups
Russ Cox [Tue, 4 May 2010 00:47:40 +0000 (17:47 -0700)]
runtime, strconv: tiny cleanups

R=r
CC=golang-dev
https://golang.org/cl/1081042

15 years agotest: test of static initialization (fails)
Russ Cox [Tue, 4 May 2010 00:21:49 +0000 (17:21 -0700)]
test: test of static initialization (fails)

R=ken2
CC=golang-dev
https://golang.org/cl/1090041

15 years agogc: bug267
Russ Cox [Mon, 3 May 2010 22:29:59 +0000 (15:29 -0700)]
gc: bug267

R=ken2
CC=golang-dev
https://golang.org/cl/1067042

15 years agogc: error for nested functions, one semicolon problem
Russ Cox [Mon, 3 May 2010 22:02:32 +0000 (15:02 -0700)]
gc: error for nested functions, one semicolon problem

R=ken2
CC=golang-dev
https://golang.org/cl/1046042

15 years agobig: fix memory corruption in nat.shr
Russ Cox [Mon, 3 May 2010 21:28:45 +0000 (14:28 -0700)]
big: fix memory corruption in nat.shr

R=gri
CC=golang-dev
https://golang.org/cl/1084041

15 years agoruntime/arm: fix build
Russ Cox [Mon, 3 May 2010 20:24:39 +0000 (13:24 -0700)]
runtime/arm: fix build

Import _mulv from Inferno again, change R9 to R2.
Not sure what the other differences were for, but
they weren't working.

TBR=kaib
CC=golang-dev
https://golang.org/cl/1079041

15 years agotest: fix run-arm to count bugs correctly
Russ Cox [Mon, 3 May 2010 20:24:26 +0000 (13:24 -0700)]
test: fix run-arm to count bugs correctly

TBR=kaib
CC=golang-dev
https://golang.org/cl/1080041

15 years agobig: Add bitwise methods for Int
Evan Shaw [Mon, 3 May 2010 18:20:52 +0000 (11:20 -0700)]
big: Add bitwise methods for Int

R=gri
CC=golang-dev
https://golang.org/cl/987041

15 years agonacl: another attempt at fixing build
Russ Cox [Mon, 3 May 2010 18:12:54 +0000 (11:12 -0700)]
nacl: another attempt at fixing build

TBR=r
CC=golang-dev
https://golang.org/cl/1077041

15 years agosyscall: fix arm build (fix bugs in generator, to add O_LARGEFILE)
Russ Cox [Mon, 3 May 2010 18:11:01 +0000 (11:11 -0700)]
syscall: fix arm build (fix bugs in generator, to add O_LARGEFILE)

R=r
CC=golang-dev
https://golang.org/cl/1021043

15 years agoAdd _cgo_export.[ch] targets so that make knows how they are
Ian Lance Taylor [Mon, 3 May 2010 18:07:22 +0000 (11:07 -0700)]
Add _cgo_export.[ch] targets so that make knows how they are
built.  Note that they are only built if a //export comment
appears, so other targets should only use them if there is
such a comment.

Fixes #723.

R=rsc
CC=golang-dev
https://golang.org/cl/1073041

15 years agobytes: Change IndexAny to look for UTF-8 encoded characters.
Rob Pike [Mon, 3 May 2010 17:59:00 +0000 (10:59 -0700)]
bytes: Change IndexAny to look for UTF-8 encoded characters.
Also improve the implementations of Equals and Compare.

R=rsc
CC=golang-dev
https://golang.org/cl/969047

15 years agodashboard: fix benchmark json output
Andrew Gerrand [Mon, 3 May 2010 08:35:32 +0000 (18:35 +1000)]
dashboard: fix benchmark json output

Fixes #722.

R=rsc
CC=golang-dev
https://golang.org/cl/1065041

15 years agoruntime: update godefs usage comment for GOARCH=386 GOOS={darwin,freebsd}
Giles Lean [Mon, 3 May 2010 08:26:39 +0000 (01:26 -0700)]
runtime: update godefs usage comment for GOARCH=386 GOOS={darwin,freebsd}

When trying to regenerate src/pkg/runtime/darwin/386/defs.h
on a 64 bit capable Snow Leopard (OS X 10.6.3) system I
needed to add -f -m32 to godefs, as this OS and hardware
combination defaults to 64 bit compilation.

For safety, make the same change to the 32 bit FreeBSD
instructions in .../freebsd/defs.c.  (Tested OK and no
problems introduced.)

R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/1052042

15 years agofix nacl build
Russ Cox [Mon, 3 May 2010 07:04:48 +0000 (00:04 -0700)]
fix nacl build

TBR=r
CC=golang-dev
https://golang.org/cl/1063042

15 years agomath: fix typo in Cbrt description
Charles L. Dorian [Mon, 3 May 2010 06:33:08 +0000 (23:33 -0700)]
math: fix typo in Cbrt description

R=rsc
CC=golang-dev
https://golang.org/cl/979043

15 years agocodelab/wiki: switch edit/view, as they were backwards
Andrew Gerrand [Mon, 3 May 2010 02:09:44 +0000 (12:09 +1000)]
codelab/wiki: switch edit/view, as they were backwards

Fixes #757.

R=rsc
CC=golang-dev
https://golang.org/cl/1064041

15 years agobig: cleanup and removal of redundant functionality
Robert Griesemer [Sat, 1 May 2010 22:11:27 +0000 (15:11 -0700)]
big: cleanup and removal of redundant functionality

R=rsc
CC=golang-dev
https://golang.org/cl/1048041

15 years agogc: be pickier about slice, chan, array, and map sizes
Russ Cox [Sat, 1 May 2010 20:15:42 +0000 (13:15 -0700)]
gc: be pickier about slice, chan, array, and map sizes

Fixes #589.

R=ken2
CC=golang-dev
https://golang.org/cl/1032044

15 years agogmp: fix bug in SetString
Russ Cox [Sat, 1 May 2010 20:10:01 +0000 (13:10 -0700)]
gmp: fix bug in SetString

R=adg
CC=golang-dev
https://golang.org/cl/1004045

15 years agovector: use correct capacity in call to make
Russ Cox [Sat, 1 May 2010 20:00:01 +0000 (13:00 -0700)]
vector: use correct capacity in call to make

R=gri, r, bflm
CC=golang-dev
https://golang.org/cl/1032043

15 years agobig: use fast shift routines
Robert Griesemer [Sat, 1 May 2010 04:25:48 +0000 (21:25 -0700)]
big: use fast shift routines

- fixed a couple of bugs in the process
  (shift right was incorrect for negative numbers)
- added more tests and made some tests more robust
- changed pidigits back to using shifts to multiply
  by 2 instead of add

  This improves pidigit -s -n 10000 by approx. 5%:

  user 0m6.496s (old)
  user 0m6.156s (new)

R=rsc
CC=golang-dev
https://golang.org/cl/963044

15 years agobig/arith: assembly routines for 386 long shifts (2nd round)
Robert Griesemer [Fri, 30 Apr 2010 21:41:04 +0000 (14:41 -0700)]
big/arith: assembly routines for 386 long shifts (2nd round)

R=rsc
CC=golang-dev
https://golang.org/cl/986044

15 years ago8g: bug272
Russ Cox [Fri, 30 Apr 2010 21:04:34 +0000 (14:04 -0700)]
8g: bug272

Fixes #589.

R=ken2
CC=golang-dev
https://golang.org/cl/1043042

15 years agogc: bug271
Russ Cox [Fri, 30 Apr 2010 20:27:08 +0000 (13:27 -0700)]
gc: bug271

Fixes #662.

R=ken2
CC=golang-dev
https://golang.org/cl/978043

15 years agogc: bug270
Russ Cox [Fri, 30 Apr 2010 20:04:16 +0000 (13:04 -0700)]
gc: bug270

Fixes #746.

R=ken2
CC=golang-dev
https://golang.org/cl/1040042

15 years ago8l: fix absolute path detection on Windows
Russ Cox [Fri, 30 Apr 2010 19:48:03 +0000 (12:48 -0700)]
8l: fix absolute path detection on Windows

Fixes #755.

R=ken2
CC=golang-dev
https://golang.org/cl/965047

15 years agosyscall: handle EOF on pipe - special case on Windows
Alex Brainman [Fri, 30 Apr 2010 19:46:46 +0000 (12:46 -0700)]
syscall: handle EOF on pipe - special case on Windows

R=rsc
CC=golang-dev
https://golang.org/cl/962046

15 years agofix build
Robert Griesemer [Fri, 30 Apr 2010 19:01:15 +0000 (12:01 -0700)]
fix build

R=rsc
CC=golang-dev
https://golang.org/cl/1044041

15 years agobig: improved computation of "karatsuba length" for faster multiplies
Robert Griesemer [Fri, 30 Apr 2010 18:54:27 +0000 (11:54 -0700)]
big: improved computation of "karatsuba length" for faster multiplies

This results in an improvement of > 35% for the existing Mul benchmark
using the same karatsuba threshold, and an improvement of > 50% with
a slightly higher threshold (32 instead of 30):

big.BenchmarkMul           500    6731846 ns/op (old alg.)
big.BenchmarkMul    500    4351122 ns/op (new alg.)
big.BenchmarkMul           500    3133782 ns/op (new alg., new theshold)

Also:
- tweaked calibrate.go, use same benchmark as for Mul benchmark

R=rsc
CC=golang-dev
https://golang.org/cl/1037041

15 years agobig: assembly routines for 386 long shifts
Robert Griesemer [Fri, 30 Apr 2010 18:53:37 +0000 (11:53 -0700)]
big: assembly routines for 386 long shifts

R=rsc
CC=golang-dev
https://golang.org/cl/974043

15 years agobig: implemented core shift routines in arith.go and
Robert Griesemer [Fri, 30 Apr 2010 16:29:11 +0000 (09:29 -0700)]
big: implemented core shift routines in arith.go and
     provide assembly versions (for x86-64 for now)

(Not yet used - waiting for previous CL to clear)

R=rsc
CC=golang-dev
https://golang.org/cl/1040041

15 years agoAdd EWOULDBLOCK to sycall_nacl.go.
Nigel Tao [Fri, 30 Apr 2010 08:45:04 +0000 (18:45 +1000)]
Add EWOULDBLOCK to sycall_nacl.go.

R=rsc
CC=go-dev, golang-dev
https://golang.org/cl/1006045

15 years agorename GOOS=mingw to GOOS=windows
Alex Brainman [Fri, 30 Apr 2010 06:45:14 +0000 (23:45 -0700)]
rename GOOS=mingw to GOOS=windows

R=rsc, Joe Poirier
CC=golang-dev
https://golang.org/cl/1015043

15 years agosyscall: force O_LARGEFILE in Linux open system call
Russ Cox [Fri, 30 Apr 2010 06:34:06 +0000 (23:34 -0700)]
syscall: force O_LARGEFILE in Linux open system call

Fixes #717.

R=adg, PeterGo
CC=golang-dev
https://golang.org/cl/1032041

15 years agosyscall: mingw Sleep
Joe Poirier [Fri, 30 Apr 2010 06:08:22 +0000 (23:08 -0700)]
syscall: mingw Sleep

R=rsc, brainman
CC=golang-dev
https://golang.org/cl/961047

15 years agogc: never include ( ) on singleton func return type
Russ Cox [Thu, 29 Apr 2010 23:07:14 +0000 (16:07 -0700)]
gc: never include ( ) on singleton func return type

Fixes #749.

R=ken2
CC=golang-dev
https://golang.org/cl/963043

15 years agogc: bug268
Russ Cox [Thu, 29 Apr 2010 22:52:27 +0000 (15:52 -0700)]
gc: bug268

Fixes #745.

R=ken2
CC=golang-dev
https://golang.org/cl/1008045

15 years agonet: use short variable declaration
Christopher Wedgwood [Thu, 29 Apr 2010 18:02:10 +0000 (11:02 -0700)]
net: use short variable declaration

R=rsc
CC=golang-dev
https://golang.org/cl/1019043

15 years agonet: parser should handle EOF without newline properly.
Christopher Wedgwood [Thu, 29 Apr 2010 18:01:21 +0000 (11:01 -0700)]
net: parser should handle EOF without newline properly.

Fixes #686.

R=rsc
CC=adg, golang-dev
https://golang.org/cl/979044

15 years agogo spec: fix iota description
Robert Griesemer [Thu, 29 Apr 2010 17:57:27 +0000 (10:57 -0700)]
go spec: fix iota description

R=r, rsc
CC=golang-dev
https://golang.org/cl/946046

15 years agocodelab/index.html: a few typos.
Andrey Mirtchovski [Thu, 29 Apr 2010 04:33:19 +0000 (14:33 +1000)]
codelab/index.html: a few typos.

R=adg
CC=golang-dev
https://golang.org/cl/993042