Bug 234341 - [:has() pseudo-class] Use Bloom filter to quickly reject :has() selectors
Summary: [:has() pseudo-class] Use Bloom filter to quickly reject :has() selectors
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Antti Koivisto
URL:
Keywords: InRadar
Depends on:
Blocks: 227702
  Show dependency treegraph
 
Reported: 2021-12-15 02:55 PST by Antti Koivisto
Modified: 2021-12-15 11:47 PST (History)
10 users (show)

See Also:


Attachments
Patch (22.89 KB, patch)
2021-12-15 03:22 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
Patch (24.15 KB, patch)
2021-12-15 05:09 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
Patch for landing (25.30 KB, patch)
2021-12-15 09:42 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
Patch for landing (25.31 KB, patch)
2021-12-15 09:51 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
Patch for landing (25.03 KB, patch)
2021-12-15 10:00 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
Patch (25.03 KB, patch)
2021-12-15 10:48 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
Patch for landing (25.03 KB, patch)
2021-12-15 10:50 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antti Koivisto 2021-12-15 02:55:33 PST
Fast reject for :has()
Comment 1 Antti Koivisto 2021-12-15 03:22:46 PST
Created attachment 447218 [details]
Patch
Comment 2 Antti Koivisto 2021-12-15 05:09:32 PST
Created attachment 447224 [details]
Patch
Comment 3 Dean Jackson 2021-12-15 09:27:24 PST
Comment on attachment 447224 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=447224&action=review

> Source/WebCore/ChangeLog:48
> +        Add HasSelectorFilter which uses non-counting BloomFilter internally. The size of the filter is 64 bytes.

I don't understand how BloomFilter<14> is 64 bytes but I'll take your word for it.
Comment 4 Antti Koivisto 2021-12-15 09:30:52 PST
> I don't understand how BloomFilter<14> is 64 bytes but I'll take your word
> for it.

It is not!
Comment 5 Antti Koivisto 2021-12-15 09:42:37 PST
Created attachment 447244 [details]
Patch for landing
Comment 6 Antti Koivisto 2021-12-15 09:51:49 PST
Created attachment 447247 [details]
Patch for landing
Comment 7 EWS 2021-12-15 09:52:43 PST
Tools/Scripts/svn-apply failed to apply attachment 447247 [details] to trunk.
Please resolve the conflicts and upload a new patch.
Comment 8 Antti Koivisto 2021-12-15 09:54:10 PST
It is now BloomFilter<12> and 512 bytes (hopefully)
Comment 9 Antti Koivisto 2021-12-15 10:00:15 PST
Created attachment 447249 [details]
Patch for landing
Comment 10 Simon Fraser (smfr) 2021-12-15 10:10:41 PST
Comment on attachment 447249 [details]
Patch for landing

View in context: https://bugs.webkit.org/attachment.cgi?id=447249&action=review

> Source/WebCore/ChangeLog:18
> +        Use it to quikly reject selectors.

quikly -> quickly
Comment 11 Antti Koivisto 2021-12-15 10:48:48 PST
Created attachment 447258 [details]
Patch
Comment 12 Antti Koivisto 2021-12-15 10:50:39 PST
Created attachment 447259 [details]
Patch for landing
Comment 13 EWS 2021-12-15 11:46:30 PST
Committed r287091 (245283@main): <https://commits.webkit.org/245283@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 447259 [details].
Comment 14 Radar WebKit Bug Importer 2021-12-15 11:47:18 PST
<rdar://problem/86535166>