Reputation: 23498
Ok so I built a jar (it loads an applet into a JFrame) using x64 JDK. I was able to run the jar just fine using x32 Jre/JDK. However, when I close the application, the JVM crashes with error code: 255.
If I run the x64 Jar using x64 Jre/JDK, it does not crash the JVM upon close; exits with error code: 0.
Question: What possible reasons would it crash the JVM for? AFAIK, it should be architecture independent or platform independent :S. Also, would it crash if I were to compile with x32 and run with x64? Or would that be safer than the other way around?
I don't have a sample small code example because the code is extremely large.
Upvotes: 0
Views: 159
Reputation: 2817
It doesn't matter what version of the JDK you compile your application, it should run the same in any of them, the most likely cause is that there is a problem with your x32 JRE installation, the second most likely cause is that you're using too much memory (x64 programs can use much more memory than x32 ones) and the third most likely cause is that you hit a bug in the JRE.
Upvotes: 1