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

Issue 17462005: IndexedDB: Replace transaction's AVLTree with std::map (Closed)

Created:
7 years, 6 months ago by jsbell
Modified:
7 years, 3 months ago
Reviewers:
ericu, dgrogan, alecflett
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam
Visibility:
Public.

Description

IndexedDB: Replace transaction's AVLTree with std::map When porting the transaction back-end from Blink we brought along an AVLTree implementation for the in-memory key/value store for transactions. Replace this with a std::map since it provides similar performance guarantees (red-black tree) and we like to delete code. TBR=jam@chromium.org R=alecflett@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=223493

Patch Set 1 #

Patch Set 2 : Remove unused code #

Patch Set 3 : Rebased; store node pointers in map to avoid copies #

Total comments: 13

Patch Set 4 : Use lower_bound, rename Tree to Data #

Patch Set 5 : Store key string in record so map keys can be StringPieces #

Patch Set 6 : Store key string in record so map keys can be StringPieces #

Patch Set 7 : Remove iterator validation support #

Unified diffs Side-by-side diffs Delta from patch set Stats (+200 lines, -1242 lines) Patch
D content/browser/indexed_db/leveldb/avltree.h View 1 chunk +0 lines, -977 lines 0 comments Download
D content/browser/indexed_db/leveldb/fixed_array.h View 1 chunk +0 lines, -63 lines 0 comments Download
M content/browser/indexed_db/leveldb/leveldb_database.h View 1 2 1 chunk +0 lines, -1 line 0 comments Download
M content/browser/indexed_db/leveldb/leveldb_transaction.h View 1 2 3 4 5 6 5 chunks +29 lines, -52 lines 0 comments Download
M content/browser/indexed_db/leveldb/leveldb_transaction.cc View 1 2 3 4 5 6 16 chunks +125 lines, -147 lines 0 comments Download
M content/browser/indexed_db/leveldb/leveldb_unittest.cc View 1 2 1 chunk +46 lines, -0 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 1 chunk +0 lines, -2 lines 0 comments Download

Messages

Total messages: 17 (0 generated)
jsbell
This is doing more data copying than before. Get perf numbers, compare, and optimize before ...
7 years, 6 months ago (2013-06-19 20:29:34 UTC) #1
jsbell
Just for kicks, this is what the patch would look like. Works and everything! However, ...
7 years, 6 months ago (2013-06-19 23:40:48 UTC) #2
jsbell
Performance runs on linux show this to be slightly slower across the board (just a ...
7 years, 5 months ago (2013-06-27 18:36:06 UTC) #3
jsbell
Dusted this off. It now stores node by pointer rather than by value to avoid ...
7 years, 4 months ago (2013-08-13 23:23:32 UTC) #4
jsbell
So far as I can tell, the performance difference here is in the noise. But ...
7 years, 4 months ago (2013-08-14 00:07:13 UTC) #5
jsbell
alecflett@, dgrogan@, ericu@ - any thoughts on whether or not this is worth pursuing?
7 years, 3 months ago (2013-09-10 00:20:11 UTC) #6
ericu
The code's not all that much smaller [the .cc file, anyway], but it is easier ...
7 years, 3 months ago (2013-09-10 01:00:40 UTC) #7
alecflett
seems like there are a few new copies going on here, are they avoidable? https://codereview.chromium.org/17462005/diff/15001/content/browser/indexed_db/leveldb/leveldb_transaction.cc ...
7 years, 3 months ago (2013-09-10 16:46:40 UTC) #8
jsbell
https://codereview.chromium.org/17462005/diff/15001/content/browser/indexed_db/leveldb/leveldb_transaction.cc File content/browser/indexed_db/leveldb/leveldb_transaction.cc (right): https://codereview.chromium.org/17462005/diff/15001/content/browser/indexed_db/leveldb/leveldb_transaction.cc#newcode70 content/browser/indexed_db/leveldb/leveldb_transaction.cc:70: std::string string_key(key.begin(), key.end() - key.begin()); On 2013/09/10 16:46:40, alecflett ...
7 years, 3 months ago (2013-09-10 17:00:06 UTC) #9
jsbell
https://codereview.chromium.org/17462005/diff/15001/content/browser/indexed_db/leveldb/leveldb_transaction.cc File content/browser/indexed_db/leveldb/leveldb_transaction.cc (right): https://codereview.chromium.org/17462005/diff/15001/content/browser/indexed_db/leveldb/leveldb_transaction.cc#newcode70 content/browser/indexed_db/leveldb/leveldb_transaction.cc:70: std::string string_key(key.begin(), key.end() - key.begin()); On 2013/09/10 17:00:06, jsbell ...
7 years, 3 months ago (2013-09-10 21:29:36 UTC) #10
jsbell
oops, forgot to say: alecflett@, ericu@ - PTAL again?
7 years, 3 months ago (2013-09-13 18:08:05 UTC) #11
alecflett
lgtm
7 years, 3 months ago (2013-09-13 20:22:07 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jsbell@chromium.org/17462005/36009
7 years, 3 months ago (2013-09-16 19:18:48 UTC) #13
commit-bot: I haz the power
Retried try job too often on chromium_presubmit for step(s) presubmit http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=chromium_presubmit&number=25707
7 years, 3 months ago (2013-09-16 19:42:04 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jsbell@chromium.org/17462005/36009
7 years, 3 months ago (2013-09-16 20:35:49 UTC) #15
commit-bot: I haz the power
Change committed as 223493
7 years, 3 months ago (2013-09-17 00:50:31 UTC) #16
hans
7 years, 3 months ago (2013-09-24 15:53:01 UTC) #17
Message was sent while issue was closed.
On 2013/09/17 00:50:31, I haz the power (commit-bot) wrote:
> Change committed as 223493

w00t!

Powered by Google App Engine
This is Rietveld 408576698