Closed Bug 206881 Opened 22 years ago Closed 22 years ago

Segfault in libimglib2 when modules/libpr0n compiled with -O{s,3}

Categories

(Firefox Build System :: General, defect)

Sun
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: satadru, Assigned: bryner)

Details

User-Agent: Mozilla/5.0 (X11; U; Linux sparc64; en-US; rv:1.4b) Gecko/20030523 Mozilla Firebird/0.6 Build Identifier: Mozilla/5.0 (X11; U; Linux sparc64; en-US; rv:1.4b) Gecko/20030523 Mozilla Firebird/0.6 phoenix compiled with "-O3 -pipe -mcpu=v9 -mtune=ultrasparc" Always segfaults in libimglib2. recompiled mozilla/components/libpr0n/ with "-O -pipe -mcpu=v9 =mtune=ultrasparc" and copied resultant libimglib2.so to dist/bin/components/ Now Phoenix runs fine. Reproducible: Always Steps to Reproduce: 1.Compile phoenix with --enable-optimize="-O3 -pipe -mcpu=v9 -mtune=ultrasparc" 2. run phoenix 3. Actual Results: crash just after this message: Fontconfig warning: line 245: invalid edit binding "same" Fontconfig warning: line 257: invalid edit binding "same" Xlib: extension "RENDER" missing on display ":0.0". Compiled with gcc version 3.3 20030509 (Debian prerelease)
reporter, are you still having the same problems?
I have also had this problem on Linux/x86 with both Firebird and SeaMonkey. The only optimization flag I needed to use was "-O3", and both browsers would crash when trying to load a page. If I change the optimization flag to "-O", then all is well. Incidentally, I am also running on Debian, using compiler gcc 3.3 (gcc version 3.3.1 (Debian)). Might this have something to do with the compiler, and not necessarily something to do with the source?
QA Contact: asa
I am building mozilla-1.4 on a SPARC/Solaris-8 machine using gcc-3.3.1 and I get a similar segmentation fault with libimglib2.so. Using this bug's information I tried (I also tried making the FLAGS set to null): in modules/libpr0n/build/Makefile, add these lines after "include $(DEPTH)/config/autoconf.mk" MODULE_OPTIMIZE_FLAGS = -O MOZ_OPTIMIZE_FLAGS = -O -mcpu=supersparc rm modules/libpr0n/build/libimglib2.so in modules/libpr0n/build, run gmake cp modules/libpr0n/build/libimglib2.so /home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/components I still get the same error, but maybe my implementation was incorrect, please help! Below are my compile notes and following the notes are the errors I get. mozilla-1.4 unsetenv CFLAGS unsetenv CXXFLAGS unsetenv LDFLAGS the following will enable a build ID: setenv MOZILLA_OFFICIAL 1 setenv BUILD_OFFICIAL 1 ./configure --prefix=/home/jjones1/usr/mozilla-1.4 \ --with-ft-prefix=/home/jjones1/usr \ --with-libIDL-prefix=/home/jjones1/usr/gnome-2.4 \ --enable-default-toolkit=gtk2 \ --with-pthreads \ --without-system-jpeg \ --without-system-mng \ --without-system-nspr \ --without-system-png \ --without-system-zlib \ --enable-js-ultrasparc \ --enable-optimize='-O3 -mcpu=supersparc' \ --enable-xft \ --enable-crypto \ --enable-extensions \ --enable-strip \ --disable-debug \ --disable-tests \ --disable-calendar \ --disable-logging \ --disable-jsd \ --disable-ldap \ --disable-xprint \ --disable-pedantic Note: --disable-pedantic is for gcc-3.3.1 patch -p0 < ../mozilla_xdefs.patch (bugzilla 214959) $ mozilla -g -d gdb /home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/run-mozilla.sh -g -d gdb /home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/mozilla-bin MOZILLA_FIVE_HOME=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4 LD_LIBRARY_PATH=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4:/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/plugins:/home/jjones1/usr/mozilla-1.4/lib/mre/mre-1.4:=MOZILLA_HOME:/home/jjones1/usr/lib:/home/jjones1/usr/gnome-2.2/lib:/home/jjones1/usr/gnome-2.4/lib:/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4:/home/jjones1/usr/gnome-1.4/lib:/home/jjones1/usr/SUNWmlib/lib:/cad/apps/gnu/gnutools/solaris/lib:/usr/openwin/lib DISPLAY=:0.0 FONTCONFIG_PATH=/etc/fonts:/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/res/Xft DYLD_LIBRARY_PATH=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4:/home/jjones1/usr/mozilla-1.4/lib/mre/mre-1.4 LIBRARY_PATH=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4:/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/components:/home/jjones1/usr/mozilla-1.4/lib/mre/mre-1.4 SHLIB_PATH=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4:/home/jjones1/usr/mozilla-1.4/lib/mre/mre-1.4 LIBPATH=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4:/home/jjones1/usr/mozilla-1.4/lib/mre/mre-1.4 ADDON_PATH=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4 MOZ_PROGRAM=/home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/mozilla-bin MOZ_TOOLKIT= moz_debug=1 moz_debugger=gdb /cad/apps/gnu/solaris/bin/gdb /home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/mozilla-bin -x /tmp/mozargs16209 GDB is free software and you are welcome to distribute copies of it under certain conditions; type "show copying" to see the conditions. There is absolutely no warranty for GDB; type "show warranty" for details. GDB 4.16 (sparc-sun-solaris2.5.1), Copyright 1996 Free Software Foundation, Inc...(no debugging symbols found)... (gdb) run Starting program: /home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/mozilla-bin warning: Unable to find dynamic linker breakpoint function. warning: GDB will be unable to debug shared library initializers warning: and track explicitly loaded dynamic code. (no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)... (no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)... (no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)... (no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)... (no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)...(no debugging symbols found)... (no debugging symbols found)... Program received signal SIGSEGV, Segmentation fault. 0xfd6922bc in ?? () from /home/jjones1/usr/mozilla-1.4/lib/mozilla-1.4/components/libimglib2.so (gdb) (gdb) quit The program is running. Quit anyway (and kill it)? (y or n) y
I took out this line during my configure: --enable-optimize='-O3 -mcpu=supersparc' \ and everything works now. Although, I do notice a loss in performance on my Sun-Sparc machine. Is there a way to make the optimize switch work with gcc-3.3.1 and mozilla-1.4?
Firebird build instructions recommend using O2 for a reason. If very agressive optimizations are used, stuff like that described in this bug happens. -> INVALID
Status: UNCONFIRMED → RESOLVED
Closed: 22 years ago
QA Contact: bugzilla
Resolution: --- → INVALID
Summary: Segfault in libimglib2 when modules/libpr0n compiled with -O{s,2,3} → Segfault in libimglib2 when modules/libpr0n compiled with -O{s,3}
QA Contact: bugzilla → build.config
Component: Build Config → General
Product: Firefox → Firefox Build System
You need to log in before you can comment on or make changes to this bug.