Closed Bug 1801820 Opened 1 year ago Closed 6 months ago

[X11 freeze] Firefox unresponsive on copying or pasting: Introduced/caused by libx11 1.8.2

Categories

(Core :: Widget: Gtk, defect, P3)

Firefox 107
x86_64
Linux
defect

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: karthik.eu, Unassigned)

References

(Blocks 1 open bug, )

Details

(Keywords: crash, hang)

Crash Data

Attachments

(3 files)

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:107.0) Gecko/20100101 Firefox/107.0

Steps to reproduce:

Do one of these randomly

  • Select text (indirectly copying to the middle click clipboard)
  • Copy text
  • Paste text

Actual results:

Firefox freezes. It does not respond to any input events. Resizing the window does not repaint. When I attached gdb, I saw these functions every time. The other elements in the backtrace were not.

gtk_clipboard_set_with_data -> gdk_x11_get_server_time -> .. some lock ..

Expected results:

Firefox should not freeze.

Attached file firefox-backtrace.txt

Attached a full backtrace after I reproduced it another time by select-copy-pasting randomly

OS: Unspecified → Linux
Hardware: Unspecified → x86_64
Component: Untriaged → Widget: Gtk
Product: Firefox → Core

Please attach your about:support page. Which distro/desktop do you use?
Thanks.

Flags: needinfo?(karthik.eu)
Attached file about-support

I am running KDE on ArchLinux with the latest versions of packages on Nvidia 1660

Flags: needinfo?(karthik.eu)

Dupe of Bug 1776263?
Please run on terminal:
MOZ_LOG="Widget:5 WidgetClipboard:5" firefox > log.txt 2>&1
and attach the log here.
Thanks.

Flags: needinfo?(karthik.eu)
Priority: -- → P3
Attached file moz_log

I had to killall firefox because I couldn't quit it normally. Hope it helps

Flags: needinfo?(karthik.eu)

That's interesting, Thanks. Would be great to have correct debug symbols from libxul.

Please install Mozilla binaries:
https://fedoraproject.org/wiki/How_to_debug_Firefox_problems#Testing_Mozilla_binaries

and then use mozilla crashreporter to get the backtrace:
https://fedoraproject.org/wiki/Debugging_guidelines_for_Mozilla_products#Getting_Mozilla_crash_report_from_running_application

Thanks.

Flags: needinfo?(karthik.eu)

I had to remove -no-remote and -ProfileManager from the CLI args. I sent signal 11 to the process and got the report here

https://crash-stats.mozilla.org/report/index/39f19e47-2377-4d8a-ab88-0912e0221124

Did I get it right?

Flags: needinfo?(karthik.eu)

