Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(137)

Issue 4433088: code review 4433088: jpeg: speed up RGBA encoding ~%50 (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years ago by bradfitz
Modified:
14 years ago
Reviewers:
CC:
r, r2, nigeltao, golang-dev
Visibility:
Public.

Description

jpeg: speed up RGBA encoding ~%50 Avoids image.At(), color.RGBA(), opposing 8 bit shifts, and min function calls in a loop. Not as pretty as before, but the pure version is still there to revert back to later if/when the compiler gets better. before (best of 5) jpeg.BenchmarkEncodeRGBOpaque 50 64781360 ns/op 18.97 MB/s after (best of 5) jpeg.BenchmarkEncodeRGBOpaque 50 42044300 ns/op 29.23 MB/s (benchmarked on an HP z600; 16 core Xeon E5520 @ 2.27Ghz)

Patch Set 1 #

Patch Set 2 : diff -r 304d7d2b1d6c https://go.googlecode.com/hg #

Patch Set 3 : diff -r 304d7d2b1d6c https://go.googlecode.com/hg #

Patch Set 4 : diff -r 66eb68cbd5c2 https://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+31 lines, -1 line) Patch
M src/pkg/image/jpeg/writer.go View 1 2 chunks +31 lines, -1 line 0 comments Download

Messages

Total messages: 5
bradfitz
Hello r (cc: golang-dev@googlegroups.com), I'd like you to review this change to https://go.googlecode.com/hg
14 years ago (2011-04-29 18:22:12 UTC) #1
r2
LGTM but nigeltao should probably take a look too
14 years ago (2011-04-29 18:27:20 UTC) #2
nigeltao
LGTM.
14 years ago (2011-05-02 08:58:00 UTC) #3
bradfitz
Hello r, r2, nigeltao (cc: golang-dev@googlegroups.com), I'd like you to review this change to https://go.googlecode.com/hg/
14 years ago (2011-05-02 14:26:35 UTC) #4
bradfitz
14 years ago (2011-05-02 14:26:52 UTC) #5
*** Submitted as http://code.google.com/p/go/source/detail?r=099dd59d3976 ***

jpeg: speed up RGBA encoding ~%50

Avoids image.At(), color.RGBA(), opposing 8 bit shifts,
and min function calls in a loop.  Not as pretty as before,
but the pure version is still there to revert back to
later if/when the compiler gets better.

before (best of 5)
jpeg.BenchmarkEncodeRGBOpaque   50   64781360 ns/op   18.97 MB/s

after (best of 5)
jpeg.BenchmarkEncodeRGBOpaque   50   42044300 ns/op   29.23 MB/s

(benchmarked on an HP z600; 16 core Xeon E5520 @ 2.27Ghz)

R=r, r2, nigeltao
CC=golang-dev
http://codereview.appspot.com/4433088
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b