NullOOJavaAI crash on exit on my windows box, probably related to the 64bit jvm.
java exact version is 6.0.230.5; spectating two RAI matches doesn't give any problem; spectating a RAI vs NullOOJavaAI game grashes on exit.
infolog doesn't give any hints. can't try with a 32bit jvm right now.
anyone got it running on a 64bit windows env?
NullOOJavaAI crashes on exit
Moderators: hoijui, Moderators
NullOOJavaAI crashes on exit
- Attachments
-
- script-ai.txt
- (1.22 KiB) Downloaded 105 times
-
- infolog.txt
- (23.55 KiB) Downloaded 115 times
Re: NullOOJavaAI crashes on exit
32bit spring + 64bit JVM, you can run a 32bit and a 64bit alongside eachother, but unless you can rebuild spring in 64bit your going to have to use 32bit
Re: NullOOJavaAI crashes on exit
the weird thing is that it runs just fine, until the game ends 

Re: NullOOJavaAI crashes on exit
on crash reports, you always include infolog.txt, even if it misses a stack-trace. you ask someone that (you hope) might know more about what is going wrong, and they might see hints in the logs that are none in your eyes. I would also not have to ask for stuff like which OS, GFX card or spring version you were using.
Re: NullOOJavaAI crashes on exit
no, you wouldn't need to ask, because everything is included in the infolog that's already attached to the first post to begin with.hoijui wrote:on crash reports, you always include infolog.txt, even if it misses a stack-trace. you ask someone that (you hope) might know more about what is going wrong, and they might see hints in the logs that are none in your eyes. I would also not have to ask for stuff like which OS, GFX card or spring version you were using.
seriously, I don't get it, is this genuine hate toward me, toward bug reports or just generic aimless hatred?
I understand the need of a copypasta post as a standard reply to reports, still..
Re: NullOOJavaAI crashes on exit
.. i missed it, sorry
Re: NullOOJavaAI crashes on exit
...in that case, sorry for the harsh reply
friends?
friends?

Re: NullOOJavaAI crashes on exit
sure :D
really can't imagine how i missed it. this is like the first time i missed something.. EVER!
(except every possible off-by-one error, and some others)
it was not a copy paste answer btw. was made just for you! :D
next two paragraphs are here mostly as reference to self, about stuff that is known but unfixed since some time
it could be that it crashes cause the JVM is not properly shut down.
The reason for this is, that the Java AI Interface plugin, when shut down, does not know whether it is shut down cause the last Java AI died, or whether the simulation/game has ended, so can not kill the JVM. It is possible to instantiate and kill AIs during runtime of a game. The JVM though, can only be started once per process. once it is shut down, you are not able to start it again, ever, for that process.
So in short, we would need to alter something in the way interface plugins are handled, basically there are two solutions:
Here the cleanest solution we came up with so far, would be to pre-allocate enough memory early in initialization of the game, and release it right before the plugin gets initialized. the size of the memory to reserve could be specified by an entry in AIInfo.lua.
maybe the interfaces log file contains some info.
really can't imagine how i missed it. this is like the first time i missed something.. EVER!

(except every possible off-by-one error, and some others)
it was not a copy paste answer btw. was made just for you! :D
next two paragraphs are here mostly as reference to self, about stuff that is known but unfixed since some time
it could be that it crashes cause the JVM is not properly shut down.
The reason for this is, that the Java AI Interface plugin, when shut down, does not know whether it is shut down cause the last Java AI died, or whether the simulation/game has ended, so can not kill the JVM. It is possible to instantiate and kill AIs during runtime of a game. The JVM though, can only be started once per process. once it is shut down, you are not able to start it again, ever, for that process.
So in short, we would need to alter something in the way interface plugins are handled, basically there are two solutions:
- do not shut down AI Interface plugins, once started, until the game ends
- add one or two new functions to the AI Interface API, which are called (at first instantiation &) at game end
Here the cleanest solution we came up with so far, would be to pre-allocate enough memory early in initialization of the game, and release it right before the plugin gets initialized. the size of the memory to reserve could be specified by an entry in AIInfo.lua.
maybe the interfaces log file contains some info.
Re: NullOOJavaAI crashes on exit
I've tried to debug the exit but I'm twice retarded:
A) first retarded award because I got a source snapshot instead of fetching the master from git, so it took an awful lot of time to get to a point where the java wrapper was not compiled and not compiling, thanks to award B
B) I insisted in using netbeans for c++, which is slow as hell, because it has to index everything every time config changes, and then, because it want me to use unix makefiles. it also has a nice popup telling me that mingw makefiles are not what I want and that mingw make is not posix compliant so I cannot use that. A lot of messing later and thanks to cmake-gui I convinced it to use the damned mingw environment but only for the main project, the other makefiles are executed with standard make which is not happy about them
I've got a visual studio 2010 and git, I'll give it another shot in the next days.
A) first retarded award because I got a source snapshot instead of fetching the master from git, so it took an awful lot of time to get to a point where the java wrapper was not compiled and not compiling, thanks to award B
B) I insisted in using netbeans for c++, which is slow as hell, because it has to index everything every time config changes, and then, because it want me to use unix makefiles. it also has a nice popup telling me that mingw makefiles are not what I want and that mingw make is not posix compliant so I cannot use that. A lot of messing later and thanks to cmake-gui I convinced it to use the damned mingw environment but only for the main project, the other makefiles are executed with standard make which is not happy about them
I've got a visual studio 2010 and git, I'll give it another shot in the next days.
Re: NullOOJavaAI crashes on exit
yeah... i can imagine you would have problems with many IDEs. i have them too (with C++).
i would recommend you to use the IDE only as a sort of better source file editor, and do the compiling in the command line.
MSVC should work to of course, but there is only one person maintaining that (zerver) and so it might often be broken for a few commits.
i would recommend you to use the IDE only as a sort of better source file editor, and do the compiling in the command line.
MSVC should work to of course, but there is only one person maintaining that (zerver) and so it might often be broken for a few commits.
Re: NullOOJavaAI crashes on exit
I was looking at an ide mostly for debugging, I can't stand gdb.
As long as the project definition is almost working I can fix it up myself, hopefully :)
As long as the project definition is almost working I can fix it up myself, hopefully :)
Re: NullOOJavaAI crashes on exit
I had problems myself with Win 7 64 bit. What I ended up doing was installing 32 bit JVM.
You appear to have a different error than me, but perhaps this might be useful:
http://springrts.com/phpbb/viewtopic.php?f=15&t=25964
You appear to have a different error than me, but perhaps this might be useful:
http://springrts.com/phpbb/viewtopic.php?f=15&t=25964