<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>315118</bug_id>
          
          <creation_ts>2026-05-19 12:39:36 -0700</creation_ts>
          <short_desc>Opening or refreshing wasitai.com is extremely slow</short_desc>
          <delta_ts>2026-05-20 02:28:11 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Layout and Rendering</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Said Abou-Hallawa">sabouhallawa</reporter>
          <assigned_to name="Said Abou-Hallawa">sabouhallawa</assigned_to>
          <cc>bfulgham</cc>
    
    <cc>simon.fraser</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>zalan</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2212153</commentid>
    <comment_count>0</comment_count>
    <who name="Said Abou-Hallawa">sabouhallawa</who>
    <bug_when>2026-05-19 12:39:36 -0700</bug_when>
    <thetext>On macOS, the first paint of wasitai.com may take a few seconds. But opening or refreshing it on iOS may take about 50 seconds.

This slow performance happens because the PageColorSampler tries to get five pixels from the first row in the page by taking five snapshots. The size of every snapshot is { 1 x 1 }.

In general this is very inefficient because snapshotFrameRect() can&apos;t know to precisely clip the whole frame drawing to just one pixel. Many renderers will be traversed although their drawing does not affect the required pixel.

By what makes this scenario extremely slow is the expensive blur in this page. On iPhone, wasitai.com draws a blur filter with stdDeviation = { 200, 200 }. This is extremely large stdDeviation. Usually the stdDeviation does not exceed 20px.

So to fix this perf bug, the following fixes should be done:

Instead of getting five snapshots from as single row, a single snapshot will be taken for the whole row. Then pixels in this row will examined. 

Second a new `FilterRenderingOption` named `FastAndLowQuality` will be introduced. This new option will allow clamping the blur stdDeviation to 20px if applied. The PageColorSampler will propagate this flag to rendering code in SnapshotFlags. `snapshotFrameRectWithClip()` will translate this SnapshotFlags to PaintBehavior. RenderLayer will send the PaintBehaviors to `RenderLayerFilters::beginFilterEffect()` which will examine paintBehavior. If it has FastAndLowQualityFilters it will send FilterRenderingOption ::FastAndLowQuality to `CSSFilterRenderer::create()`. FEGaussianBlur will check for this flag and clamp the stdDeviation when creating the appliers or the CGStyle.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2212154</commentid>
    <comment_count>1</comment_count>
    <who name="Said Abou-Hallawa">sabouhallawa</who>
    <bug_when>2026-05-19 12:39:59 -0700</bug_when>
    <thetext>rdar://172480480</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2212155</commentid>
    <comment_count>2</comment_count>
    <who name="Said Abou-Hallawa">sabouhallawa</who>
    <bug_when>2026-05-19 12:52:47 -0700</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/65208</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2212434</commentid>
    <comment_count>3</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2026-05-20 02:28:08 -0700</bug_when>
    <thetext>Committed 313563@main (f4ce4a791de7): &lt;https://commits.webkit.org/313563@main&gt;

Reviewed commits have been landed. Closing PR #65208 and removing active labels.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>