digitalmars.D.learn - new and GC.malloc fail, core.stdc.malloc works
- John Colvin (6/6) Jun 24 2014 I'm getting OutOfMemoryErrors on some machines when calling
- John Colvin (6/12) Jun 24 2014 P.S. yes I've checked the return value of core.stdc.malloc. Also,
- bearophile (8/11) Jun 24 2014 I think that when you go in territories where most people have
- John Colvin (4/15) Jun 25 2014 After a little more investigation It seems that I'm getting an
- John Colvin (2/20) Jun 26 2014 User error, carry on, nothing to see here...
I'm getting OutOfMemoryErrors on some machines when calling GC.malloc (or new) for anything large (more than about 1GB), where core.stdc.malloc works fine. Anyone ever come accross this before? I suspect it's related to some system memory monitor/management as it's only happening to me on supercomputer nodes.
Jun 24 2014
On Tuesday, 24 June 2014 at 10:06:10 UTC, John Colvin wrote:I'm getting OutOfMemoryErrors on some machines when calling GC.malloc (or new) for anything large (more than about 1GB), where core.stdc.malloc works fine. Anyone ever come accross this before? I suspect it's related to some system memory monitor/management as it's only happening to me on supercomputer nodes.P.S. yes I've checked the return value of core.stdc.malloc. Also, I'm not doing anything silly like calling them one after the other and then wondering why the second one doesn't work (although seeing as I've got ~24GB of RAM to play with that shouldn't be a problem).
Jun 24 2014
John Colvin:I'm getting OutOfMemoryErrors on some machines when calling GC.malloc (or new) for anything large (more than about 1GB), where core.stdc.malloc works fine.I think that when you go in territories where most people have not done much coding in D, like allocating than 1 GB in one shot, you hit some bugs. In general if some part of D is not used a lot, you have to assume it's buggy. Please report in Bugzilla the problems you have located. Bye, bearophile
Jun 24 2014
On Tuesday, 24 June 2014 at 10:16:38 UTC, bearophile wrote:John Colvin:After a little more investigation It seems that I'm getting an OutOfMemoryError at around 1GB memory usage, regardless of the granularity of allocation.I'm getting OutOfMemoryErrors on some machines when calling GC.malloc (or new) for anything large (more than about 1GB), where core.stdc.malloc works fine.I think that when you go in territories where most people have not done much coding in D, like allocating than 1 GB in one shot, you hit some bugs. In general if some part of D is not used a lot, you have to assume it's buggy. Please report in Bugzilla the problems you have located. Bye, bearophile
Jun 25 2014
On Wednesday, 25 June 2014 at 14:44:22 UTC, John Colvin wrote:On Tuesday, 24 June 2014 at 10:16:38 UTC, bearophile wrote:User error, carry on, nothing to see here...John Colvin:After a little more investigation It seems that I'm getting an OutOfMemoryError at around 1GB memory usage, regardless of the granularity of allocation.I'm getting OutOfMemoryErrors on some machines when calling GC.malloc (or new) for anything large (more than about 1GB), where core.stdc.malloc works fine.I think that when you go in territories where most people have not done much coding in D, like allocating than 1 GB in one shot, you hit some bugs. In general if some part of D is not used a lot, you have to assume it's buggy. Please report in Bugzilla the problems you have located. Bye, bearophile
Jun 26 2014