New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 608780 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocking:
issue 477150



Sign in to add a comment

[Resource Timing] window.performance doesn't work with OOPIFs

Project Member Reported by lukasza@chromium.org, May 3 2016

Issue description

Specs:
- https://www.w3.org/TR/performance-timeline/
- https://www.w3.org/TR/resource-timing/


Repro:
$ ninja ... blink_tests
$ third_party/WebKit/Tools/Scripts/run-webkit-tests -t gn -v --additional-drt-flag=--site-per-process http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_cross_origin_redirect.html


The problem is that with --site-per-process, when window.performance.getEntriesByName is called in the main frame, it fails to find entries related to a cross-site subframe.  Via window.performance.getEntries I only see 4 entries related to the 4 javascript files.

Interestingly window.performance.getEntries returns 0 entries when called in the subframe (500ms after the frame's onload).


Note that cross-site verification in the test is not accidental - the broken test explicitly verifies various aspects of the behavior for cross-site frames:
    - Some things should be 0 in cross-origin redirect:
          redirectStart should be 0 in cross-origin redirect
          redirectEnd should be 0 in cross-origin redirect
          domainLookupStart should be 0 in cross-origin redirect
          domainLookupEnd should be 0 in cross-origin redirect
          connectStart should be 0 in cross-origin redirect
          connectEnd should be 0 in cross-origin redirect
          requestStart should be 0 in cross-origin redirect
          responseStart should be 0 in cross-origin redirect
          secureConnectionStart should be 0 in cross-origin redirect
    - Some things should still be available for a cross-origin redirect:
          fetchStart should be greater than 0 in cross-origin redirect!");
          responseEnd should be greater than 0 in cross-origin redirect!");


AFACT there are 4 affected tests:
    http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_cross_origin_redirect.html
    http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_cross_origin_redirect_with_timing_allow_origin.html
    http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_cross_origin_resource_request.html
    http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_timing_allow_cross_origin_resource_request.html

 
Owner: nasko@chromium.org
Assigning to @nasko for initial triage.
Project Member

Comment 2 by bugdroid1@chromium.org, May 3 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f5fd0274e5e02d283588d8b890a1d3ee564cd77c

commit f5fd0274e5e02d283588d8b890a1d3ee564cd77c
Author: lukasza <lukasza@chromium.org>
Date: Tue May 03 19:12:01 2016

Annotating window.performance-related test failures with a specific bug.

BUG= 608780 

Review-Url: https://codereview.chromium.org/1949583002
Cr-Commit-Position: refs/heads/master@{#391321}

[modify] https://crrev.com/f5fd0274e5e02d283588d8b890a1d3ee564cd77c/third_party/WebKit/LayoutTests/FlagExpectations/site-per-process

Comment 3 Deleted

Comment 4 by sshru...@google.com, May 18 2016

Labels: Test-Layout

Comment 5 by sshru...@google.com, May 18 2016

Components: -Blink>LayoutTests
Deprecating component:Blink>LayoutTests, to use label Test=Layout instead.
Cc: panicker@chromium.org
Components: Blink>DOM

Comment 7 by tkent@chromium.org, Nov 11 2016

Components: -Blink>DOM Blink>PerformanceAPIs
Project Member

Comment 8 by bugdroid1@chromium.org, Mar 29 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/3584247ed72a9c63da351e4042d8208334bcc591

commit 3584247ed72a9c63da351e4042d8208334bcc591
Author: alexmos <alexmos@chromium.org>
Date: Wed Mar 29 21:29:04 2017

Adjust expectations for performance layout test failures with OOPIFs.

BUG= 608780 
NOTRY=true

Review-Url: https://codereview.chromium.org/2779113007
Cr-Commit-Position: refs/heads/master@{#460540}

[modify] https://crrev.com/3584247ed72a9c63da351e4042d8208334bcc591/third_party/WebKit/LayoutTests/FlagExpectations/site-per-process

Comment 9 by panicker@google.com, Apr 13 2017

Status: Assigned (was: Untriaged)

Comment 10 by nasko@chromium.org, Apr 26 2017

Cc: nasko@chromium.org
Owner: ----
Status: Available (was: Assigned)
Summary: [Resource Timing] window.performance doesn't work with OOPIFs (was: window.performance doesn't work with OOPIFs)
Owner: dcheng@chromium.org
Status: Started (was: Available)
Blocking: 780133

Comment 15 by creis@chromium.org, Nov 30 2017

Blocking: -780133
Project Member

Comment 16 by bugdroid1@chromium.org, Jan 18 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e0555e198511a327076ea2ce7c1664e9e5455c11

commit e0555e198511a327076ea2ce7c1664e9e5455c11
Author: Daniel Cheng <dcheng@chromium.org>
Date: Thu Jan 18 20:00:05 2018

Forward resource timing info for cross-process iframe loads.

content::ResourceTimingInfo and blink::WebResourceTimingInfo have been
added to plumb this data through, since the Mojo glue for forwarding
messages to frame proxies doesn't exist yet.

PerformanceResourceTiming's constructor has been updated to set its
internal fields based on blink::WebResourceTimingInfo.  For now, the
internal structure of PerformanceResourceTiming is retained, since
PerformanceNavigationTiming inherits this class, but overrides certain
methods in a way that makes it hard to share the logic.

Followups will change PerformanceResourceTiming to read the fields
directly out of blink::WebResourceTimingInfo, as well as remove the need
to plumb around the policy bits for exposing timing and redirect info
cross-origin.

PerformanceServerTiming has been refactored to separate parsing of the
server header from creation of the C++ DOM objects. In addition, it's
been cleaned up to no longer require plumbing across access policy bit.

Finally, the check for whether or not to forward resource timing info to
the parent frame has been changed to be OOPIF friendly. The original
check used a bool stored on the HTMLFrameOwnerElement, but this is hard
to manage correctly when transferring frames between processes.

Unfortunately, the original forwarding check is difficult to implement
exactly when the check needs to be synchronized between multiple
processes: it relies on several pieces of state in the renderer to stay
in sync in a way that's tricky to replicate between processes. Instead,
this CL moves the notion of tracking the first real load up to frame
creation time rather than navigation commit time, since generation of
resource timings happens before the commit.

Note that due to https://crbug.com/778318, the browser and the renderer
process currently disagree on when a real load has been committed in
cases where an <iframe> with no src specified is inserted... this will
hopefully be resolved in followup patches.

Bug:  608780 
Change-Id: I6c9eba184fd0b1f8ebbc41ba915dea9414cce3b5
Reviewed-on: https://chromium-review.googlesource.com/798592
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Kinuko Yasuda <kinuko@chromium.org>
Reviewed-by: Nasko Oskov <nasko@chromium.org>
Cr-Commit-Position: refs/heads/master@{#530241}
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/browser/frame_host/navigation_entry_impl.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/browser/frame_host/navigation_entry_impl.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/browser/frame_host/navigation_request.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/browser/frame_host/render_frame_host_impl.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/browser/frame_host/render_frame_host_impl.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/browser/renderer_host/render_view_host_impl.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/common/BUILD.gn
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/common/frame_messages.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/common/navigation_params.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/common/navigation_params.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/common/renderer.mojom
[add] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/common/resource_timing_info.cc
[add] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/common/resource_timing_info.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/BUILD.gn
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_frame_impl.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_frame_impl.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_frame_impl_browsertest.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_frame_proxy.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_frame_proxy.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_thread_impl.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_view_browsertest.cc
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/render_view_impl.cc
[add] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/resource_timing_info_conversions.cc
[add] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/content/renderer/resource_timing_info_conversions.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/exported/LocalFrameClientImpl.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/exported/WebFrame.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/exported/WebRemoteFrameImpl.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/exported/WebRemoteFrameImpl.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/Frame.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/FrameOwner.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/LocalFrame.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/LocalFrame.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/LocalFrameClient.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/RemoteFrame.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/RemoteFrame.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/RemoteFrameOwner.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/RemoteFrameOwner.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/frame/WebLocalFrameImpl.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/html/HTMLFrameOwnerElement.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/html/HTMLFrameOwnerElement.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/loader/EmptyClients.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/loader/FrameFetchContext.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/loader/WorkerFetchContext.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/loader/WorkerThreadableLoader.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/Performance.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceBase.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceBase.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceNavigationTiming.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceNavigationTiming.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceResourceTiming.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceResourceTiming.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceServerTiming.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/core/timing/PerformanceServerTiming.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/modules/serviceworkers/FetchEvent.cpp
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/Source/platform/loader/fetch/ResourceTimingInfo.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/public/BUILD.gn
[add] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/public/platform/WebResourceTimingInfo.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/public/platform/WebURLLoadTiming.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/public/web/WebFrameClient.h
[modify] https://crrev.com/e0555e198511a327076ea2ce7c1664e9e5455c11/third_party/WebKit/public/web/WebRemoteFrame.h

Project Member

Comment 17 by bugdroid1@chromium.org, Jan 29 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e26762f0d69b0ea95d5fa81d091c4dacf139f322

commit e26762f0d69b0ea95d5fa81d091c4dacf139f322
Author: Daniel Cheng <dcheng@chromium.org>
Date: Mon Jan 29 19:31:42 2018

Remove failure suppressions for window.performance tests in OOPIF.

Bug:  608780 
Change-Id: I4b699a8322702e117a0e2a5b81b61fd294e781b5
Reviewed-on: https://chromium-review.googlesource.com/889522
Reviewed-by: Ɓukasz Anforowicz <lukasza@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#532543}
[modify] https://crrev.com/e26762f0d69b0ea95d5fa81d091c4dacf139f322/third_party/WebKit/LayoutTests/FlagExpectations/site-per-process

Status: Fixed (was: Started)

Sign in to add a comment