Bug 156464 - Fix a bug where createNewPage is not working with warmInitialProcess
Summary: Fix a bug where createNewPage is not working with warmInitialProcess
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Ryuan Choi
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-04-11 05:11 PDT by Ryuan Choi
Modified: 2017-08-19 16:01 PDT (History)
3 users (show)

See Also:


Attachments
Patch (12.54 KB, patch)
2016-04-11 05:26 PDT, Ryuan Choi
no flags Details | Formatted Diff | Diff
Patch (12.58 KB, patch)
2016-04-11 06:47 PDT, Ryuan Choi
no flags Details | Formatted Diff | Diff
Patch (12.80 KB, patch)
2016-05-01 17:01 PDT, Ryuan Choi
beidson: review-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ryuan Choi 2016-04-11 05:11:13 PDT
If I am right, createNewPage must create new page with the process of related page regardless of m_haveInitialEmptyProcess.
Comment 1 Ryuan Choi 2016-04-11 05:26:37 PDT
Created attachment 276139 [details]
Patch
Comment 2 Ryuan Choi 2016-04-11 06:47:02 PDT
Created attachment 276146 [details]
Patch
Comment 3 Alex Christensen 2016-04-11 14:34:28 PDT
Comment on attachment 276146 [details]
Patch

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

> Tools/TestWebKitAPI/Tests/WebKit2/CreatePageWithWarmInitialProcess.cpp:87
> +    WKPageLoadURL(webView.page(), url.get());
> +    WKContextWarmInitialProcess(context.get());

Why do you need to warm the initial process after loading a URL?  I think the intent of WarmInitialProcess is that it is called before loading a URL.
Comment 4 Ryuan Choi 2016-04-11 17:49:44 PDT
Comment on attachment 276146 [details]
Patch

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

>> Tools/TestWebKitAPI/Tests/WebKit2/CreatePageWithWarmInitialProcess.cpp:87
>> +    WKContextWarmInitialProcess(context.get());
> 
> Why do you need to warm the initial process after loading a URL?  I think the intent of WarmInitialProcess is that it is called before loading a URL.

Yes. It is not for the prior Loading(86line) but just to reserve web process before calling createNewPage().
I called it here just to simplify test case.

IMHO, I think that WarmInitialProcess is not only for first process.
So, I called WarmInitialProcess after created every new tab (and without loading a URL).

But in that case, createNewPage() was not working when called window.open() in other tab.
Comment 5 Ryuan Choi 2016-05-01 17:01:02 PDT
Created attachment 277876 [details]
Patch
Comment 6 Ryuan Choi 2016-05-01 17:06:58 PDT
(In reply to comment #5)
> Created attachment 277876 [details]
> Patch

I modified test case little bit with comment.

IMHO, all operations should be fine whenever we call warmInitialProcess.
Comment 7 Brady Eidson 2017-08-19 16:01:33 PDT
Comment on attachment 277876 [details]
Patch

r-, as this has been pending review for over a year now. It is near-impossible that this patch still applies to trunk and unlikely to still be relevant in its current form.