After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 141378 - gstreamer crashes during initialization due to a recent change in gstcpu.c
gstreamer crashes during initialization due to a recent change in gstcpu.c
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other Linux
: Normal blocker
: 0.8.4
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2004-04-29 11:19 UTC by Diego González
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch to gstcpu.c fixing %ebx clobbering (1.05 KB, patch)
2004-06-10 16:29 UTC, Jordan Crouse
none Details | Review

Description Diego González 2004-04-29 11:19:14 UTC
i'm using this version of GCC
gcc.real (GCC) 3.3.3 (Debian 20040401)

reverting this patch everything works again.
http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gstreamer/gst/gstcpu.c?r1=1.24&r2=1.25
Comment 1 David Schleef 2004-04-29 21:48:43 UTC
I can't reproduce this.
Comment 2 Ronald Bultje 2004-04-30 00:46:18 UTC
Are you using any extraordinary optimization levels or otherwise odd compiler flags?
Comment 3 Diego González 2004-05-03 16:30:15 UTC
-Os -msse -mfpmath=sse

before the change to that file it worked with this options
Comment 4 David Schleef 2004-05-03 19:25:41 UTC
Again, I can't reproduce this.
Comment 5 Ronald Bultje 2004-05-03 19:41:22 UTC
Diego, try without -msse. I've seen weird random crashes and errors on
ffmpeg-devel for people that were using that. Try the default compiler flags, at
least for this specific file.
Comment 6 Diego González 2004-05-22 16:03:31 UTC
i've already try without -msse it, it keeps crashing, i'm going to try without
-Os to see what happends
Comment 7 Götz Waschk 2004-05-28 10:43:32 UTC
I can confirm this on Mandrakelinux 10.1 Cooker with gcc 3.3.2. My CFLAGS are
these: 

gcc -DHAVE_CONFIG_H -I. -I. -I.. -D_GNU_SOURCE -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -pthread -I/usr/include/glib-2.0
-I/usr/lib/glib-2.0/include -I/usr/include/libxml2 -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -fno-common -g -Wall -Werror -DGST_DISABLE_DEPRECATED
-I.. -DG_LOG_DOMAIN=g_log_domain_gstreamer -DGST_MAJORMINOR=\"0.8\" -O2
-fomit-frame-pointer -pipe -march=i586 -mtune=pentiumpro -c gstcpu.c  -fPIC
-DPIC -o .libs/libgstreamer_0.8_la-gstcpu.o
Comment 8 Jordan Crouse 2004-06-10 16:29:18 UTC
Created attachment 28563 [details] [review]
Patch to gstcpu.c fixing %ebx clobbering
Comment 9 Jordan Crouse 2004-06-10 16:32:47 UTC
Previous patch solves %ebx clobbering.  To make a long story short, original
code was pushing %ebx onto offset 0x0 in the stack in gst_cpuid_i386.  However,
reg[0] (the eventual destination of %eax) was going to the same location,
effectively clobbering %ebx.

A possible solution is to add another item to reg[], and increasing all offsets
by 1, thereby leaving offset 0x0 in the stack untouched (%eax will save to
0x4($esp), etc, etc..)

There may be more elegant solutions available, but this works for me... :)
Comment 10 David Schleef 2004-06-10 19:02:27 UTC
The patch is wrong.

The problem is that you're using -fomit-frame-pointer.  Don't.

If I get a good idea of how to handle the -fomit-frame-pointer case at the same
time as all the others, I'll fix it.  Otherwise, I'll add an autoconf check to
make sure -fomit-frame-pointer is not being used.
Comment 11 Ronald Bultje 2004-06-17 03:32:10 UTC
This is fixed in CVS, will be released along with 0.8.4.

http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gstreamer/gst/gstcpu.c?r1=1.27&r2=1.28