Date: Thu, 15 Nov 2001 10:55:02 -0500 (EST) From: Joe Clarke <marcus@marcuscom.com> To: freebsd-ports@freebsd.org Cc: freebsd-stable@freebsd.org Subject: sigreturn: eflags creash (fixed!) Message-ID: <20011115104710.D47613-200000@shumai.marcuscom.com>
next in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
Sorry for the wide distribution, but I have sent email to both lists
regarding this problem in the past. It seems that while doing intensive
threaded operations in Gnome applications, crashes occur with the
following kernel message:
sigreturn: eflags 0x280
And, in .gnomerc-errors:
Fatal error 'Thread has returned from sigreturn or longjump'
The problem as I have found it is with libpng. libpng uses MMX
optimizations by default on FreeBSD. If you apply the attached patch to
patch-aa in /usr/ports/graphics/png, the problem goes away. You only need
to recompile and install libpng. Reinstalling Gnome isn't necessary. It
seems the MMX optimizations are corrupting eflags, and when a thread tries
to restore context after a signal, things go really wrong.
The true fix will probably come in analyzing the MMX code in libpng.
Unfortunately, I don't know enough about x86 assembly to be of much use
here. Hopefully this will help other experiencing the same problem.
Joe
[-- Attachment #2 --]
--- patch-aa.orig Thu Nov 15 10:52:33 2001
+++ patch-aa Thu Nov 15 10:52:23 2001
@@ -42,10 +42,6 @@
pngwtran.o pngmem.o pngerror.o pngpread.o
-all: libpng.a pngtest
-+.if (${ARCH} == "i386")
-+CFLAGS+=-DPNG_USE_PNGGCCRD
-+OBJS+=pnggccrd.o
-+.endif
+
+.SUFFIXES: .c .so .o
+
@@ -91,5 +87,4 @@
pngwtran.o: png.h pngconf.h
pngwutil.o: png.h pngconf.h
pngpread.o: png.h pngconf.h
-+pnggccrd.o: png.h pngconf.h pngasmrd.h
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011115104710.D47613-200000>
