Bug 234341

Summary: [:has() pseudo-class] Use Bloom filter to quickly reject :has() selectors
Product: WebKit Reporter: Antti Koivisto <koivisto>
Component: CSSAssignee: Antti Koivisto <koivisto>
Status: RESOLVED FIXED    
Severity: Normal CC: allan.jensen, dino, esprehn+autocc, ews-watchlist, glenn, gyuyoung.kim, macpherson, menard, simon.fraser, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 227702    
Attachments:
Description Flags
Patch
none
Patch
none
Patch for landing
none
Patch for landing
none
Patch for landing
none
Patch
none
Patch for landing none

Antti Koivisto
Reported 2021-12-15 02:55:33 PST
Fast reject for :has()
Attachments
Patch (22.89 KB, patch)
2021-12-15 03:22 PST, Antti Koivisto
no flags
Patch (24.15 KB, patch)
2021-12-15 05:09 PST, Antti Koivisto
no flags
Patch for landing (25.30 KB, patch)
2021-12-15 09:42 PST, Antti Koivisto
no flags
Patch for landing (25.31 KB, patch)
2021-12-15 09:51 PST, Antti Koivisto
no flags
Patch for landing (25.03 KB, patch)
2021-12-15 10:00 PST, Antti Koivisto
no flags
Patch (25.03 KB, patch)
2021-12-15 10:48 PST, Antti Koivisto
no flags
Patch for landing (25.03 KB, patch)
2021-12-15 10:50 PST, Antti Koivisto
no flags
Antti Koivisto
Comment 1 2021-12-15 03:22:46 PST
Antti Koivisto
Comment 2 2021-12-15 05:09:32 PST
Dean Jackson
Comment 3 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.
Antti Koivisto
Comment 4 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!
Antti Koivisto
Comment 5 2021-12-15 09:42:37 PST
Created attachment 447244 [details] Patch for landing
Antti Koivisto
Comment 6 2021-12-15 09:51:49 PST
Created attachment 447247 [details] Patch for landing
EWS
Comment 7 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.
Antti Koivisto
Comment 8 2021-12-15 09:54:10 PST
It is now BloomFilter<12> and 512 bytes (hopefully)
Antti Koivisto
Comment 9 2021-12-15 10:00:15 PST
Created attachment 447249 [details] Patch for landing
Simon Fraser (smfr)
Comment 10 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
Antti Koivisto
Comment 11 2021-12-15 10:48:48 PST
Antti Koivisto
Comment 12 2021-12-15 10:50:39 PST
Created attachment 447259 [details] Patch for landing
EWS
Comment 13 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].
Radar WebKit Bug Importer
Comment 14 2021-12-15 11:47:18 PST
Note You need to log in before you can comment on or make changes to this bug.