Bug 3386 - sigsegv in r200 when glXCreateContext called by JOGL (Java for OpenGL)
Summary: sigsegv in r200 when glXCreateContext called by JOGL (Java for OpenGL)
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Radeon (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: high normal
Assignee: Default DRI bug account
QA Contact:
Depends on:
Reported: 2005-05-24 01:23 UTC by Nik
Modified: 2010-12-02 20:18 UTC (History)
0 users

See Also:
i915 platform:
i915 features:

java JVM-generated crash log (17.46 KB, text/plain)
2005-05-24 01:24 UTC, Nik
no flags Details

Description Nik 2005-05-24 01:23:14 UTC
I am encountering segsegv application crashes when I run the JOGL (Java for
OpenGL) demo TestContextDestruction.

updated (with YUM) Fedora Core 3 (kernel 2.6.11-1.14_FC3)
Xorg 6.8.2 (release date 9 February 2005)
radeon 4.0.1, ati 6.5.6, 
drm 1.0.0 20040925.
Java: build 1.5.0_01-b08 (www.java.sun.com)
JOGL: binary build, 1.1b11 (May 11, 2005)

DELL latitude D600 notebook with an ATI Mobility 9000 (M9) graphics card

I have a 100% reproducable testcase:
If I run the JOGL demo program TestContextDestruction, a sigsegv is thrown,
ironically in xGLCreateContext(). The TestContextDestruction demo can be
downloaded in the jogl-demos.jar download on the same page as the jogl
installation, or can be individually downloaded (single java file) from the jogl
project CVS.

I have also submitted a bug report to the JOGL project, but their belief is that
this is most likely a DRI r200 problem. Their response included: "JOGL stresses
the multithreading support of the driver more than most C applications."

To reproduce the crash, a java VM needs to be installed (I have 1.5) and the
JOGL libraries (1 java - jogl.jar, and 2 native libjogl.so, libjogl_cg.so) must
be installed as well (usually in <path-to-java>/jre/lib/ext (for jogl.jar) and
<path-to-java>/jre/lib/i386 (for jogl*.so)).

1a. If the demos are downloaded in binary form extract the jogl-demos.jar file
using "jar xvf jogl-demos.jar".

1b. If the source file was downloaded (say from CVS) then compile it using:
"javac -classpath .:<path-to->/jogl.jar -d . TestContextDestruction.java

2. run the program: "java demos.testContextDestruction.TestContextDestruction"
3. click on the "swap frame 1's and frame2's components" button twice.

The screen shows a summary of the crash, and names the log file (created in the
current directory) containing further information.

I am happy to provide any further information required.

The initial lines of the Java JVM-generated stack trace are included here, and I
will attach the entire file to this report.

# An unexpected error has been detected by HotSpot Virtual Machine:
#  SIGSEGV (0xb) at pc=0xa7e7d0be, pid=2476, tid=2773232560
# Java VM: Java HotSpot(TM) Client VM (1.5.0_01-b08 mixed mode)
# Problematic frame:
# C  [r200_dri.so+0x14d0be]

---------------  T H R E A D  ---------------

Current thread (0x0842d778):  JavaThread "AWT-EventQueue-0" [_thread_in_native,

siginfo:si_signo=11, si_errno=0, si_code=1, si_addr=0x00000050

EAX=0x00000000, EBX=0x084544d8, ECX=0x084544d8, EDX=0x085f41e0
ESP=0xa54c1924, EBP=0xa54c194c, ESI=0x08451ed8, EDI=0xa54c1938
EIP=0xa7e7d0be, CR2=0x00000050, EFLAGS=0x00010202

Top of Stack: (sp=0xa54c1924)
0xa54c1924:   084544d8 a54c1938 a54c193c 00000000
0xa54c1934:   005daf01 02c00011 085f41e0 08454418
0xa54c1944:   08451ed8 084889cc a54c197c a7e7dc11
0xa54c1954:   08453a50 08451ed8 00000000 08451ed8
0xa54c1964:   08451edc 00001000 00000000 084889cc
0xa54c1974:   084884c0 08453650 a54c19bc 00b563a2
0xa54c1984:   081b69e8 08453a50 00000000 00000000
0xa54c1994:   084889cc a54c19bc 08453a50 8fbcc5a8

Instructions: (pc=0xa7e7d0be)
0xa7e7d0ae:   e8 f2 0f ee ff 85 c0 2e 74 a3 8b 45 f0 8b 40 08
0xa7e7d0be:   8b 40 50 8b 30 8b 45 ec 89 44 24 04 89 34 24 ff

Stack: [0xa5442000,0xa54c3000),  sp=0xa54c1924,  free space=510k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [r200_dri.so+0x14d0be]
C  [r200_dri.so+0x14dc11]
C  [libGL.so.1+0x4a3a2]
C  [libGL.so.1+0x4a7e7]  glXCreateContext+0x3e
C  [libjogl.so+0xc09a2] Java_net_java_games_jogl_impl_x11_GLX_glXCreateContext0
j net.java.games.jogl.impl.x11.GLX.glXCreateContext0(JLjava/nio/Buffer;JZ)J+0
j net.java.games.jogl.impl.x11.GLX.glXCreateContext(JLnet/java/games/jogl/impl/
j net.java.games.jogl.impl.x11.X11GLContext.createContext(Lnet/java/games/jogl/
j net.java.games.jogl.impl.x11.X11GLContext.chooseVisualAndCreateContext(Z)V+9
j  net.java.games.jogl.impl.x11.X11OnscreenGLContext.create()V+2
J net.java.games.jogl.impl.x11.X11GLContext.makeCurrent(Ljava/lang/Runnable;)Z
J net.java.games.jogl.impl.x11.X11OnscreenGLContext.makeCurrent(Ljava/lang/Runn
J net.java.games.jogl.impl.GLContext.invokeGL(Ljava/lang/Runnable;ZLjava/lang/R
Comment 1 Nik 2005-05-24 01:24:20 UTC
Created attachment 2759 [details]
java JVM-generated crash log

This is the complete crash log file, as generated by the java JVM.
Comment 2 Jerome Glisse 2009-05-18 13:01:18 UTC
Do you still have this issue with recent mesa ?
Comment 3 Matt Turner 2010-12-02 20:18:30 UTC
Closing due to inactivity. Reopen if this is still a problem.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.