<?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>184899</bug_id>
          
          <creation_ts>2018-04-23 15:29:37 -0700</creation_ts>
          <short_desc>Investigate a better heuristic for when to prewarm a process</short_desc>
          <delta_ts>2018-05-09 10:51:59 -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>WebKit2</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=184765</see_also>
          <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="Saam Barati">saam</reporter>
          <assigned_to name="Saam Barati">saam</assigned_to>
          <cc>achristensen</cc>
    
    <cc>beidson</cc>
    
    <cc>cdumez</cc>
    
    <cc>fpizlo</cc>
    
    <cc>ggaren</cc>
    
    <cc>msaboff</cc>
    
    <cc>rniwa</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1416994</commentid>
    <comment_count>0</comment_count>
    <who name="Saam Barati">saam</who>
    <bug_when>2018-04-23 15:29:37 -0700</bug_when>
    <thetext>Some ideas:
- on the &apos;load&apos; event
- a timer X ms after the &apos;load&apos; event.

Or some combination of a timer an load event or first paint.

Perhaps there are other heuristics as well</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1417027</commentid>
    <comment_count>1</comment_count>
    <who name="Saam Barati">saam</who>
    <bug_when>2018-04-23 17:23:40 -0700</bug_when>
    <thetext>one way the current heuristic falls down is:
- load &quot;a.com&quot; &lt;-- does prewarm a process
- press a link on &quot;a.com&quot; going to &quot;b.com&quot; &lt;-- uses the prewarmed process
- Go back (to &quot;a.com&quot; &lt;--- does not prewarm a process
- press a link on &quot;a.com&quot; for &quot;c.com&quot; &lt;-- does not use a prewarmed process because one doesn&apos;t exist

So we should take into account prewarming a process when using back/forward cache</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1417028</commentid>
    <comment_count>2</comment_count>
    <who name="Saam Barati">saam</who>
    <bug_when>2018-04-23 17:26:17 -0700</bug_when>
    <thetext>(In reply to Saam Barati from comment #1)
&gt; one way the current heuristic falls down is:
&gt; - load &quot;a.com&quot; &lt;-- does prewarm a process
&gt; - press a link on &quot;a.com&quot; going to &quot;b.com&quot; &lt;-- uses the prewarmed process
&gt; - Go back (to &quot;a.com&quot; &lt;--- does not prewarm a process
&gt; - press a link on &quot;a.com&quot; for &quot;c.com&quot; &lt;-- does not use a prewarmed process
&gt; because one doesn&apos;t exist
&gt; 
&gt; So we should take into account prewarming a process when using back/forward
&gt; cache

actually, I&apos;m off here. Maybe we don&apos;t need to do anything, since we do end up using a prewarmed process for &quot;c.com&quot;, because &quot;b.com&quot; will prewarm a process</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1422310</commentid>
    <comment_count>3</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2018-05-09 09:52:08 -0700</bug_when>
    <thetext>&lt;rdar://problem/40094910&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1422311</commentid>
    <comment_count>4</comment_count>
    <who name="Geoffrey Garen">ggaren</who>
    <bug_when>2018-05-09 09:53:24 -0700</bug_when>
    <thetext>I think we also need to merge navigation process prewarming with the process prewarming we already do to speed up launch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1422332</commentid>
    <comment_count>5</comment_count>
    <who name="Saam Barati">saam</who>
    <bug_when>2018-05-09 10:18:36 -0700</bug_when>
    <thetext>(In reply to Geoffrey Garen from comment #4)
&gt; I think we also need to merge navigation process prewarming with the process
&gt; prewarming we already do to speed up launch.

Merge in what sense? They both call the same codepath if that’s what you mean</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1422344</commentid>
    <comment_count>6</comment_count>
    <who name="Geoffrey Garen">ggaren</who>
    <bug_when>2018-05-09 10:51:59 -0700</bug_when>
    <thetext>&gt; Merge in what sense? They both call the same codepath if that’s what you mean

Yeah, I guess that&apos;s what I mean. :P</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>