Closed Bug 1675573 Opened 4 years ago Closed 3 years ago

WebRender on linux starts janking after running Firefox for some time

Categories

(Core :: Graphics: WebRender, defect)

defect

Tracking

()

RESOLVED DUPLICATE of bug 1635186

People

(Reporter: smaug, Unassigned)

References

Details

Attachments

(1 file)

The issue seems to happen both with Intel's iGPU and AMD's iGPU.
I haven't yet managed to get this into a performance profile.
The Firefox profile where this shows up has lots of windows and tabs open and
child process count is limited to 400 (but in practice there are way fewer child processes).

Software WebRender has worked well, and non-webrender.

Can you grab a profile?

Flags: needinfo?(bugs)
Blocks: wr-linux, wr-perf
Severity: -- → S3
Attached file about_support.txt

https://share.firefox.dev/36CBGwn

This was with AMD, and happened while watching a youtube video.

Flags: needinfo?(bugs)

Yeah, that's really bad. It looks like we're getting stuck waiting for X:

__poll
_xcb_conn_wait.part.0
<name omitted>
<name omitted>
<name omitted>
<name omitted>
<name omitted>
dri2_allocate_textures
dri_st_framebuffer_validate
<name omitted>
<name omitted>
<name omitted>
<name omitted>
<name omitted>
<gleam::gl::ProfilingGl<F> as gleam::gl::Gl>::draw_arrays
webrender::renderer::Renderer::update_gpu_cache
webrender::renderer::Renderer::render_impl
webrender::renderer::Renderer::render
wr_renderer_render
mozilla::wr::RendererOGL::UpdateAndRender(mozilla::Maybe<mozilla::gfx::IntSizeTyped<mozilla::gfx::UnknownUnits> > const&, mozilla::Maybe<mozilla::wr::ImageFormat> const&, mozilla::Maybe<mozilla::Range<unsigned char> > const&, bool*, mozilla::wr::RendererStats*)
mozilla::wr::RenderThread::UpdateAndRender(mozilla::wr::WrWindowId, mozilla::layers::BaseTransactionId<mozilla::VsyncIdType> const&, mozilla::TimeStamp const&, bool, mozilla::Maybe<mozilla::gfx::IntSizeTyped<mozilla::gfx::UnknownUnits> > const&, mozilla::Maybe<mozilla::wr::ImageFormat> const&, mozilla::Maybe<mozilla::Range<unsigned char> > const&, bool*)
mozilla::wr::RenderThread::HandleFrameOneDoc(mozilla::wr::WrWindowId, bool)
mozilla::detail::RunnableMethodImpl<mozilla::wr::RenderThread*, void (mozilla::wr::RenderThread::*)(mozilla::wr::WrWindowId, bool), true, (mozilla::RunnableKind)0, mozilla::wr::WrWindowId, bool>::Run()
base::MessagePumpDefault::Run(base::MessagePump::Delegate*)
MessagePumpDefault::Run
MessageLoop::Run()
base::Thread::ThreadMain()
(root)
Flags: needinfo?(jmuizelaar)

And happened now again while I was testing if giving more RAM for GPU to use would help. (512MB -> 2GB, didn't make any difference)

Olli, the next time it happens can you try profiling the x server? We seem to be stuck waiting for it, so it would be good to figure out what it's doing.

Flags: needinfo?(bugs)

I'm also curious to know if it happens with MOZ_X11_EGL=1.

And me if this also happens on vanilla X11 - this was on Xwayland, right? Just thinking of of a bug in xserver where there would not be enough buffers available.

This is with xwayland yes. That is what I get by default when running Nightly on Fedora.

Flags: needinfo?(bugs)

Olli: mind checking what happens if you log into a X11 session (on the login screen select "Gnome+X11" or so on the bottom-right)? And then, in both sessions also run nightly with MOZ_X11_EGL=1 env var? That would be super helpful for us I think :)

If possible, MOZ_X11_EGL=1 made the jank even worse.
https://share.firefox.dev/3kM7wMw

Now testing with MOZ_ENABLE_WAYLAND=1

Michel, do you have an idea what could be going on here? It appears we're blocked here while waiting for a buffer on Xwayland with radeonsi. Could that be Xwaylands fault or are we submitting buffers to fast or so?

Flags: needinfo?(michel)

(In reply to Robert Mader [:rmader] from comment #11)

It appears we're blocked here while waiting for a buffer on Xwayland with radeonsi.

Specifically, waiting for notification that a buffer which we previously submitted to the X server for presentation can be reused.

Could that be Xwaylands fault or are we submitting buffers to fast or so?

Not sure, could be either in theory.

I wonder if it could be related to https://bugzilla.mozilla.org/show_bug.cgi?id=1635186#c25 ? I.e. could the MakeCurrent call be for a window which is currently not visible?

Flags: needinfo?(michel)
Blocks: wr-linux-perf
No longer blocks: wr-linux
No longer blocks: wr-perf

Likely the same root cause as bug 1635186 - in any case blocking Xwayland/bug 1695440

Blocks: wr-linux-xwayland
No longer blocks: wr-linux-perf
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → DUPLICATE
Flags: needinfo?(jmuizelaar)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: