Java Heap Space Memory Issue
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
This question has been asked by others as well. But solution in majority of those questions worsened the situtation in my case instaed of improving.
I have a code tha runs a parallel for loop i.e. parfor. In certain cases I get the following error
java.lang.OutOfMemoryError: GC overhead limit exceeded at java.util.Arrays.copyOfRange(Unknown Source) at java.lang.StringBuffer.toString(Unknown Source)
Most of the solution suggested to increase the heap space memory in MATLAB. Once I increased the memory to 2GB from 784MB the frequency at which I was getting this error increased. One thing to note here is that the parallel for loop worked perfectly fine in version 2017b and I started getting this error when I switched to version 2020a. After looking the heap space memory allocated in 2017b I reduced the default memory in 2020a to 384MB similar to default set in 2017b. This solved the issue but I do not understand why reducing helps when most of the solutions suggest to increase the heap space memory.
I want to know a logical reasoning for this behaviour.
0 commentaires
Réponses (0)
Voir également
Catégories
En savoir plus sur Loops and Conditional Statements dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!