Minecraft has just recently been crashing on me with and out of memory error. Are there any possible explainations for this? It happens alot when traveling from traveling to nether and vice versa. I'm running version 1.7.10 as thats what most my mods work on
Computer Specs:
intel i7 4790k 4.0 GHz
gforce 780ti 3gb
16 gb ram
One thing that I think could be causing it is a new graphic driver update I just installed
The Meaning of Life, the Universe, and Everything.
Join Date:
4/8/2015
Posts:
332
Member Details
Is minecraft using 64 bit java? You can check in the profile settings, it should be something like C:/Program Files/java/stuff. If it looks like C:/Program Files (x86)/java/stuff then you need to change it to the 64 bit version of java.
Alright I'll try changing to the 64 bit java version cause it looks like I have the wrong one.
Also, there is no log file, it just says in game that minecraft has ran out of memory.
That is very likely due to 32 bit Java, not so much due to the amount of heap memory (which will cause a fatal out of memory crash) but because you only have 2 GB of process space available; I have 32 bit myself (OS limited) and if I use Far render distance with 1 GB allocated I will likely get an "out of memory" screen after a few minutes, even as F3 shows that there is plenty of free heap memory. Ironically though, if I allocate less heap memory it doesn't happen, which is actually not so surprising because by allocating less heap there is more memory available for other functions (texture memory is stored outside the heap, which is used by native libraries like OpenGL). Task Manager can show you the total amount of memory used by the Java process, which is typically about twice as high as what is allocated in-game, at least for 512 MB-1 GB of heap.
This also applies to using HD texture packs on a 32 bit system, as demonstrated here (with a 256x texture pack allocating 256-768 MB worked without problems, but 1 GB crashed. Also, you can see that most people do now know about this, including the Mojang moderators, which just tell you to allocate more - then look at the responses that it didn't help because that is the opposite of what should be done).
I also modified the game myself to print out a stack trace when an out of memory error occurred in the main game loop, which normally only ends the current session and displays the error screen; the exact error was "unable to create new native thread", which is exactly what you see when there isn't enough native memory available, as noted here; "The OS will refuse native memory allocation either because the 32-bit Java process size has depleted its memory address space - e.g. (2-4) GB process size limit has been hit - or the virtual memory of the OS has been fully depleted".
In any case though you should use 64 bit Java if you have a 64 bit system; there can be other performance issues when running the wrong version of Java (for example, the OS has to emulate a 32 bit environment, which may not run as well as a native 32 bit OS). Another issue with 32 bit is the amount of stack space; unless I add -Xss1024K to the JVM arguments I get stack overflow crashes; 1024 K is the amount of stack space allocated on 64 bit systems, while 32 bit only allocates 320 K.
Minecraft has just recently been crashing on me with and out of memory error. Are there any possible explainations for this? It happens alot when traveling from traveling to nether and vice versa. I'm running version 1.7.10 as thats what most my mods work on
Computer Specs:
intel i7 4790k 4.0 GHz
gforce 780ti 3gb
16 gb ram
One thing that I think could be causing it is a new graphic driver update I just installed
It might help to post something like the magical thing called a log file...
Is minecraft using 64 bit java? You can check in the profile settings, it should be something like C:/Program Files/java/stuff. If it looks like C:/Program Files (x86)/java/stuff then you need to change it to the 64 bit version of java.
Alright I'll try changing to the 64 bit java version cause it looks like I have the wrong one.
Also, there is no log file, it just says in game that minecraft has ran out of memory.
That is very likely due to 32 bit Java, not so much due to the amount of heap memory (which will cause a fatal out of memory crash) but because you only have 2 GB of process space available; I have 32 bit myself (OS limited) and if I use Far render distance with 1 GB allocated I will likely get an "out of memory" screen after a few minutes, even as F3 shows that there is plenty of free heap memory. Ironically though, if I allocate less heap memory it doesn't happen, which is actually not so surprising because by allocating less heap there is more memory available for other functions (texture memory is stored outside the heap, which is used by native libraries like OpenGL). Task Manager can show you the total amount of memory used by the Java process, which is typically about twice as high as what is allocated in-game, at least for 512 MB-1 GB of heap.
This also applies to using HD texture packs on a 32 bit system, as demonstrated here (with a 256x texture pack allocating 256-768 MB worked without problems, but 1 GB crashed. Also, you can see that most people do now know about this, including the Mojang moderators, which just tell you to allocate more - then look at the responses that it didn't help because that is the opposite of what should be done).
I also modified the game myself to print out a stack trace when an out of memory error occurred in the main game loop, which normally only ends the current session and displays the error screen; the exact error was "unable to create new native thread", which is exactly what you see when there isn't enough native memory available, as noted here; "The OS will refuse native memory allocation either because the 32-bit Java process size has depleted its memory address space - e.g. (2-4) GB process size limit has been hit - or the virtual memory of the OS has been fully depleted".
In any case though you should use 64 bit Java if you have a 64 bit system; there can be other performance issues when running the wrong version of Java (for example, the OS has to emulate a 32 bit environment, which may not run as well as a native 32 bit OS). Another issue with 32 bit is the amount of stack space; unless I add -Xss1024K to the JVM arguments I get stack overflow crashes; 1024 K is the amount of stack space allocated on 64 bit systems, while 32 bit only allocates 320 K.
TheMasterCaver's First World - possibly the most caved-out world in Minecraft history - includes world download.
TheMasterCaver's World - my own version of Minecraft largely based on my views of how the game should have evolved since 1.6.4.
Why do I still play in 1.6.4?