Codebase list golang-github-klauspost-pgzip / e6c5279
New upstream snapshot. Debian Janitor 1 year, 3 months ago
6 changed file(s) with 31 addition(s) and 32 deletion(s). Raw diff Collapse all Expand all
+0
-24
.gitignore less more
0 # Compiled Object files, Static and Dynamic libs (Shared Objects)
1 *.o
2 *.a
3 *.so
4
5 # Folders
6 _obj
7 _test
8
9 # Architecture specific extensions/prefixes
10 *.[568vq]
11 [568vq].out
12
13 *.cgo1.go
14 *.cgo2.c
15 _cgo_defun.c
16 _cgo_gotypes.go
17 _cgo_export.*
18
19 _testmain.go
20
21 *.exe
22 *.test
23 *.prof
0
1 arch:
2 - amd64
3 - ppc64le
04 language: go
15
26 os:
0 MIT License
0 The MIT License (MIT)
11
22 Copyright (c) 2014 Klaus Post
33
1818 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
1919 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2020 SOFTWARE.
21
103103
104104 Compressor | MB/sec | speedup | size | size overhead (lower=better)
105105 ------------|----------|---------|------|---------
106 [gzip](http://golang.org/pkg/compress/gzip) (golang) | 15.44MB/s (1 thread) | 1.0x | 4781329307 | 0%
107 [gzip](http://github.com/klauspost/compress/gzip) (klauspost) | 135.04MB/s (1 thread) | 8.74x | 4894858258 | +2.37%
108 [pgzip](https://github.com/klauspost/pgzip) (klauspost) | 1573.23MB/s| 101.9x | 4902285651 | +2.53%
109 [bgzf](https://godoc.org/github.com/biogo/hts/bgzf) (biogo) | 361.40MB/s | 23.4x | 4869686090 | +1.85%
110 [pargzip](https://godoc.org/github.com/golang/build/pargzip) (builder) | 306.01MB/s | 19.8x | 4786890417 | +0.12%
106 [gzip](http://golang.org/pkg/compress/gzip) (golang) | 16.91MB/s (1 thread) | 1.0x | 4781329307 | 0%
107 [gzip](http://github.com/klauspost/compress/gzip) (klauspost) | 127.10MB/s (1 thread) | 7.52x | 4885366806 | +2.17%
108 [pgzip](https://github.com/klauspost/pgzip) (klauspost) | 2085.35MB/s| 123.34x | 4886132566 | +2.19%
109 [pargzip](https://godoc.org/github.com/golang/build/pargzip) (builder) | 334.04MB/s | 19.76x | 4786890417 | +0.12%
111110
112 pgzip also contains a [linear time compression](https://github.com/klauspost/compress#linear-time-compression-huffman-only) mode, that will allow compression at ~250MB per core per second, independent of the content.
111 pgzip also contains a [huffman only compression](https://github.com/klauspost/compress#linear-time-compression-huffman-only) mode, that will allow compression at ~450MB per core per second, largely independent of the content.
113112
114113 See the [complete sheet](https://docs.google.com/spreadsheets/d/1nuNE2nPfuINCZJRMt6wFWhKpToF95I47XjSsc-1rbPQ/edit?usp=sharing) for different content types and compression settings.
115114
122121 Decompressor | Time | Speedup
123122 -------------|------|--------
124123 [gzip](http://golang.org/pkg/compress/gzip) (golang) | 1m28.85s | 0%
125 [pgzip](https://github.com/klauspost/pgzip) (golang) | 43.48s | 104%
124 [pgzip](https://github.com/klauspost/pgzip) (klauspost) | 43.48s | 104%
126125
127126 But wait, since gzip decompression is inherently singlethreaded (aside from CRC calculation) how can it be more than 100% faster? Because pgzip due to its design also acts as a buffer. When using unbuffered gzip, you are also waiting for io when you are decompressing. If the gzip decoder can keep up, it will always have data ready for your reader, and you will not be waiting for input to the gzip decompressor to complete.
128127
0 golang-github-klauspost-pgzip (1.2.5+git20220930.1.17e8dac-1) UNRELEASED; urgency=low
1
2 * New upstream snapshot.
3
4 -- Debian Janitor <janitor@jelmer.uk> Mon, 30 Jan 2023 15:14:33 -0000
5
06 golang-github-klauspost-pgzip (1.2.5-2) unstable; urgency=medium
17
28 [ Debian Janitor ]
512512
513513 func (z *Reader) WriteTo(w io.Writer) (n int64, err error) {
514514 total := int64(0)
515 avail := z.current[z.roff:]
516 if len(avail) != 0 {
517 n, err := w.Write(avail)
518 if n != len(avail) {
519 return total, io.ErrShortWrite
520 }
521 total += int64(n)
522 if err != nil {
523 return total, err
524 }
525 z.blockPool <- z.current
526 z.current = nil
527 }
515528 for {
516529 if z.err != nil {
517530 return total, z.err