Closed Bug 1674262 Opened 4 years ago Closed 6 months ago

Make WebGPU initialization async

Categories

(Core :: Graphics: WebGPU, defect, P5)

Firefox 84
x86_64
Windows 10
defect

Tracking

()

RESOLVED WORKSFORME
Tracking Status
firefox84 --- affected

People

(Reporter: rafalopilowski1, Unassigned)

References

(Blocks 1 open bug, )

Details

(Keywords: hang, nightly-community)

Attachments

(1 file)

Steps to reproduce

  1. Visit e.g. https://www.wirtualnemedia.pl/, which includes Google ReCaptcha v2
  2. Try to scroll the webpage while it's loading

Expected results

Firefox remaing responsive throughout the process of loading the website - the page is scrollable.

Actual results

ReCaptcha v2 API call causes Firefox Nightly 84.0a1 (2020-10-29) to hang for ~7 seconds on Windows 10 20H2.

Profiler: https://share.firefox.dev/2HLHWtr

Blocking ReCaptcha v2 API calls via Developer Tools (blocking https://www.google.com/recaptcha/api2/anchor?...) resolves the issue.

Hi Rafał Opiłowski!
I was not able to reproduce this issue on latest Nightly version 84.0a1 (2020-11-02)(64-bit) on Windows 10.
Could you please try to reproduce it on latest Nightly? You can download it from here: https://nightly.mozilla.org/
I will set a component to have a starting point of this. Please if this is not the right component feel free to route this ticket to the corresponding team, thanks!

Component: Untriaged → JavaScript Engine
Flags: needinfo?(rafalopilowski1)
Product: Firefox → Core

Marcela, I was able to reproduce this issue with the latest version of Firefox Nightly 84.0a1 (2020-11-02) (64-bit) - build ID: 20201102095541. What's worth pointing out, issue is not reproducible on a clean profile with Fission disabled (fission.autostart = false).

Flags: needinfo?(rafalopilowski1)

I wasn't able to reproduce it on Mac, either with fission.autostart set to true or to false. In both cases the page scrolls just fine while it's loading. In the DevTools Network pane, I see 7 or 8 requests that include recaptcha. Many are fetching JS code; a few are to the API endpoint.

If this is Fission-only and/or Windows-only, then it's almost certainly not a JavaScript Engine issue. Let's try Core :: Performance.

Component: JavaScript Engine → Performance
Whiteboard: [qf]

Looking at the Jank in the profile, it looks like there is a synchronous IPC with WebRender.

Component: Performance → Graphics: WebRender

The compositor thread is blocked for 7 seconds loading a DLL:
C:\WINDOWS\System32\DriverStore\FileRepository\igdlh64.inf_amd64_1a33d2f73651d989.\igvk64.dll

This happens when initializing WebGPU.

Component: Graphics: WebRender → Graphics: WebGPU

Note "dom.webgpu.enabled" is enabled by the user, so this doesn't affect any Nightly users who don't mess with the settings. Hence setting S3.
We'll need to make WebGPU initialization async though, if it's blocking today (esp on AMD).

Severity: -- → S3

Is there a tracking bug for WebGPU stuff, so that we don't forget to test this again later?
Could you make this bug block such tracking bug?

Flags: needinfo?(dmalyshau)
Whiteboard: [qf]

This is definitely something we need to resolve before MVP status

Blocks: webgpu-mvp
Flags: needinfo?(dmalyshau)
Summary: Google ReCaptcha v2 API call causes Firefox to hang → Make WebGPU initialization async

Does the hang happen multiple times if, say, you visit this page and reload multiple time? https://austin-eng.com/webgpu-samples/samples/helloTriangle

Flags: needinfo?(rafalopilowski1)

Does the hang happen multiple times if, say, you visit this page and reload multiple time? https://austin-eng.com/webgpu-samples/samples/helloTriangle

(In reply to Nicolas Silva [:nical] from comment #11)

Sadly I can't test it as WebGPU crashes on my Intel HD Graphics 530 on Windows 10 21H2.

Here's crash report: https://crash-stats.mozilla.org/report/index/1d2fa459-5e02-4661-bea2-78b330220218

Flags: needinfo?(rafalopilowski1)
Flags: needinfo?(nical.bugzilla)
Flags: needinfo?(nical.bugzilla)
Priority: -- → P3
Blocks: webgpu-v1
No longer blocks: webgpu-mvp
Blocks: webgpu-phase-2
No longer blocks: webgpu-v1

Rafał, could you give this a try in a recent Firefox Nightly?

Flags: needinfo?(rafalopilowski1)
Priority: P3 → P5
No longer blocks: webgpu-triage

Redirect a needinfo that is pending on an inactive user to the triage owner.
:jimb, since the bug has recent activity, could you please find another way to get the information or close the bug as INCOMPLETE if it is not actionable?

For more information, please visit BugBot documentation.

Flags: needinfo?(rafalopilowski1) → needinfo?(jimb)

I cannot reproduce this on latest MacOS, and nobody has recently been able to reproduce this, with expected results being met across platforms and users. Closing as WORKSFORME; if this comes up again and/or the OP wants to attend to NI requests here, we can reopen.

Status: NEW → RESOLVED
Closed: 6 months ago
Flags: needinfo?(jimb)
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: