Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 181617 - dev-java/sun-jdk-1.6* and jrockit-jdk-bin-1.6* segfault with AWT_TOOLKIT=MToolkit
Summary: dev-java/sun-jdk-1.6* and jrockit-jdk-bin-1.6* segfault with AWT_TOOLKIT=MToo...
Status: RESOLVED DUPLICATE of bug 181854
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Java (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Java team
URL: http://bugs.sun.com/bugdatabase/view_...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-06-11 01:23 UTC by Volker Hemmann
Modified: 2010-03-09 18:31 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
the error log from sun's jdk (hs_err_pid17277.log,24.27 KB, text/plain)
2007-06-11 01:24 UTC, Volker Hemmann
Details
the jrockig jdk dump. (jrockit.16340.dump,8.73 KB, text/plain)
2007-06-11 01:25 UTC, Volker Hemmann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Volker Hemmann 2007-06-11 01:23:48 UTC
Hi,
With sun's jdk 1.6 or Bea's jrockit jdk 1.6 triplea - both installed via portage and the precompiled version - and another java app I use every day 'segfault'.

with sun's jdk 1.6.0.01:

#
# An unexpected error has been detected by Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x000000333242e5e4, pid=17277, tid=1076021568
#
# Java VM: Java HotSpot(TM) 64-Bit Server VM (1.6.0_01-b06 mixed mode)
# Problematic frame:
# C  [libc.so.6+0x2e5e4]  catgets+0x14
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
#

I have rebuilt glibc without any changes.


Reproducible: Always

Steps to Reproduce:
1.emerge any 1.6 jdk (64bit)
2.set the 1.6 as the user's vm
3. watch the fireworks

Actual Results:  
triplea and the other java-application (a chat client) crash

Expected Results:  
they should work - both do with sun's 1.5

Sun 32bit JRE 1.6.0.01 [emul-linux-x86-java-1.6] works 'fine' (I started to try different jdk because of a bug in triplea), without crashing.

My emerge --info:
emerge --info
Portage 2.1.2.9 (default-linux/amd64/2007.0, gcc-4.1.2, glibc-2.5-r3, 2.6.21.3cfsv16libatareiser4 x86_64)
=================================================================
System uname: 2.6.21.3cfsv16libatareiser4 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 4600+
Gentoo Base System release 1.12.10
Timestamp of tree: Sun, 10 Jun 2007 23:00:02 +0000
ccache version 2.4 [enabled]
dev-java/java-config: 1.3.7, 2.0.33-r1
dev-lang/python:     2.3.6-r2, 2.4.4-r4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r7
dev-util/confcache:  0.4.2-r1
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.17.50.0.16
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.23b
virtual/os-headers:  2.6.21
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -O2 -pipe -fweb -ftracer -fpeel-loops -msse3"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=k8 -O2 -pipe -fweb -ftracer -fpeel-loops -msse3"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig candy ccache distlocks metadata-transfer parallel-fetch sandbox sfperms strict"
GENTOO_MIRRORS="ftp://ftp.tu-clausthal.de/pub/linux/gentoo/"
LC_ALL="de_DE@euro"
LINGUAS="de"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage /usr/local/portage/gentoo-de"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext 7zip S3TC X Xaw3d a52 aac acpi addbookmarks aiglx aim aio akode alias alsa altenburgcards amarok amd64 aotuv aqua_theme asf athena audiofile autoreplace bash-completion berkdb binary-drivers bitmap-fonts bluetooth boost bzip2 cairo cdda cddb cdinstall cdparanoia cdr cdrom cdsound cegui cg clamav cli connectionstatus contactnotes cracklib crypt css cups curl dbus depth32 dhcp dio divx dnd double-precision dpms dri dts dv dvd dvdr dvdread emerald emul-linux-x86 encode exif expat exscalibar extra-cardsets fame fasttrack ffmpeg fftw filter_default filter_legacy filter_light flac foomaticdb fortran ftp gadu gdbm gif gimp gimpprint glitz glut glx gnokii gnutella gpgme gpm gtk gtk2 hddtemp highlight history iconv icq id3 imagemagick imlib inotify irc irmc isdnlog jabber java javascript jce jingle joystick jpeg jpeg2k kcal kde kdecards kdeenablefinal kdehiddenvisibility kdepim kdm kexi kipi kqemu lame lcms lesstif libg++ libwww lm_sensors logitech-mouse lzo lzw mad magic maps matroska midi mime mjpeg mmap mmx mmxext mng mp3 mp4 mpeg mpeg2 mplayer msn mudflap mule musepack ncurses neXt net newspr ngui nls no-old-linux nocd nosendmail nowin nowlistening nptl nptlonly nsplugin nvidia offensive ogg openexr opengl openmp oscar pam paste64 pch pcre pdf perl physfs player plugins png pnm posix ppds pppd python qt3 qt4 quicktime rar readline recode reflection reiser4 reiserfs remix resolvconf rogue rtc sametime scanner schedule scsi sdl sdl-sound sdlaudio sendfile server session sharedmem slp smp sms sndfile sockets sounds spell spl sqlite sqlite3 srt sse sse-filters sse2 sse3 ssl startup-notification statistics stats stencil-buffer stroke subp subtitles svg sysfs sysvipc szip tcpd texteffect textures tga theora threads tiff timidity tk toolbar tools transcode translator truetype truetype-fonts type1 type1-fonts unicode unzip usb userlocales utempter v4l v4l2 vcd videos visualization vorbis webdav webpresence wmf wmp wxwindows x264 xanim xcomposite xemacs xext xface xine xml xorg xosd xpm xrandr xscreensaver xskatcards xv xvid xvmc yiff yv12 zlib zvbi" ALSA_CARDS="emu10k1" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="de" USERLAND="GNU" VIDEO_CARDS="nvidia vesa vga v4l nv"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Volker Hemmann 2007-06-11 01:24:54 UTC
Created attachment 121715 [details]
the error log from sun's jdk
Comment 2 Volker Hemmann 2007-06-11 01:25:14 UTC
Created attachment 121716 [details]
the jrockig jdk dump.
Comment 3 Petteri Räty (RETIRED) gentoo-dev 2007-06-11 08:04:01 UTC
(In reply to comment #0)
> CFLAGS="-march=k8 -O2 -pipe -fweb -ftracer -fpeel-loops -msse3"

I am guessing this could be because of weird CFLAGS. They tend to cause segfaults in unexpected places. Someone on the amd64 team: Please try to verify.
Comment 4 Alistair Bush (RETIRED) gentoo-dev 2007-06-11 10:33:01 UTC
I agree,  after playing it for over 1/2 -1 hour without any sign of a crash.

Please reopen if you are still able to reproduce this after recompiling with 
sainer CFLAGS
Comment 5 Volker Hemmann 2007-06-11 12:37:41 UTC
recompiling WHAT?

triplea?

I have tried the binary version from sourceforge - and it crashes the same way the compiled one crashes.

glibc?
cat /var/db/pkg/sys-libs/glibc-2.5-r3/CFLAGS
-march=k8 -pipe -O2 -fno-strict-aliasing
Comment 6 Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2007-06-11 13:07:48 UTC
maybe motif? or any underlying X stuff? :)
Comment 7 Volker Hemmann 2007-06-11 13:16:57 UTC
a) I haven't motif installed.

b) shouldn't a problem in the X libs show up there? both sun's jdk and jrockit blame /lib/libc.so.6.
Comment 8 Petteri Räty (RETIRED) gentoo-dev 2007-06-11 14:52:31 UTC
(In reply to comment #7)
> a) I haven't motif installed.
> 
> b) shouldn't a problem in the X libs show up there? both sun's jdk and jrockit
> blame /lib/libc.so.6.
> 

emerge -e world at least makes sure everything is compiled with sane CFLAGS. You can also try setting LC_ALL to POSIX but I doubt this is caused by that.
Comment 9 Volker Hemmann 2007-06-11 16:07:03 UTC
Hi,

I rebuild everything in x11-* with O2 march=k8 -msse3 -pipe without a change.

I will rebuild the rest now.
Comment 10 Petteri Räty (RETIRED) gentoo-dev 2007-06-11 16:16:02 UTC
(In reply to comment #9)
> Hi,
> 
> I rebuild everything in x11-* with O2 march=k8 -msse3 -pipe without a change.
> 
> I will rebuild the rest now.
> 

-msse3 is something that will be enabled by -march if the processors supports it so why not just rely on that?
Comment 11 Volker Hemmann 2007-06-11 16:50:01 UTC
because the last couple of times I checked it, march=k8 did not include -msse3. And since my cpu does support msse3, I add it. If that has changed with the last gcc releases - great!
Comment 12 Petteri Räty (RETIRED) gentoo-dev 2007-06-11 17:25:08 UTC
(In reply to comment #11)
> because the last couple of times I checked it, march=k8 did not include -msse3.
> And since my cpu does support msse3, I add it. If that has changed with the
> last gcc releases - great!
> 

Ah yes it does seem the current stable gcc doesn't have march like this for our processor so it's probably coming in a later release etc (well there you have -march=native which is handy). From your uname AMD Athlon(tm) 64 X2 Dual Core I would say you should be using -O2 -march=athlon64 -msse3 -pipe but this is getting a bit off topic for discussion here. For further info come ask us on IRC in #gentoo-java or some other general Gentoo support channel.
Comment 13 Christoph Mende (RETIRED) gentoo-dev 2007-06-11 19:59:29 UTC
Just one side note for the CFLAGS here: -march={k8,athlon64,athlon-fx,opteron} are all the same, they don't and they will never include -msse3 since there are (older) Athlon64{,FX}/Opteron processors that don't support SSE3 :>
Comment 14 Volker Hemmann 2007-06-12 23:24:38 UTC
Hi,

I did an emerge -e world. The only things I did not rebuilt were sandbox, gimp and KDE.

Still crashes, with the same error.

h triplea_unix.sh
#
# An unexpected error has been detected by Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x00002b4580fa45e4, pid=4527, tid=1076017472
#
# Java VM: Java HotSpot(TM) 64-Bit Server VM (1.6.0_01-b06 mixed mode)
# Problematic frame:
# C  [libc.so.6+0x2e5e4]  catgets+0x14
#
# An error report file with more information is saved as hs_err_pid4527.log
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
#
triplea_unix.sh: line 12:  4527 Abgebrochen             java -Xmx128m -cp bin/patch.jar:bin/triplea.jar games.strategy.engine.framework.GameRunner

emerge --info
Portage 2.1.2.9 (default-linux/amd64/2007.0, gcc-4.1.2, glibc-2.5-r3, 2.6.21.3cfsv16libatareiser4 x86_64)
=================================================================
System uname: 2.6.21.3cfsv16libatareiser4 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 4600+
Gentoo Base System release 1.12.10
Timestamp of tree: Sun, 10 Jun 2007 23:00:02 +0000
ccache version 2.4 [enabled]
dev-java/java-config: 1.3.7, 2.0.33-r1
dev-lang/python:     2.3.6-r2, 2.4.4-r4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r7
dev-util/confcache:  0.4.2-r1
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.17.50.0.16
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.23b
virtual/os-headers:  2.6.21
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -O2 -msse3 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=k8 -O2 -msse3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig candy ccache distlocks metadata-transfer parallel-fetch sandbox sfperms strict"
GENTOO_MIRRORS="ftp://ftp.tu-clausthal.de/pub/linux/gentoo/"
LC_ALL="de_DE@euro"
LINGUAS="de"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage /usr/local/portage/gentoo-de"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext 7zip S3TC X Xaw3d a52 aac acpi addbookmarks aiglx aim aio akode alias alsa altenburgcards amarok amd64 aotuv aqua_theme asf athena audiofile autoreplace bash-completion berkdb binary-drivers bitmap-fonts bluetooth boost bzip2 cairo cdda cddb cdinstall cdparanoia cdr cdrom cdsound cegui cg clamav cli connectionstatus contactnotes cracklib crypt css cups curl dbus depth32 dhcp dio divx dnd double-precision dpms dri dts dv dvd dvdr dvdread emerald emul-linux-x86 encode exif expat exscalibar extra-cardsets fame fasttrack ffmpeg fftw filter_default filter_legacy filter_light flac foomaticdb fortran ftp gadu gdbm gif gimp gimpprint glitz glut glx gnokii gnutella gpgme gpm gtk gtk2 hddtemp highlight history iconv icq id3 imagemagick imlib inotify irc irmc isdnlog jabber java javascript jce jingle joystick jpeg jpeg2k kcal kde kdecards kdeenablefinal kdehiddenvisibility kdepim kdm kexi kipi kqemu lame lcms lesstif libg++ libwww lm_sensors logitech-mouse lzo lzw mad magic maps matroska midi mime mjpeg mmap mmx mmxext mng mp3 mp4 mpeg mpeg2 mplayer msn mudflap mule musepack ncurses neXt net newspr ngui nls no-old-linux nocd nosendmail nowin nowlistening nptl nptlonly nsplugin nvidia offensive ogg openexr opengl openmp oscar pam paste64 pch pcre pdf perl physfs player plugins png pnm posix ppds pppd python qt3 qt4 quicktime rar readline recode reflection reiser4 reiserfs remix resolvconf rogue rtc sametime scanner schedule scsi sdl sdl-sound sdlaudio sendfile server session sharedmem slp smp sms sndfile sockets sounds spell spl sqlite sqlite3 srt sse sse-filters sse2 sse3 ssl startup-notification statistics stats stencil-buffer stroke subp subtitles svg sysfs sysvipc szip tcpd texteffect textures tga theora threads tiff timidity tk toolbar tools transcode translator truetype truetype-fonts type1 type1-fonts unicode unzip usb userlocales utempter v4l v4l2 vcd videos visualization vorbis webdav webpresence wmf wmp wxwindows x264 xanim xcomposite xemacs xext xface xine xml xorg xosd xpm xrandr xscreensaver xskatcards xv xvid xvmc yiff yv12 zlib zvbi" ALSA_CARDS="emu10k1" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="de" USERLAND="GNU" VIDEO_CARDS="nvidia vesa vga v4l nv"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

Comment 15 Volker Hemmann 2007-06-13 20:54:51 UTC
Hi,

the cause was the same as in #181854:
AWT_TOOLKIT=MToolkit

without it, the segfault is gone.

Please accept my apology for wasting your time.
Comment 16 Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2007-06-13 20:57:38 UTC
Ha ha was just going to ask.
We should ask emerge --verbose --info always in the future
Comment 17 Petteri Räty (RETIRED) gentoo-dev 2007-06-13 21:01:18 UTC
(In reply to comment #16)
> Ha ha was just going to ask.
> We should ask emerge --verbose --info always in the future
> 

reopening until we decide if we should support Motif or not
Comment 18 Volker Hemmann 2007-06-15 16:21:35 UTC
I opened a bug at bugs.sun.com about it here:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6570063
Comment 19 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2008-12-08 02:33:01 UTC
This bug has been opened and closed so many times and I read through the whole thing and don't exactly see anything for the amd64 team to confirm anymore (comment #9). Feel free to add amd64@g.o back if you need any thing else. Thanks.
Comment 20 Alistair Bush (RETIRED) gentoo-dev 2010-03-09 18:31:08 UTC
Lets consolidate this bug into only 1.

*** This bug has been marked as a duplicate of bug 181854 ***