Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 277107 - dev-java/sun-jre-bin (?): Sun Java VM crashes with sys-libs/glibc-2.10.1
Summary: dev-java/sun-jre-bin (?): Sun Java VM crashes with sys-libs/glibc-2.10.1
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High major (vote)
Assignee: Java team
Depends on:
Blocks: glibc-2.10
  Show dependency tree
Reported: 2009-07-08 21:48 UTC by Matt Whitlock
Modified: 2009-08-24 20:44 UTC (History)
1 user (show)

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


Note You need to log in before you can comment on or make changes to this bug.
Description Matt Whitlock 2009-07-08 21:48:04 UTC
Sun's JVM regularly crashes inside from sys-libs/glibc-2.10.1.

# A fatal error has been detected by the Java Runtime Environment:
#  SIGSEGV (0xb) at pc=0x00007f1fccdb0170, pid=2896, tid=139773682403600
# JRE version: 6.0_14-b08
# Java VM: Java HotSpot(TM) 64-Bit Server VM (14.0-b16 mixed mode linux-amd64 )
# Problematic frame:
# C  []

Disassembling with objdump shows that offset 0x74170 is a mov instruction within the malloc_usable_size function.

There is no set sequence of steps that reproduces this crash, but it happens pretty often whether I'm using Eclipse or compiling a project with Maven in a terminal.

I compiled glibc with debugging information (-ggdb), but I don't know how to translate an offset into a source file and line number.  If someone could tell me the commands to use, I could provide this information.
Comment 1 Matt Whitlock 2009-07-10 10:48:13 UTC
A friend told me how to get the file name and line number from the offset, so here it is:

$ addr2line -e /usr/lib/debug/lib64/ 0x74170

Here's my emerge --info if it helps:

Portage 2.2_rc33 (default/linux/amd64/2008.0/no-multilib, gcc-4.3.3, glibc-2.10.1-r0, 2.6.29-gentoo-r5 x86_64)
System uname: Linux-2.6.29-gentoo-r5-x86_64-Intel-R-_Core-TM-2_Quad_CPU_Q6600_@_2.40GHz-with-gentoo-2.0.1     
Timestamp of tree: Fri, 10 Jul 2009 10:00:19 +0000                                                            
app-shells/bash:     4.0_p24                                                                                  
dev-java/java-config: 2.1.8-r1                                                                                
dev-lang/python:     2.6.2-r1                                                                                 
dev-util/cmake:      2.6.4                                                                                    
sys-apps/baselayout: 2.0.1                                                                                    
sys-apps/openrc:     0.4.3-r3                                                                                 
sys-apps/sandbox:    2.0                                                                                      
sys-devel/autoconf:  2.13, 2.63-r1                                                                            
sys-devel/automake:  1.7.9-r1, 1.9.6-r2, 1.10.2, 1.11                                                         
sys-devel/binutils:  2.19.1-r1                                                                                
sys-devel/gcc-config: 1.4.1                                                                                   
sys-devel/libtool:   2.2.6a                                                                                   
virtual/os-headers:  2.6.30                                                                                   
ACCEPT_KEYWORDS="amd64 ~amd64"                                                                                
CFLAGS="-march=native -O3 -ggdb -pipe"                                                                        
CONFIG_PROTECT="/etc /usr/share/config"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dbus-1 /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/init.d /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=native -O3 -ggdb -pipe"
FEATURES="distlocks fixpackages parallel-fetch preserve-libs protect-owned sandbox sfperms splitdebug strict unmerge-orphans userfetch"
LINGUAS="en_US en"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTDIR_OVERLAY="/usr/local/portage/layman/java-overlay /usr/local/portage/layman/lcd-filtering /usr/local/portage/layman/sunrise /usr/local/portage/layman/kde-testing /usr/local/portage/overlay"
USE="X a52 aac acpi alsa amd64 berkdb bzip2 cairo cdparanoia cli cracklib crypt cups curl dbus dri dvd dvdr dvdread encode fam ffmpeg flac gdbm geoip gif gstreamer gtk hal iconv isdnlog java java5 java6 jpeg kde lame lirc mad matroska midi mjpeg mmx mmxext mng mp3 mpeg mudflap mysql ncurses nptl nptlonly nsplugin ogg opengl openmp pcre pdf perl phonon php png ppds pppd python qt4 quicktime rdesktop readline reflection sdl session spell spl sse sse2 ssl ssse3 startup-notification subversion svg sysfs theora threads tiff truetype unicode usb vdpau vnc vorbis webkit x264 xcb xcomposite xml xorg xv xvid yahoo zlib" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_US en" LIRC_DEVICES="mceusb2" USERLAND="GNU" VIDEO_CARDS="nvidia"
Comment 2 Matt Whitlock 2009-07-15 06:16:29 UTC
Actually I'm using the JVM from dev-java/sun-jdk, but I would expect this problem to afflict dev-java/sun-jre-bin as well.
Comment 3 Arttu Valo 2009-08-13 00:05:41 UTC
Latest stable sun-jdk is (stabilized just the other day for amd64), you were running Maybe you can try the newest one?

Also, is -O3 considered a sane optimization these days?

"Using -O3 is not recommended for gcc 4.x."
Comment 4 Matt Whitlock 2009-08-13 01:27:02 UTC
(In reply to comment #3)
> Latest stable sun-jdk is (stabilized just the other day for amd64),
> you were running Maybe you can try the newest one?

I'm running now, and I haven't seen this crash since upgrading.

> Also, is -O3 considered a sane optimization these days?

Computers only do what you tell them to.  The trouble with -O3 is that many programmers don't understand what they're telling the computer to do.  If you program correctly, -O3 is perfectly safe.  If you make assumptions (for instance, about execution order or memory consistency) that are not strictly guaranteed by the programming language, -O3 will burn you.  I assume my fellow programmers are competent until they prove themselves otherwise.
Comment 5 Petteri Räty (RETIRED) gentoo-dev 2009-08-24 20:44:01 UTC
(In reply to comment #4)
> (In reply to comment #3)
> > Latest stable sun-jdk is (stabilized just the other day for amd64),
> > you were running Maybe you can try the newest one?
> I'm running now, and I haven't seen this crash since upgrading.

Assuming this to be fixed by then. Thanks for testing and reporting. Please reopen if you see it again.