Closed Bug 1630389 Opened 4 years ago Closed 4 years ago

Enable WaitForVBlank by default on Windows 10

Categories

(Core :: Graphics, enhancement, P3)

Desktop
Windows
enhancement

Tracking

()

RESOLVED FIXED
mozilla77
Tracking Status
firefox77 --- fixed

People

(Reporter: bpeers, Assigned: bpeers)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

No description provided.
Assignee: nobody → bpeers
Status: NEW → ASSIGNED
Pushed by bpeers@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/af41b9549456
Enable WaitForVBlank by default on Windows 10 r=jrmuizel
Backout by aiakab@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/22a6286b594e
Backed out changeset af41b9549456 for causing mass Windows failures.

It looks like we might be OOMing for some reason.

Thanks for catching this Arthur.

The failure logs suggest that the crash is in the vsync notifications, not in the VBlank loop itself:

  • PVsyncBridgeChild::SendNotifyVsync
  • VsyncBridgeChild::NotifyVsync
  • PVsyncParent::SendNotify

and in 2 of those the failed allocation is in Pickle::Write(something), the 3rd is (inlined?) IPC::Message::WriteSentinel I think?
At least one of the logs suggests this may be exhausting a pre-allocated pool (like an SBA maybe) rather than a run-away memory leak:
AddressSanitizer: Out of memory. The process has exhausted 8192MB for size class 5120

I'm running a test locally where I've disabled this line:
mWaitVBlankMonitor = primary_monitor;
to force a call to GetOutputFromMonitor in every frame, which is where all the COM Add/Release action is. So far I'm not seeing any runaway memory use after ~15 mins of vsynctester.

Flags: needinfo?(bpeers)

I did notice that when I spam the F5 key on this file:
dom/canvas/test/webgl-conf/checkout/conformance/textures/canvas/tex-2d-rgb-rgb-unsigned_short_5_6_5.html
that I can push one of the processes to consume an extra 100 MB. Which eventually drops down again when I stop spamming, but it takes a bit of time.
It's wild guess but do you think it's possible that increased refresh speed pushes up the highwater mark of this test and it thinks it detects a leak?
Otherwise I don't have a lot of ideas.

Flags: needinfo?(jmuizelaar)

Maybe the refresh speed is not being throttled for some reason? Perhaps we can check if we're waiting for a reasonable amount of time?

Flags: needinfo?(jmuizelaar)

From the Chrome issue: "Deal with monitor power off. WaitForVBlank may return right away without waiting in this case. "

Pushed by bpeers@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/613bd6719175
Enable WaitForVBlank by default on Windows 10 r=jrmuizel
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla77
See Also: → 1636843
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: