<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/go-git.git/src/compress, branch dev.inline</title>
<subtitle>github.com: golang/go
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/'/>
<entry>
<title>compress/flate: add examples</title>
<updated>2016-11-12T18:42:35+00:00</updated>
<author>
<name>Joe Tsai</name>
<email>joetsai@digital-static.net</email>
</author>
<published>2016-09-22T20:33:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=091ba60bd87bf8b40a24196f31b5f3c18c2f2dc4'/>
<id>091ba60bd87bf8b40a24196f31b5f3c18c2f2dc4</id>
<content type='text'>
Updates #16360

Change-Id: I66ff23e0501363f58fe891d5e95806422071f93b
Reviewed-on: https://go-review.googlesource.com/30162
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Updates #16360

Change-Id: I66ff23e0501363f58fe891d5e95806422071f93b
Reviewed-on: https://go-review.googlesource.com/30162
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>all: sprinkle t.Parallel on some slow tests</title>
<updated>2016-11-04T16:56:57+00:00</updated>
<author>
<name>Brad Fitzpatrick</name>
<email>bradfitz@golang.org</email>
</author>
<published>2016-11-04T05:28:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=23416315060bf7601e5779c3a6a2529d4d604584'/>
<id>23416315060bf7601e5779c3a6a2529d4d604584</id>
<content type='text'>
I used the slowtests.go tool as described in
https://golang.org/cl/32684 on packages that stood out.

go test -short std drops from ~56 to ~52 seconds.

This isn't a huge win, but it was mostly an exercise.

Updates #17751

Change-Id: I9f3402e36a038d71e662d06ce2c1d52f6c4b674d
Reviewed-on: https://go-review.googlesource.com/32751
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I used the slowtests.go tool as described in
https://golang.org/cl/32684 on packages that stood out.

go test -short std drops from ~56 to ~52 seconds.

This isn't a huge win, but it was mostly an exercise.

Updates #17751

Change-Id: I9f3402e36a038d71e662d06ce2c1d52f6c4b674d
Reviewed-on: https://go-review.googlesource.com/32751
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>compress/flate: tighten the BestSpeed max match offset bound.</title>
<updated>2016-10-30T22:52:14+00:00</updated>
<author>
<name>Nigel Tao</name>
<email>nigeltao@golang.org</email>
</author>
<published>2016-10-29T02:23:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=590fce48849cc7f81b890d6e9b6120fc6681e19a'/>
<id>590fce48849cc7f81b890d6e9b6120fc6681e19a</id>
<content type='text'>
Previously, we were off by one.

Also fix a comment typo.

Change-Id: Ib94d23acc56d5fccd44144f71655481f98803ac8
Reviewed-on: https://go-review.googlesource.com/32149
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
Run-TryBot: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously, we were off by one.

Also fix a comment typo.

Change-Id: Ib94d23acc56d5fccd44144f71655481f98803ac8
Reviewed-on: https://go-review.googlesource.com/32149
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
Run-TryBot: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>compress/gzip: only encode MTIME if it is valid</title>
<updated>2016-10-29T23:29:13+00:00</updated>
<author>
<name>Joe Tsai</name>
<email>joetsai@digital-static.net</email>
</author>
<published>2016-10-29T19:25:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=b4e714e59efd21f9140a3e8e2b0182c74bfde437'/>
<id>b4e714e59efd21f9140a3e8e2b0182c74bfde437</id>
<content type='text'>
The GZIP format records the ModTime as an uint32 counting seconds since
the Unix epoch. The zero value is explicitly defined in section 2.3.1
as meaning no timestamp is available.

Currently, the Writer always encodes the ModTime even if it is the zero
time.Time value, which causes the Writer to try and encode the value
-62135596800 into the uint32 MTIME field. This causes an overflow and
results in our GZIP files having MTIME fields indicating a date in 2042-07-13.

We alter the Writer to only encode ModTime if the value does not underflow
the MTIME field (i.e., it is newer than the Unix epoch). We do not attempt
to fix what happens when the timestamp overflows in the year 2106.

We alter the Reader to only decode ModTime if the value is non-zero.
There is no risk of overflowing time.Time when decoding.

Fixes #17663

Change-Id: Ie1b65770c6342cd7b14aeebe10e5a49e6c9eb730
Reviewed-on: https://go-review.googlesource.com/32325
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The GZIP format records the ModTime as an uint32 counting seconds since
the Unix epoch. The zero value is explicitly defined in section 2.3.1
as meaning no timestamp is available.

Currently, the Writer always encodes the ModTime even if it is the zero
time.Time value, which causes the Writer to try and encode the value
-62135596800 into the uint32 MTIME field. This causes an overflow and
results in our GZIP files having MTIME fields indicating a date in 2042-07-13.

We alter the Writer to only encode ModTime if the value does not underflow
the MTIME field (i.e., it is newer than the Unix epoch). We do not attempt
to fix what happens when the timestamp overflows in the year 2106.

We alter the Reader to only decode ModTime if the value is non-zero.
There is no risk of overflowing time.Time when decoding.

Fixes #17663

Change-Id: Ie1b65770c6342cd7b14aeebe10e5a49e6c9eb730
Reviewed-on: https://go-review.googlesource.com/32325
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>compress/flate: make compression level 0 consistent</title>
<updated>2016-10-27T00:58:30+00:00</updated>
<author>
<name>Klaus Post</name>
<email>klauspost@gmail.com</email>
</author>
<published>2016-10-15T12:37:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=461adfd817eea64ee6b96f5711a48854bcda6241'/>
<id>461adfd817eea64ee6b96f5711a48854bcda6241</id>
<content type='text'>
Tests for determinism was not working as intended since io.Copybuffer
uses the io.WriterTo if available.

This exposed that level 0 (no compression) changed output
based on the number of writes and buffers given to the
writer.

Previously, Write would emit a new raw block (BTYPE=00) for
every non-empty call to Write.

This CL fixes it such that a raw block is only emitted upon
the following conditions:
 	* A full window is obtained (every 65535 bytes)
 	* Flush is called
 	* Close is called

Change-Id: I807f866d97e2db7820f11febab30a96266a6cbf1
Reviewed-on: https://go-review.googlesource.com/31174
Run-TryBot: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Tests for determinism was not working as intended since io.Copybuffer
uses the io.WriterTo if available.

This exposed that level 0 (no compression) changed output
based on the number of writes and buffers given to the
writer.

Previously, Write would emit a new raw block (BTYPE=00) for
every non-empty call to Write.

This CL fixes it such that a raw block is only emitted upon
the following conditions:
 	* A full window is obtained (every 65535 bytes)
 	* Flush is called
 	* Close is called

Change-Id: I807f866d97e2db7820f11febab30a96266a6cbf1
Reviewed-on: https://go-review.googlesource.com/31174
Run-TryBot: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>compress/flate: level 1 (best speed) match across blocks</title>
<updated>2016-10-27T00:50:06+00:00</updated>
<author>
<name>Klaus Post</name>
<email>klauspost@gmail.com</email>
</author>
<published>2016-10-22T16:50:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=2e196b15b94e48009369aae25299a59cbc7d45f4'/>
<id>2e196b15b94e48009369aae25299a59cbc7d45f4</id>
<content type='text'>
This change makes deflate level 1 (best speed) match across
block boundaries. This comes at a small speed penalty,
but improves compression on almost all output.

Sample numbers on various content types:

enwik9:            391052014 -&gt;  382578469 bytes, 77.59 -&gt; 74.28 MB/s
adresser.001:       57269799 -&gt;   47756095 bytes, 287.84 -&gt; 357.86 MB/s
10gb:             5233055166 -&gt; 5198328382 bytes, 105.85 -&gt; 96.99 MB/s
rawstudio-mint14: 3972329211 -&gt; 3927423364 bytes, 100.07 -&gt; 94.22 MB/s
sites:             165556800 -&gt;  163178702 bytes, 72.31 -&gt; 70.15 MB/s
objectfiles:       115962472 -&gt;  111649524 bytes, 132.60 -&gt; 128.05 MB/s
sharnd.out:        200015283 -&gt;  200015283 bytes, 221.50 -&gt; 218.83 MB/s

Change-Id: I62a139e5c06976e803439a4268acede5139b8cfc
Reviewed-on: https://go-review.googlesource.com/31640
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
Reviewed-by: Nigel Tao &lt;nigeltao@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This change makes deflate level 1 (best speed) match across
block boundaries. This comes at a small speed penalty,
but improves compression on almost all output.

Sample numbers on various content types:

