{"action":"created","issue":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3201","labels_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3201/labels{/name}","comments_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3201/comments","events_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3201/events","html_url":"https://github.com/cockroachdb/cockroach/pull/3201","id":118408822,"number":3201,"title":"Enable the rocksdb row cache.","user":{"login":"bdarnell","id":160562,"avatar_url":"https://avatars.githubusercontent.com/u/160562?v=3","gravatar_id":"","url":"https://api.github.com/users/bdarnell","html_url":"https://github.com/bdarnell","followers_url":"https://api.github.com/users/bdarnell/followers","following_url":"https://api.github.com/users/bdarnell/following{/other_user}","gists_url":"https://api.github.com/users/bdarnell/gists{/gist_id}","starred_url":"https://api.github.com/users/bdarnell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bdarnell/subscriptions","organizations_url":"https://api.github.com/users/bdarnell/orgs","repos_url":"https://api.github.com/users/bdarnell/repos","events_url":"https://api.github.com/users/bdarnell/events{/privacy}","received_events_url":"https://api.github.com/users/bdarnell/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":{"login":"petermattis","id":6201335,"avatar_url":"https://avatars.githubusercontent.com/u/6201335?v=3","gravatar_id":"","url":"https://api.github.com/users/petermattis","html_url":"https://github.com/petermattis","followers_url":"https://api.github.com/users/petermattis/followers","following_url":"https://api.github.com/users/petermattis/following{/other_user}","gists_url":"https://api.github.com/users/petermattis/gists{/gist_id}","starred_url":"https://api.github.com/users/petermattis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petermattis/subscriptions","organizations_url":"https://api.github.com/users/petermattis/orgs","repos_url":"https://api.github.com/users/petermattis/repos","events_url":"https://api.github.com/users/petermattis/events{/privacy}","received_events_url":"https://api.github.com/users/petermattis/received_events","type":"User","site_admin":false},"milestone":null,"comments":5,"created_at":"2015-11-23T15:45:46Z","updated_at":"2015-11-24T13:43:47Z","closed_at":"2015-11-23T19:57:14Z","pull_request":{"url":"https://api.github.com/repos/cockroachdb/cockroach/pulls/3201","html_url":"https://github.com/cockroachdb/cockroach/pull/3201","diff_url":"https://github.com/cockroachdb/cockroach/pull/3201.diff","patch_url":"https://github.com/cockroachdb/cockroach/pull/3201.patch"},"body":"```\r\nname                                old time/op    new time/op     delta\r\nMVCCStats-4                           4.46µs ± 2%     4.45µs ± 2%      ~     (p=1.000 n=4+4)\r\nMVCCScan1Version1Row-4                8.82µs ± 5%     6.88µs ± 4%   -22.00%  (p=0.029 n=4+4)\r\nMVCCScan1Version10Rows-4              58.5µs ± 6%     44.1µs ± 7%   -24.66%  (p=0.029 n=4+4)\r\nMVCCScan1Version100Rows-4              530µs ± 7%      436µs ± 7%   -17.71%  (p=0.029 n=4+4)\r\nMVCCScan1Version1000Rows-4            5.81ms ±14%     4.56ms ±10%   -21.50%  (p=0.029 n=4+4)\r\nMVCCScan10Versions1Row-4              18.0µs ±12%     12.2µs ± 2%   -32.48%  (p=0.029 n=4+4)\r\nMVCCScan10Versions10Rows-4            78.1µs ± 2%     47.4µs ± 9%   -39.24%  (p=0.029 n=4+4)\r\nMVCCScan10Versions100Rows-4            731µs ± 3%      439µs ± 5%   -39.92%  (p=0.029 n=4+4)\r\nMVCCScan10Versions1000Rows-4          7.79ms ± 6%     4.88ms ± 4%   -37.35%  (p=0.029 n=4+4)\r\nMVCCScan100Versions1Row-4             7.65µs ± 3%     7.84µs ± 5%      ~     (p=0.486 n=4+4)\r\nMVCCScan100Versions10Rows-4           50.7µs ± 6%     50.3µs ± 6%      ~     (p=0.886 n=4+4)\r\nMVCCScan100Versions100Rows-4           481µs ± 6%      460µs ± 4%      ~     (p=0.200 n=4+4)\r\nMVCCScan100Versions1000Rows-4         4.85ms ± 7%     4.81ms ± 5%      ~     (p=1.000 n=4+4)\r\nMVCCGet1Version-4                     7.42µs ± 5%     4.43µs ± 4%   -40.33%  (p=0.029 n=4+4)\r\nMVCCGet10Versions-4                   19.1µs ±15%      6.7µs ± 5%   -64.71%  (p=0.029 n=4+4)\r\nMVCCGet100Versions-4                  5.45µs ± 5%     5.14µs ± 6%      ~     (p=0.114 n=4+4)\r\nMVCCPut10-4                           5.07µs ± 2%     5.03µs ± 3%      ~     (p=0.343 n=4+4)\r\nMVCCPut100-4                          5.24µs ± 1%     5.21µs ± 0%      ~     (p=0.114 n=4+4)\r\nMVCCPut1000-4                         8.40µs ± 7%     8.64µs ± 1%      ~     (p=0.143 n=4+4)\r\nMVCCPut10000-4                        27.8µs ± 1%     27.8µs ± 1%      ~     (p=1.000 n=4+4)\r\nMVCCBatch1Put10-4                     5.63µs ± 1%     5.70µs ± 1%      ~     (p=0.171 n=4+4)\r\nMVCCBatch100Put10-4                   5.26µs ± 3%     5.12µs ± 1%    -2.51%  (p=0.029 n=4+4)\r\nMVCCBatch10000Put10-4                 6.59µs ± 0%     6.55µs ± 1%      ~     (p=0.343 n=4+4)\r\nMVCCBatch100000Put10-4                7.68µs ± 5%     7.66µs ± 2%      ~     (p=0.343 n=4+4)\r\nMVCCMergeTimeSeries-4                 7.83µs ± 2%     7.86µs ± 4%      ~     (p=1.000 n=4+4)\r\nMVCCDeleteRange1Version8Bytes-4        134ms ± 1%      143ms ± 1%    +6.14%  (p=0.029 n=4+4)\r\nMVCCDeleteRange1Version32Bytes-4      96.4ms ± 2%    101.3ms ± 3%    +5.15%  (p=0.029 n=4+4)\r\nMVCCDeleteRange1Version256Bytes-4     27.7ms ± 1%     28.6ms ± 1%    +3.12%  (p=0.029 n=4+4)\r\nMVCCComputeStats1Version8Bytes-4       407ms ± 3%      389ms ± 2%    -4.46%  (p=0.029 n=4+4)\r\nMVCCComputeStats1Version32Bytes-4      285ms ± 1%      273ms ± 1%    -4.04%  (p=0.029 n=4+4)\r\nMVCCComputeStats1Version256Bytes-4    95.9ms ± 1%     91.7ms ± 2%    -4.36%  (p=0.029 n=4+4)\r\n\r\nname                                old speed      new speed       delta\r\nMVCCStats-4                         23.3MB/s ± 2%   23.4MB/s ± 2%      ~     (p=1.000 n=4+4)\r\nMVCCScan1Version1Row-4               116MB/s ± 5%    149MB/s ± 4%   +28.12%  (p=0.029 n=4+4)\r\nMVCCScan1Version10Rows-4             175MB/s ± 6%    233MB/s ± 7%   +32.80%  (p=0.029 n=4+4)\r\nMVCCScan1Version100Rows-4            193MB/s ± 7%    235MB/s ± 7%   +21.63%  (p=0.029 n=4+4)\r\nMVCCScan1Version1000Rows-4           178MB/s ±13%    225MB/s ±10%   +26.98%  (p=0.029 n=4+4)\r\nMVCCScan10Versions1Row-4            57.2MB/s ±11%   84.2MB/s ± 2%   +47.31%  (p=0.029 n=4+4)\r\nMVCCScan10Versions10Rows-4           131MB/s ± 2%    217MB/s ± 9%   +65.15%  (p=0.029 n=4+4)\r\nMVCCScan10Versions100Rows-4          140MB/s ± 3%    233MB/s ± 5%   +66.59%  (p=0.029 n=4+4)\r\nMVCCScan10Versions1000Rows-4         132MB/s ± 6%    210MB/s ± 4%   +59.47%  (p=0.029 n=4+4)\r\nMVCCScan100Versions1Row-4            134MB/s ± 3%    131MB/s ± 5%      ~     (p=0.486 n=4+4)\r\nMVCCScan100Versions10Rows-4          202MB/s ± 6%    204MB/s ± 6%      ~     (p=0.886 n=4+4)\r\nMVCCScan100Versions100Rows-4         213MB/s ± 7%    223MB/s ± 4%      ~     (p=0.200 n=4+4)\r\nMVCCScan100Versions1000Rows-4        212MB/s ± 7%    213MB/s ± 5%      ~     (p=1.000 n=4+4)\r\nMVCCGet1Version-4                    138MB/s ± 5%    232MB/s ± 4%   +67.66%  (p=0.029 n=4+4)\r\nMVCCGet10Versions-4                 54.5MB/s ±16%  152.1MB/s ± 5%  +179.03%  (p=0.029 n=4+4)\r\nMVCCGet100Versions-4                 188MB/s ± 5%    200MB/s ± 6%      ~     (p=0.114 n=4+4)\r\nMVCCPut10-4                         1.97MB/s ± 2%   1.99MB/s ± 2%      ~     (p=0.514 n=4+4)\r\nMVCCPut100-4                        19.1MB/s ± 1%   19.2MB/s ± 0%      ~     (p=0.114 n=4+4)\r\nMVCCPut1000-4                        119MB/s ± 7%    116MB/s ± 1%      ~     (p=0.143 n=4+4)\r\nMVCCPut10000-4                       360MB/s ± 1%    360MB/s ± 1%      ~     (p=1.000 n=4+4)\r\nMVCCBatch1Put10-4                   1.78MB/s ± 1%   1.76MB/s ± 1%      ~     (p=0.114 n=4+4)\r\nMVCCBatch100Put10-4                 1.90MB/s ± 3%   1.95MB/s ± 1%      ~     (p=0.086 n=4+4)\r\nMVCCBatch10000Put10-4               1.52MB/s ± 0%   1.53MB/s ± 1%      ~     (p=0.200 n=4+4)\r\nMVCCBatch100000Put10-4              1.30MB/s ± 5%   1.30MB/s ± 2%      ~     (p=0.629 n=4+4)\r\nMVCCDeleteRange1Version8Bytes-4     3.90MB/s ± 1%   3.68MB/s ± 1%    -5.89%  (p=0.029 n=4+4)\r\nMVCCDeleteRange1Version32Bytes-4    5.44MB/s ± 2%   5.17MB/s ± 3%    -4.87%  (p=0.029 n=4+4)\r\nMVCCDeleteRange1Version256Bytes-4   18.9MB/s ± 1%   18.3MB/s ± 1%    -3.04%  (p=0.029 n=4+4)\r\nMVCCComputeStats1Version8Bytes-4     165MB/s ± 3%    173MB/s ± 2%    +4.66%  (p=0.029 n=4+4)\r\nMVCCComputeStats1Version32Bytes-4    236MB/s ± 1%    246MB/s ± 1%    +4.21%  (p=0.029 n=4+4)\r\nMVCCComputeStats1Version256Bytes-4   700MB/s ± 1%    732MB/s ± 2%\r\n+4.58%  (p=0.029 n=4+4)\r\n```\n\n<!-- Reviewable:start -->\n[<img src=\"https://reviewable.io/review_button.png\" height=40 alt=\"Review on Reviewable\"/>](https://reviewable.io/reviews/cockroachdb/cockroach/3201)\n<!-- Reviewable:end -->\n"},"comment":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/comments/159270739","html_url":"https://github.com/cockroachdb/cockroach/pull/3201#issuecomment-159270739","issue_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3201","id":159270739,"user":{"login":"petermattis","id":6201335,"avatar_url":"https://avatars.githubusercontent.com/u/6201335?v=3","gravatar_id":"","url":"https://api.github.com/users/petermattis","html_url":"https://github.com/petermattis","followers_url":"https://api.github.com/users/petermattis/followers","following_url":"https://api.github.com/users/petermattis/following{/other_user}","gists_url":"https://api.github.com/users/petermattis/gists{/gist_id}","starred_url":"https://api.github.com/users/petermattis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petermattis/subscriptions","organizations_url":"https://api.github.com/users/petermattis/orgs","repos_url":"https://api.github.com/users/petermattis/repos","events_url":"https://api.github.com/users/petermattis/events{/privacy}","received_events_url":"https://api.github.com/users/petermattis/received_events","type":"User","site_admin":false},"created_at":"2015-11-24T13:43:47Z","updated_at":"2015-11-24T13:43:47Z","body":"The MVCCScan benchmarks are only using 100k keys. I imagine the row cache gets populated in early iterations and then utilized. Btw, see #3211 which changes mvccGetInternal to always use an iterator. It eliminates the benefit of the row cache but provides a nice speedup to scan above and beyond what we saw with the row cache enabled. "}}