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

Issue 1914303002: [Courgette] Fix sorting in QSufSort's split(). (Closed)

Created:
4 years, 8 months ago by huangs
Modified:
4 years, 7 months ago
CC:
chromium-reviews, deymo, chrisha, Sigurður Ásgeirsson
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Courgette] Fix sorting in QSufSort's split(). BSDiff implements Quicksort in its adaptation of QSufSort. To improve robustness, we reverted the simplified pivot selection algorithm to the original one due to Bentley & McIlroy used in QSufSort: http://www.larsson.dogma.net/qsufsort.c Also reverting split() selection sort threshold from 6 back to 16. Resulting Courgette-gen and QSufSort has same performance as before (preliminary: ~1% faster). BUG=605565 Committed: https://crrev.com/a937d0438bab5dc41c6cfc571a4b16c0d68a6312 Cr-Commit-Position: refs/heads/master@{#390134}

Patch Set 1 #

Patch Set 2 : Redo: Improve pivoting to match original QSufSort's. #

Total comments: 1

Patch Set 3 : Update comments; put helper into namespace { }. #

Patch Set 4 : Comment nit. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+31 lines, -4 lines) Patch
M courgette/third_party/qsufsort.h View 1 2 3 3 chunks +31 lines, -4 lines 0 comments Download

Messages

Total messages: 27 (13 generated)
huangs
This fixes the bug, but makes Courgette-gen 8% slower! If this is fine, please consider ...
4 years, 8 months ago (2016-04-26 23:02:27 UTC) #2
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1914303002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1914303002/1
4 years, 8 months ago (2016-04-26 23:02:46 UTC) #4
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: cast_shell_android on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/cast_shell_android/builds/56851)
4 years, 8 months ago (2016-04-26 23:10:51 UTC) #6
huangs
Using std::sort() followed by I[] V[] resolution was a neat idea, but it was more ...
4 years, 7 months ago (2016-04-27 15:29:04 UTC) #8
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1914303002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1914303002/20001
4 years, 7 months ago (2016-04-27 15:29:40 UTC) #10
huangs
https://codereview.chromium.org/1914303002/diff/20001/courgette/third_party/qsufsort.h File courgette/third_party/qsufsort.h (right): https://codereview.chromium.org/1914303002/diff/20001/courgette/third_party/qsufsort.h#newcode50 courgette/third_party/qsufsort.h:50: if (end - start < 16) { Changing this ...
4 years, 7 months ago (2016-04-27 15:30:49 UTC) #11
huangs
Ran the baseline again for better comparison: Only saw ~1% speed up. Well the point ...
4 years, 7 months ago (2016-04-27 15:47:29 UTC) #13
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 7 months ago (2016-04-27 16:22:38 UTC) #15
Will Harris
lgtm % can you link where you got this code from in the CL? Also ...
4 years, 7 months ago (2016-04-27 17:02:30 UTC) #16
huangs
This is reverting the simplification made by BSDiff to choose middle element as pivot. Patch ...
4 years, 7 months ago (2016-04-27 17:13:15 UTC) #18
huangs
But I suppose changing selection sort threshold from 6 back to 16 is a partial ...
4 years, 7 months ago (2016-04-27 17:24:07 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1914303002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1914303002/60001
4 years, 7 months ago (2016-04-27 17:33:56 UTC) #23
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 7 months ago (2016-04-27 18:32:34 UTC) #25
commit-bot: I haz the power
4 years, 7 months ago (2016-04-30 17:11:28 UTC) #26
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/a937d0438bab5dc41c6cfc571a4b16c0d68a6312
Cr-Commit-Position: refs/heads/master@{#390134}

Powered by Google App Engine
This is Rietveld 408576698