JVM crashing with nvidia drivers.

hello, my jogl application seems to crash the VM randomly, at about 10 seconds to 2 minutes after startup.


     [java] # An unexpected error has been detected by HotSpot Virtual Machine:
     [java] #
     [java] #  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x6968aef9, pid=2604, tid=3764
     [java] #
     [java] # Java VM: Java HotSpot(TM) Client VM (1.5.0_06-b05 mixed mode, sharing)
     [java] # Problematic frame:
     [java] # C  [nvoglnt.dll+0x18aef9]
     [java] #
     [java] # An error report file with more information is saved as hs_err_pid2604.log
     [java] #
     [java] # If you would like to submit a bug report, please visit:
     [java] #   http://java.sun.com/webapps/bugreport/crash.jsp

now, is this something wrong with my code or could this be a bug in the nvidia driver dll?

the graphics card is an Nvidia GF 7300LE.
driver version: 84.21
(i know they have newer drivers, but these dont seem to work at all for my machine :/)

thanks.

If you look at the error log it will tell you what call actually dropped the JVM. I doubt that it is the drivers. You probably forgot to rewind a buffer.

ok, this is from the call:


Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  com.sun.opengl.impl.windows.WGL.wglMakeCurrent(JJ)Z+0
j  com.sun.opengl.impl.windows.WindowsGLContext.releaseImpl()V+8
j  com.sun.opengl.impl.windows.WindowsOnscreenGLContext.releaseImpl()V+1
j  com.sun.opengl.impl.GLContextImpl.release()V+25
j  com.sun.opengl.impl.GLDrawableHelper.invokeGL(Ljavax/media/opengl/GLDrawable;Ljavax/media/opengl/GLContext;Ljava/lang/Runnable;Ljava/lang/Runnable;)V+462
j  javax.media.opengl.GLCanvas$DisplayOnEventDispatchThreadAction.run()V+35
j  java.awt.event.InvocationEvent.dispatch()V+11
j  java.awt.EventQueue.dispatchEvent(Ljava/awt/AWTEvent;)V+26
j  java.awt.EventDispatchThread.pumpOneEventForHierarchy(ILjava/awt/Component;)Z+233
j  java.awt.EventDispatchThread.pumpEventsForHierarchy(ILjava/awt/Conditional;Ljava/awt/Component;)V+26
j  java.awt.EventDispatchThread.pumpEvents(ILjava/awt/Conditional;)V+4
j  java.awt.EventDispatchThread.pumpEvents(Ljava/awt/Conditional;)V+3
j  java.awt.EventDispatchThread.run()V+9
v  ~StubRoutines::call_stub

still i think it’s the drivers being corrupt or something, because my co-workers who have the exact same graphics card+ driver version do not experience the crash.

Yeah you probably need to uninstall your display drivers, reboot, run driver cleaner, and install 91.31.

Well this is funny… we’ve lately had a few VM crashes at WGL.wglMakeCurrent(), although they are extremely rare and hard to reproduce. We use JSR-231 beta 5. I’m pretty sure we never had these crashes with beta 4!
???

Crash reproduced on two machines, one running 81.67 the other one 84.26 (both WHQL certified for Quadro boards). What makes you certain that 91.31 will fix this?

Identical machines, one works the otherdoesn’t, probably means the drivers aremessed up. Or perhaps one machine has an older version of jogl in theclass path somewhere. It is just a guess. If you, mabraham, can manage to create a small test case that you can post in the bug tracker I bet that Ken would be able to track down the problem pretty quick.

Yes, please provide a test case if you can make one which reproduces the crashes. I won’t take GKW’s bet on my ability to quickly track down the problem :-), but can certainly try to reproduce and look into it. I don’t think there were any changes in beta 5 that weren’t in beta 4 which would have destabilized things in this area. Beta 4 did have some pretty large-scale changes, though.

The two machines where this crash was seen are markedly different; one runs WinXP x64 the other runs WinXP 32-bit Professional. I don’t think the drivers are “messed up”, to be frank.

I wish I could reproduce this crash easily. I know this sort of problem report is useless, but there’s nothing I can do at this time. I’ll let you know if anything happens…

M.

Well it turns out that driver version 91.31 indeed fixes the problem (at least in our case)! It’s really odd though; I had isolated the problem to occur only when the views in our application had their text overlays enabled. We draw text using textured quads in immediate mode - I went through that code over and over again and could see no problem with it.

On a side note, using DebugGL causes quite a significant slowdown of our text renderer (one order of magnitude, for ~1,000 textured quads). The slowdown is more pronounced on my PC whereas on a laptop with an ATI Mobility Radeon I could see virtually no performance loss. Any thoughts on that?

It sounds like something in NVidia’s drivers is causing glGetError() calls to become extremely expensive. The DebugGL isn’t allowed to call glGetError() between glBegin/glEnd() pairs so basically every glEnd() call has a glGetError() associated with it. You might want to report this performance loss with NVidia.

What’s the best way to go about this, I wonder. I can’t seem to find an email address on their website, and I think their forums are pretty useless. Might try opengl.org

Go to developer.nvidia.com and click the “join” link under “registered developers” on the left-hand side of the page. Keep in mind I’ve never had any apparent success in having bugs fixed which I’ve reported, but as far as I know that’s the best way to file them if you don’t have a direct contact to the OpenGL driver team (which I don’t).