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

Issue 2641953009: [1 of 4] Support prefix queries against the effective_tld_names DAFSA (Closed)

Created:
3 years, 11 months ago by ncarter (slow)
Modified:
3 years, 10 months ago
Reviewers:
Ryan Sleevi
CC:
chromium-reviews, cbentzel+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Support prefix queries against the effective_tld_names DAFSA Reimplement LookupStringInFixedSet in terms of a new incremental prefix lookup class, FixedSetIncrementalLookup. Use FixedSetIncrementalLookup in a unittest to enumerate the language of the DAFSA, and validate that it matches the body of the .gperf file. Because the unittest exhaustively explores every node of the DAFSA on every possible input, it should be safe to demote the CHECKs in this file to DCHECKs, which is a performance win. Because of function inlining and the CHECK removal, this actually runs about 10% faster than the old version. Current scores on my Windows machine (best of 3 runs): RegistryControlledDomainTest.GetDomainAndRegistry: 98ms RegistryControlledDomainTest.SameDomainOrHost_Different: 170ms RegistryControlledDomainTest.SameDomainOrHost_Same: 194ms BUG=678334 Review-Url: https://codereview.chromium.org/2641953009 Cr-Commit-Position: refs/heads/master@{#451085} Committed: https://chromium.googlesource.com/chromium/src/+/0b80485a436c8c881164729adb8484868ecd065d

Patch Set 1 #

Patch Set 2 : Comments and DCHECK-ification #

Patch Set 3 : Move EnumerateDafsaLanguage to lookup_string_in_fixed_set_unittest.cc #

Patch Set 4 : Self-review. #

Patch Set 5 : Revert unrelated unittest diffs #

Patch Set 6 : Update #

Patch Set 7 : Rebase #

Total comments: 45

Patch Set 8 : add gperf to bundle data. #

Patch Set 9 : Add effective_tld_names.gperf to the unittest data dependencies. #

Patch Set 10 : Comment rewriting. #

Patch Set 11 : Convert |sequence| from string to vector (since string.pop_back() isn't everywhere) #

Patch Set 12 : Fixes. #

Total comments: 2

Patch Set 13 : Move unittests to not depend on production dafsa #

Patch Set 14 : Revert BUILD changes. #

Patch Set 15 : Revert BUILD changes. #

Patch Set 16 : Fix problem #

Unified diffs Side-by-side diffs Delta from patch set Stats (+338 lines, -96 lines) Patch
M net/base/lookup_string_in_fixed_set.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +107 lines, -0 lines 0 comments Download
M net/base/lookup_string_in_fixed_set.cc View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +141 lines, -95 lines 0 comments Download
M net/base/lookup_string_in_fixed_set_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +90 lines, -1 line 0 comments Download

Dependent Patchsets:

Messages

Total messages: 49 (42 generated)
Ryan Sleevi
https://codereview.chromium.org/2641953009/diff/120001/net/base/lookup_string_in_fixed_set.cc File net/base/lookup_string_in_fixed_set.cc (right): https://codereview.chromium.org/2641953009/diff/120001/net/base/lookup_string_in_fixed_set.cc#newcode27 net/base/lookup_string_in_fixed_set.cc:27: inline bool GetNextOffset(const unsigned char** pos, Pedantry: It doesn't ...
3 years, 11 months ago (2017-01-25 19:11:05 UTC) #27
ncarter (slow)
ptal https://codereview.chromium.org/2641953009/diff/120001/net/base/lookup_string_in_fixed_set.cc File net/base/lookup_string_in_fixed_set.cc (right): https://codereview.chromium.org/2641953009/diff/120001/net/base/lookup_string_in_fixed_set.cc#newcode27 net/base/lookup_string_in_fixed_set.cc:27: inline bool GetNextOffset(const unsigned char** pos, On 2017/01/25 ...
3 years, 11 months ago (2017-01-26 23:29:12 UTC) #36
Ryan Sleevi
LGTM - thanks for doing this; the documentation made this much easier to read & ...
3 years, 11 months ago (2017-01-27 00:08:24 UTC) #37
Ryan Sleevi
Ping? Are the others good for review now?
3 years, 10 months ago (2017-02-14 18:35:14 UTC) #38
ncarter (slow)
I think this is ready to land now. I'm renumbering the patches in the series ...
3 years, 10 months ago (2017-02-15 23:42:11 UTC) #41
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2641953009/300001
3 years, 10 months ago (2017-02-16 19:11:48 UTC) #46
commit-bot: I haz the power
3 years, 10 months ago (2017-02-16 20:27:18 UTC) #49
Message was sent while issue was closed.
Committed patchset #16 (id:300001) as
https://chromium.googlesource.com/chromium/src/+/0b80485a436c8c881164729adb84...

Powered by Google App Engine
This is Rietveld 408576698