Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(499)

Issue 1288703002: [Courgette] Optimize QSufSort to speed up courgette-gen. (Closed)

Created:
5 years, 4 months ago by huangs
Modified:
5 years, 4 months ago
Reviewers:
Will Harris
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Courgette] Optimize QSufSort to speed up courgette-gen. We apply the following optimizations to QSufSort: - split()'s interface is changed to start/end instead of start/length, so many unnecessary adds are removed. - split()'s 3-way partition is now done in a single pass. - search()'s binary search is no longer recursive. Experiment (goo.gl/XboS1f) shows this leads to 35% speed up in qsufsort(), and 10% speed up in courgette-gen. search() was slightly (0.5%) slower up much, perhaps because tail recursion was compiler-optimized. However, the new code is cleaner and takes two fewer params. Committed: https://crrev.com/21773eb242e96704d0ec486d1adf95f2da5d55f7 Cr-Commit-Position: refs/heads/master@{#344353}

Patch Set 1 #

Patch Set 2 : Make search() non-recursive. #

Patch Set 3 : Fix unittests. #

Patch Set 4 : Fix comments and spacing. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+94 lines, -78 lines) Patch
M courgette/third_party/bsdiff_create.cc View 1 2 chunks +3 lines, -1 line 0 comments Download
M courgette/third_party/qsufsort.h View 1 2 3 4 chunks +90 lines, -76 lines 0 comments Download
M courgette/third_party/qsufsort_unittest.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 13 (3 generated)
huangs
Here are the optimization that http://crrev.com/1272453003/ referred to. I'm also running better benchmarks to measure ...
5 years, 4 months ago (2015-08-12 19:44:20 UTC) #2
Will Harris
On 2015/08/12 19:44:20, huangs wrote: > Here are the optimization that http://crrev.com/1272453003/ referred to. I'm ...
5 years, 4 months ago (2015-08-12 23:33:55 UTC) #3
huangs
Qsufsort does not appear to be under active development. This CL implements some low-hanging fruit ...
5 years, 4 months ago (2015-08-13 01:06:48 UTC) #4
huangs
Benchmark data: goo.gl/XboS1f . So we have 35% speed-up in qsufsort and 10% for courgette-gen. ...
5 years, 4 months ago (2015-08-13 17:21:55 UTC) #5
Will Harris
we chatted about this in person and huangs ran through the algorithm. lgtm and thanks ...
5 years, 4 months ago (2015-08-19 20:55:09 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1288703002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1288703002/60001
5 years, 4 months ago (2015-08-19 21:43:26 UTC) #9
commit-bot: I haz the power
Committed patchset #4 (id:60001)
5 years, 4 months ago (2015-08-19 22:34:05 UTC) #10
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/21773eb242e96704d0ec486d1adf95f2da5d55f7 Cr-Commit-Position: refs/heads/master@{#344353}
5 years, 4 months ago (2015-08-19 22:34:42 UTC) #11
zsnmhd
On 2015/08/19 22:34:42, commit-bot: I haz the power wrote: > Patchset 4 (id:??) landed as ...
5 years, 4 months ago (2015-08-20 12:34:19 UTC) #12
huangs
5 years, 4 months ago (2015-08-20 17:26:58 UTC) #13
Message was sent while issue was closed.
Download the Chrome repository and "ninja -C out/Release courgette" builds
Courgette. I haven't tried building this without Chrome. Courgette directly
depends on //base and //third_party/lzma_sdk, so in principle if you download
just these (and transitive deps) you should be able to build "stand alone"
Courgette. However, you might encounter problem trying to generate the build
files ("gclient runhooks"), so some more tweaking might be required.

Powered by Google App Engine
This is Rietveld 408576698