Skip to content

[DevTools Bug]: confused on prerender pages and resulting in high-cpu usage loop #35954

@toyoshim

Description

@toyoshim

Website or app

example; https://yuri.twintail.org/chrome/prerendering/specrules.html

Repro steps

Hello, I'm Takashi from Google Chrome team.

I've investigated high-cpu usage issue on prerendering, and noticed that the React Developer Tools seems to be a root cause.
The original report for the chromium project is here; https://crbug.com/478909972

Steps:

  1. Install React Developer Tools Extension (from the Chrome Web Store)
  2. Visit a page that uses specupationrules
  3. Open Chrome's Task manager from ... > More tools >, and see CPU usages
  4. Usage for the prerender pages shows higher CPU usages
  5. Open DevTools
  6. Prerender pages' CPU usages get much higher, and frame of the React Developer Tools spends almost 100%

This needs that the current page is accessible from the Extensions. e.g., they would not have a permission to touch the New Tab Page, and this doesn't happen there.

Also, this happens with Chrome UI triggered pretenders too. So, even if the page doesn't use the speculationrules, the problem could happen when users type something in the Omnibox, and Chrome has confidence on the next navigating page.

I suspect this is because the extension doesn't expect the Chrome's recent MPArch: Multi-Page Architecture, and is confused on multiple page navigations.
Here is a resource for the prerender and link for its impact on the Extension system.
Prerender pages in Chrome for instant page navigations > Impact on extensions

How often does this bug happen?

Every time

DevTools package (automated)

No response

DevTools version (automated)

No response

Error message (automated)

No response

Error call stack (automated)


Error component stack (automated)


GitHub query string (automated)


Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions