digitalmars.D.learn - How do you handle OutOfMemoryError?
- Enjoys Math (8/8) Sep 19 2015 Here's my code:
- John Colvin (7/15) Sep 20 2015 Memory allocated with the GC (e.g. using new) will never be freed
Here's my code: https://drive.google.com/file/d/0B3LYxKGJ4ZI_MV91SkxPVVlSOW8/view?usp=sharing I don't have access to a debugger. Run the code for a few minutes and it tends to crash with a core OutOfMemoryError. Any suggestions welcome including regularly cleaning up memory used. Thanks.
Sep 19 2015
On Sunday, 20 September 2015 at 00:16:50 UTC, Enjoys Math wrote:Here's my code: https://drive.google.com/file/d/0B3LYxKGJ4ZI_MV91SkxPVVlSOW8/view?usp=sharing I don't have access to a debugger. Run the code for a few minutes and it tends to crash with a core OutOfMemoryError. Any suggestions welcome including regularly cleaning up memory used. Thanks.Memory allocated with the GC (e.g. using new) will never be freed if a reference is kept to it. Are you accidentally or deliberately keeping a complete history of all programs? Are you allocating any memory from anywhere other than the GC? What OS? How much RAM? Are you compiling with -m32 (and conversely what happens if you compile with -m64)?
Sep 20 2015