(In reply to karthik.eu from comment #10)

Did I get it right?

Yes, that's exactly what I need, Thanks.

Firefox is blocked on two threads.

Main thread which handles clipboard:

0 	libc.so.6 	futex_wait 	/usr/src/debug/glibc/sysdeps/nptl/futex-internal.h:146 	inlined
0 	libc.so.6 	__GI___lll_lock_wait 	/usr/src/debug/glibc/nptl/lowlevellock.c:49 	context
1 	libc.so.6 	lll_mutex_lock_optimized 	/usr/src/debug/glibc/nptl/pthread_mutex_lock.c:48 	inlined
1 	libc.so.6 	__GI___pthread_mutex_lock 	/usr/src/debug/glibc/nptl/pthread_mutex_lock.c:93 	cfi
2 	libX11.so.6 	_XInternalLockDisplay 	/usr/src/debug/libx11/libX11-1.8.2/src/locking.c:526 	cfi
3 	libX11.so.6 	_XReadEvents 	/usr/src/debug/libx11/libX11-1.8.2/src/xcb_io.c:491 	inlined
3 	libX11.so.6 	_XReadEvents 	/usr/src/debug/libx11/libX11-1.8.2/src/xcb_io.c:454 	cfi
4 	libX11.so.6 	XIfEvent 	/usr/src/debug/libx11/libX11-1.8.2/src/IfEvent.c:70 	cfi
5 	libgdk-3.so.0 	gdk_x11_get_server_time 	/usr/src/debug/gtk/gdk/x11/gdkwindow-x11.c:5627 	cfi
6 	libgtk-3.so.0 	clipboard_get_timestamp 	/usr/src/debug/gtk/gtk/gtkclipboard.c:496 	cfi
7 	libgtk-3.so.0 	gtk_clipboard_set_contents 	/usr/src/debug/gtk/gtk/gtkclipboard.c:605 	cfi
8 	libgtk-3.so.0 	gtk_clipboard_set_with_data 	/usr/src/debug/gtk/gtk/gtkclipboard.c:675 	cfi

and Rendering thread:

0 	libc.so.6 	futex_wait 	/usr/src/debug/glibc/sysdeps/nptl/futex-internal.h:146 	inlined
0 	libc.so.6 	__GI___lll_lock_wait 	/usr/src/debug/glibc/nptl/lowlevellock.c:49 	context
1 	libc.so.6 	lll_mutex_lock_optimized 	/usr/src/debug/glibc/nptl/pthread_mutex_lock.c:48 	inlined
1 	libc.so.6 	__GI___pthread_mutex_lock 	/usr/src/debug/glibc/nptl/pthread_mutex_lock.c:93 	cfi
2 	libX11.so.6 	_XInternalLockDisplay 	/usr/src/debug/libx11/libX11-1.8.2/src/locking.c:526 	cfi
3 	libX11.so.6 	_XReply 	/usr/src/debug/libx11/libX11-1.8.2/src/xcb_io.c:706 	cfi
4 	libnvidia-glsi.so.520.56.06 	_nv000glsi 		cfi
5 	libnvidia-glsi.so.520.56.06 	_nv000glsi 		cfi
6 	libnvidia-eglcore.so.520.56.06 	NvGlEglApiInit 		cfi
7 	libnvidia-eglcore.so.520.56.06 	_glNamedBufferAttachMemoryNV 		cfi
8 	libnvidia-eglcore.so.520.56.06 	_glNamedBufferAttachMemoryNV 		cfi

Is that a recent issue or have you seen that for while?
Thanks.

Flags: needinfo?(karthik.eu)

IIRC I hit this bug roughly a week ago. That coincides with two things,

Flags: needinfo?(karthik.eu)

Can you try to downgrade the libx11 library? I don't think GPU is related here unless you mean the NVIDIA one used by Firefox.

Flags: needinfo?(karthik.eu)

I downgraded to libx11-1.8.1-3. No matter how much I select / copy text on a webpage, I cannot yet reproduce the crash. I did not restart the X server, just firefox.

I agree, the new secondary GPU is not involved with X or firefox.

Flags: needinfo?(karthik.eu)

You don't need to restart X Server for that.

Please report that at Archlinux bugtracker, looks like a problem with the libx11 update.
Thanks.

Summary: Firefox unresponsive on copying or pasting → [X11 freeze] Firefox unresponsive on copying or pasting
Duplicate of this bug: 1805180

The following field has been copied from a duplicate bug:

Field Value Source
Status NEW bug 1805180

For more information, please visit auto_nag documentation.

Status: UNCONFIRMED → NEW
Ever confirmed: true
Crash Signature: [@ libX11.so.6@0x41547 ] [@ futex_wait ]
Keywords: crash, hang
Summary: [X11 freeze] Firefox unresponsive on copying or pasting → [X11 freeze] Firefox unresponsive on copying or pasting: Introduced/caused by libx11 1.8.2
Duplicate of this bug: 1803592
Duplicate of this bug: 1800903
Duplicate of this bug: 1803982
Duplicate of this bug: 1805159
See Also: → 1743551, 1802229

Closing because no crashes reported for 12 weeks.

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

Attachment

General

Creator:
Created:
Updated:
Size: