Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(182)

Issue 238923009: HTML Imports: No more BlockingDocumentCreation. (Closed)

Created:
6 years, 8 months ago by Hajime Morrita
Modified:
6 years, 8 months ago
CC:
blink-reviews, gavinp+prerender_chromium.org, webcomponents-bugzilla_chromium.org, sof, eae+blinkwatch, abarth-chromium, dglazkov+blink, adamk+blink_chromium.org, Mikhail, rwlbuis, Inactive
Visibility:
Public.

Description

HTML Imports: No more BlockingDocumentCreation. This change gets rid of HTMLImportState::BlockingDocumentCreation. This is a perf improvement as Blink no longer delay parsing of imports which leads earlier fetch requests. To make it work, the change: * Gets rid of the notion of "owning loader". Now fewer places depends on the import tree ordering. * HTMLImportLoader::addImport() is one of such place. It does ensure that: * The firstImport() is the first import of the same URL in tree order of the import tree. * The firstImport() has all children that is loaded by the document. HTMLImport::recalcTreeState() and HTMLImportLoader::shouldBlockScriptExecution() relies on these invariants. * The microtask queue of CustomElementMicrotaskImportSteps is got owned by HTMLImportLoader. Also, now each HTMLImportChild can have the step regardless of its tree order. This ensures that each imported document blocks microtask queue consumption of all referring documents. * HTMLImportResolver::shouldBlockDocumentCreation() is merged into shouldBlockScriptExecution() The change on import-nested-dup.html is to cover the observable invariant of script execution order more precisely. TEST=import-dup-custom-element.html,import-nested-dup.html,import-nested-dup-2.html R=dominicc@chromium.org BUG=none Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=171966

Patch Set 1 #

Patch Set 2 : Fixed the build breakage #

Total comments: 14

Patch Set 3 : Killed RefCountedCustomElementMicrotaskQueue #

Patch Set 4 : Landing #

Patch Set 5 : Landing #

Patch Set 6 : Rebased to ToT. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+306 lines, -126 lines) Patch
M LayoutTests/fast/html/imports/import-nested-dup.html View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/html/imports/import-nested-dup-2.html View 1 chunk +2 lines, -1 line 0 comments Download
M LayoutTests/fast/html/imports/import-nested-dup-2-expected.txt View 2 chunks +2 lines, -12 lines 0 comments Download
M LayoutTests/fast/html/imports/import-nested-dup-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/html/imports/resources/nest-dup.html View 1 chunk +1 line, -0 lines 0 comments Download
A + LayoutTests/fast/html/imports/resources/nest-dup-child.html View 0 chunks +-1 lines, --1 lines 0 comments Download
A LayoutTests/http/tests/htmlimports/import-dup-custom-element.html View 1 2 3 1 chunk +48 lines, -0 lines 0 comments Download
A LayoutTests/http/tests/htmlimports/import-dup-custom-element-expected.txt View 1 chunk +13 lines, -0 lines 0 comments Download
A LayoutTests/http/tests/htmlimports/resources/custom-element-def.html View 1 2 3 1 chunk +15 lines, -0 lines 0 comments Download
A LayoutTests/http/tests/htmlimports/resources/pointing-custom-element-def.html View 1 chunk +6 lines, -0 lines 0 comments Download
A LayoutTests/http/tests/htmlimports/resources/using-custom-element-1.html View 1 chunk +10 lines, -0 lines 0 comments Download
A LayoutTests/http/tests/htmlimports/resources/using-custom-element-2.html View 1 chunk +10 lines, -0 lines 0 comments Download
M Source/core/dom/custom/CustomElementMicrotaskDispatcher.h View 1 2 3 chunks +3 lines, -3 lines 0 comments Download
M Source/core/dom/custom/CustomElementMicrotaskDispatcher.cpp View 1 2 4 chunks +8 lines, -6 lines 0 comments Download
M Source/core/dom/custom/CustomElementMicrotaskImportStep.h View 1 2 2 chunks +8 lines, -8 lines 0 comments Download
M Source/core/dom/custom/CustomElementMicrotaskImportStep.cpp View 1 2 2 chunks +11 lines, -8 lines 0 comments Download
M Source/core/dom/custom/CustomElementMicrotaskQueue.h View 1 2 3 1 chunk +9 lines, -3 lines 0 comments Download
M Source/core/dom/custom/CustomElementMicrotaskQueue.cpp View 1 2 3 2 chunks +41 lines, -0 lines 0 comments Download
M Source/core/dom/custom/CustomElementScheduler.cpp View 1 2 3 chunks +4 lines, -3 lines 0 comments Download
M Source/core/html/imports/HTMLImport.h View 1 2 3 2 chunks +4 lines, -5 lines 0 comments Download
M Source/core/html/imports/HTMLImport.cpp View 1 2 3 1 chunk +12 lines, -2 lines 0 comments Download
M Source/core/html/imports/HTMLImportChild.h View 1 chunk +1 line, -3 lines 0 comments Download
M Source/core/html/imports/HTMLImportChild.cpp View 7 chunks +9 lines, -32 lines 0 comments Download
M Source/core/html/imports/HTMLImportLoader.h View 1 2 3 chunks +8 lines, -1 line 0 comments Download
M Source/core/html/imports/HTMLImportLoader.cpp View 1 2 3 4 chunks +33 lines, -4 lines 0 comments Download
M Source/core/html/imports/HTMLImportState.h View 2 chunks +3 lines, -5 lines 0 comments Download
M Source/core/html/imports/HTMLImportStateResolver.h View 1 chunk +0 lines, -1 line 0 comments Download
M Source/core/html/imports/HTMLImportStateResolver.cpp View 2 chunks +2 lines, -14 lines 0 comments Download
M Source/core/html/imports/HTMLImportsController.h View 1 chunk +0 lines, -1 line 0 comments Download
M Source/core/html/imports/HTMLImportsController.cpp View 1 2 3 4 chunks +15 lines, -9 lines 0 comments Download
M Source/core/html/imports/LinkImport.h View 1 chunk +0 lines, -1 line 0 comments Download
M Source/core/html/imports/LinkImport.cpp View 1 chunk +0 lines, -5 lines 0 comments Download
M Source/wtf/TreeNode.h View 1 chunk +10 lines, -0 lines 0 comments Download
M Source/wtf/TreeNodeTest.cpp View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download

Messages

Total messages: 14 (0 generated)
Hajime Morrita
PTAL? This is what we discussed last week.
6 years, 8 months ago (2014-04-17 00:21:09 UTC) #1
dominicc (has gone to gerrit)
LGTM I think this achieves your objective, is possible to understand, nothing fishy (ownership of ...
6 years, 8 months ago (2014-04-18 00:56:25 UTC) #2
Hajime Morrita
Thanks or the thorough review! Landing with fix. I added scope re-enter detector for the ...
6 years, 8 months ago (2014-04-18 01:48:32 UTC) #3
Hajime Morrita
The CQ bit was checked by morrita@chromium.org
6 years, 8 months ago (2014-04-18 01:49:33 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/morrita@chromium.org/238923009/60001
6 years, 8 months ago (2014-04-18 01:49:45 UTC) #5
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 8 months ago (2014-04-18 02:00:13 UTC) #6
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on mac_blink_rel
6 years, 8 months ago (2014-04-18 02:00:13 UTC) #7
Hajime Morrita
The CQ bit was checked by morrita@chromium.org
6 years, 8 months ago (2014-04-18 18:12:22 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/morrita@chromium.org/238923009/80001
6 years, 8 months ago (2014-04-18 18:12:34 UTC) #9
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 8 months ago (2014-04-18 18:12:54 UTC) #10
commit-bot: I haz the power
Failed to apply patch for Source/core/html/HTMLLinkElement.cpp: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
6 years, 8 months ago (2014-04-18 18:12:54 UTC) #11
Hajime Morrita
The CQ bit was checked by morrita@chromium.org
6 years, 8 months ago (2014-04-18 18:25:39 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/morrita@chromium.org/238923009/100001
6 years, 8 months ago (2014-04-18 18:25:54 UTC) #13
commit-bot: I haz the power
6 years, 8 months ago (2014-04-18 19:37:35 UTC) #14
Message was sent while issue was closed.
Change committed as 171966

Powered by Google App Engine
This is Rietveld 408576698