enwik9:            391052014 -&gt;  382578469 bytes, 77.59 -&gt; 74.28 MB/s
adresser.001:       57269799 -&gt;   47756095 bytes, 287.84 -&gt; 357.86 MB/s
10gb:             5233055166 -&gt; 5198328382 bytes, 105.85 -&gt; 96.99 MB/s
rawstudio-mint14: 3972329211 -&gt; 3927423364 bytes, 100.07 -&gt; 94.22 MB/s
sites:             165556800 -&gt;  163178702 bytes, 72.31 -&gt; 70.15 MB/s
objectfiles:       115962472 -&gt;  111649524 bytes, 132.60 -&gt; 128.05 MB/s
sharnd.out:        200015283 -&gt;  200015283 bytes, 221.50 -&gt; 218.83 MB/s

Change-Id: I62a139e5c06976e803439a4268acede5139b8cfc
Reviewed-on: https://go-review.googlesource.com/31640
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
Reviewed-by: Nigel Tao &lt;nigeltao@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>all: minor vet fixes</title>
<updated>2016-10-24T17:27:37+00:00</updated>
<author>
<name>Josh Bleecher Snyder</name>
<email>josharian@gmail.com</email>
</author>
<published>2016-10-23T21:10:11+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=accf5cc3862830bb8bb54af31aa1861e6a2b8481'/>
<id>accf5cc3862830bb8bb54af31aa1861e6a2b8481</id>
<content type='text'>
Change-Id: I22f0f3e792052762499f632571155768b4052bc9
Reviewed-on: https://go-review.googlesource.com/31759
Run-TryBot: Josh Bleecher Snyder &lt;josharian@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change-Id: I22f0f3e792052762499f632571155768b4052bc9
Reviewed-on: https://go-review.googlesource.com/31759
Run-TryBot: Josh Bleecher Snyder &lt;josharian@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>compress/gzip, compress/zlib: add HuffmanOnly as compression levels.</title>
<updated>2016-10-20T23:11:05+00:00</updated>
<author>
<name>Klaus Post</name>
<email>klauspost@gmail.com</email>
</author>
<published>2016-10-16T20:18:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=c9517b1ffe7c99a3fd2a748fab51645bd674ad75'/>
<id>c9517b1ffe7c99a3fd2a748fab51645bd674ad75</id>
<content type='text'>
This exposes HuffmanOnly in zlib and gzip packages, which is currently
unavailable.

Change-Id: If5d103bbc8b5fce2f5d740fd103a235c5d1ed7cd
Reviewed-on: https://go-review.googlesource.com/31186
Reviewed-by: Nigel Tao &lt;nigeltao@golang.org&gt;
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
Run-TryBot: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This exposes HuffmanOnly in zlib and gzip packages, which is currently
unavailable.

Change-Id: If5d103bbc8b5fce2f5d740fd103a235c5d1ed7cd
Reviewed-on: https://go-review.googlesource.com/31186
Reviewed-by: Nigel Tao &lt;nigeltao@golang.org&gt;
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
Run-TryBot: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>compress/flate: use correct table for size estimation</title>
<updated>2016-10-17T09:00:41+00:00</updated>
<author>
<name>Klaus Post</name>
<email>klauspost@gmail.com</email>
</author>
<published>2016-10-15T11:06:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=c1cd64d0ac2001ec8fe6f253e4e95561a444d533'/>
<id>c1cd64d0ac2001ec8fe6f253e4e95561a444d533</id>
<content type='text'>
The incorrect table was used for estimating output size.
This can give suboptimal selection of entropy encoder in rare cases.

Change-Id: I8b358200f2d1f9a3f9b79a44269d7be704e1d2d9
Reviewed-on: https://go-review.googlesource.com/31172
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The incorrect table was used for estimating output size.
This can give suboptimal selection of entropy encoder in rare cases.

Change-Id: I8b358200f2d1f9a3f9b79a44269d7be704e1d2d9
Reviewed-on: https://go-review.googlesource.com/31172
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>compress/gzip: document Reader.Read</title>
<updated>2016-10-09T00:22:59+00:00</updated>
<author>
<name>Emmanuel Odeke</name>
<email>emm.odeke@gmail.com</email>
</author>
<published>2016-10-08T04:27:32+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/go-git.git/commit/?id=56d35d42e188b8767665a368384e084da50ef634'/>
<id>56d35d42e188b8767665a368384e084da50ef634</id>
<content type='text'>
Fixes #17374.

Change-Id: Ic89c35aaa31f35a8a4e3ffa09f49b68f08127625
Reviewed-on: https://go-review.googlesource.com/30718
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes #17374.

Change-Id: Ic89c35aaa31f35a8a4e3ffa09f49b68f08127625
Reviewed-on: https://go-review.googlesource.com/30718
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Reviewed-by: Joe Tsai &lt;thebrokentoaster@gmail.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
