Bug 251506 - WebGL in <iframe> is very slow with Metal
Summary: WebGL in <iframe> is very slow with Metal
Status: RESOLVED DUPLICATE of bug 246335
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGL (show other bugs)
Version: Safari 16
Hardware: iPhone / iPad iOS 16
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-02-01 04:37 PST by Marcin
Modified: 2023-02-01 23:10 PST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marcin 2023-02-01 04:37:53 PST
WebGL in <iframe> is very slow with Metal backend enabled.

- Disabling Metal backend solves the problem.

- I've tried limiting resolution to the minimum 160x90, but it does not help.

- I've observed massive battery drain, so it is probably not just Safari is throttling the RAF inside iframe.
Comment 1 Kimmo Kinnunen 2023-02-01 06:38:33 PST
Thanks for the report. If you have set of .html files for a simple repro, that would be very helpful.
Comment 2 Marcin 2023-02-01 08:07:01 PST
My mistake Kimmo. While preparing the test files for you, I realized that I am using flat variables in the shaders (inside the test iframe). The slowdown has nothing to do with iframes but with https://bugs.webkit.org/show_bug.cgi?id=246335

I apologize for submitting this false report.
Comment 3 Kimmo Kinnunen 2023-02-01 23:10:14 PST
Thanks for letting us know.
Once bug 251259 ships, many algorithms using flat shading can use provoking vertex extension to select the most performant configuration for particular platform.

*** This bug has been marked as a duplicate of bug 246335 ***