strange crash

I’ve been writing a lot of lwjgl code recently (opengl/openal) and everything works fine on my computer as well as the rest of the computers in my household (including a crappy laptop with intel integrated graphics), even got openal working on the laptop ;D I have the latest nvidia drivers on my computer and fairly recent drivers on the other computers. However my friend tried it with his geforce 4 (6.1.4.something driver version) and it runs for a few seconds and then crashes with no output, windows shows a dialog saying java.exe crashed. I tried on my school’s computers which have geforce2 32 meg cards with the same driver version as my friend, same crash, no output whatsoever. I can’t seem to figure out what could cause this, the program runs normally, nothing changes (no user interaction or anything), and then it crashes after 15 seconds or so. This happens after all textures are loaded and sounds have been initialized, the program is just a demo with some lights and sprites bouncing around, as I mentioned before nothing in the program changes before the crash.

I suppose the next thing to do is have my friend update his drivers, that will tell me if its an opengl thing or not, but I really have no idea where to go from there with no output. Any ideas about what could cause a crash like this? Any suggestions about what I need to do to solve this problem? If someone would like to try the demo and see the crash for themselves, please let me know! I’m lost, thanks for any help :-/

its the java version thats the problem IIRC (same thing happened with me).

I take it the JVM that are causing the crashes are 1.4.2_05/06 or 07? Downgrading to 1.4.2_04 or upgrading to 1.5_02 seems to solve the problem.

DP

I believe the two crashes were on 1.5_01 and 1.4.1_something… I’m running it just fine with 1.4.2_07 and 6.0 here.

my friend upgraded his drivers and the program crashes the same, so I guess you could be right about the jvm version thing but he is using 1.5.0_01… If its not that then its probably OpenAL. Any word from lwjgl people? do you know about this and will there be a fix? Heres the program, its in the .zip/run.bat format: http://www.cyntaks.com/projects/wjge2/WJGE2_Demo.zip

If you can get it to crash, please give me some info about your system so I can try to figure out whats causing this!

if it actually works on your computer and you want to view the rest of the demo, check out controls.txt.

[quote]Any word from lwjgl people? do you know about this and will there be a fix?
[/quote]
::slight_smile:
Since there is no specific bug here, then it’s hard to know if its a lwjgl error or a user error. fwiw, runs fine on my Radeon/JDK1.5.0

ah yeah sorry about that, guess I was jumping to conclusions after hearing about someone else having a similar problem :-[ can anyone confirm my theory that it is indeed a problem in native code that would result in a crash like this (whether its my improper use of it or otherwise)? Anyone know what kinda of problem could generate the java.exe has crashed windows dialog?

edit: also, its only crashed on nvida cards so far :frowning: (although for all I know, it could be a problem with their audio drivers/card…)

Works fine:

P4 2.4GHz (@1.8GHz)
512MB ram
ATi Radeon 9700pro
Budget 5.1 soundcard (I hear it)
Windows XP
90fps

I installed OpenAL on my machine, ages ago… maybe
that’s the problem, let them download the OpenAL
drivers, for me they didn’t come with my PC/OS.

on my system: start -> screen: switch to demo resoulution -> screen: switch back *

thats all

no output on screen, nor on cosole. last echo is the java.exe command itself.

WinXP, Athlon, Geforce2, SoundBlaster PCI

hmm, that sounds like the other crashes in that there is no output at all, just ends… I still see nothing in common with the systems except that they all use nvidia cards… but I really don’t think thats it since I’m also on an nvidia and my friend with the geforce 4 updated his drivers and it still crashes, plus I’ve run it on another computer with a geforce 4 and its fine on there. ???

I have a similar problem on a Win2K/GF4TI box (was a GF4MX before with same problem). Sometimes LWJGL stuff works, sometimes it works for some seconds, starts to show wired polygons and crashes. It works fine if i start any other OpenGL application before. Don’t know why but i don’t care much either.

made some progress: I disabled all audio, I don’t even initialize OpenAL, and… it works. So now I just have to look through all my audio code and see what could be causing the crash. My guess would be that it has something to do with the streaming audio… ugh, looks like more testing with no output (and I don’t own a computer that will crash it). Also, OpenAL says there is no error (I check during every frame). Does anyone know of something I could do in OpenAL that would cause a crash like this (crashes after a small period of time passes, so it sounds like something is accumulating to cause the crash…)? I’ll continue looking and share the solution if I find it…

Hello together,

I have the same OpenAL problem with Jake2.
You can run the game via webstart.
http://www.bytonic.de/html/jake2_webstart.html
(version 0.95 of lwjgl)

It works fine with sound off. The OpenAL implementation crashes the JVM on Win2k and WinXP. It happens after 1-2 Quake2 demo runs. On Linux there is no problem.

I don’t know why because the joal implementation is nearly the same source code and works without problems. Thats why I think it isn’t a driver problem. I am not sure but it is possible that something goes wrong in the lwjgl native code (OpenAL Win32).

Any ideas? Or can someone check it out, please?

bye
Carsten

I’ve just been playing about with openal for the first time and it seems to be working ok, besides one huge conflict problem. If I’m using openal and I’ve got Reason (music app) open I get a blue screen of death with this message:

DRIVER_IRQL_NOT_LESS_OR_EQUAL
Blah, blah, please reset your computer…

That’s on winxp with a creative Audigy card.

Not nice, but it could be a problem with Reason and I’ve learnt to close Reason if I’m using openal on the pc. I get the same problem if I try the superdudster demo when Reason is open. I haven’t tried it on the mac yet but I’ll give it a go tomorrow. Also, noticed the sound in superdudster gets very crackly when lots of bat guys are exploding, I can’t remember thisbeing a problem in the older versions I tried.

[quote]Any ideas? Or can someone check it out, please?
[/quote]
It does sound a bit weird. What’s in the error log?
The best thing you can do, is to track down what happens around the stacktrace (if any), or at least at the end of level code. It sounds like a mismanaged buffer, but this usually doesn’t crash OAL code, but rather OGL.

You could try to contact me on mail, and we can try and work together on this, I would however prefer not to get too intimately involved in the jake2 source code.

[quote]I’ve just been playing about with openal for the first time and it seems to be working ok, besides one huge conflict problem. If I’m using openal and I’ve got Reason (music app) open I get a blue screen of death with this message:

DRIVER_IRQL_NOT_LESS_OR_EQUAL
Blah, blah, please reset your computer…

That’s on winxp with a creative Audigy card.

Not nice, but it could be a problem with Reason and I’ve learnt to close Reason if I’m using openal on the pc. I get the same problem if I try the superdudster demo when Reason is open. I haven’t tried it on the mac yet but I’ll give it a go tomorrow. Also, noticed the sound in superdudster gets very crackly when lots of bat guys are exploding, I can’t remember thisbeing a problem in the older versions I tried.
[/quote]
Is this with ANY OpenAL app AND with a LWJGL app ?

Sorry, I should have checked more before posting, just updated my sound drivers and that seems to have fixed it.

Hi Brian

Yes, it is weird. There is no error log nor a stacktrace.

Thank you very much for your suggestion. I will contact you soon. During the next weeks I will make some tests to track the problem down.

bye
Carsten

Hi Brian,

I have found the bug. It was a “mismanaged” buffer problem :wink:
The error (access violation) occurs on loading a buffer with new sample data every time.


AL10.alBufferData(bufferId, format, data, freq);

I think the problem was that this data upload was done on playing the buffers old content.
I had forgotten to check that the buffer is filled only once.
BTW: The joal implementation for jake2 had the same upload problem, but this binding could handle the asynchronous buffer modification.

bye
Carsten