In C I'd get a return value from malloc (like, NULL in this case, assuming

in C, it depends on the size of the allocation. in linux, the behavior depends on the /proc/vm/overcommit_memory setting: it can refuse to give you more memory than it has, or the max size can be set to swap+ram*/proc/vm/overcommit_ratio or (the default setting, overcommit_memory=0) a heuristic that lets you make absurdly large allocations, as long as you don't touch them all...

(it also depends on whether your glibc contains a malloc that switches to mmap for large allocations rather than sbrk, etc.)
_______________________________________________
Beowulf mailing list, Beowulf@beowulf.org
To change your subscription (digest mode or unsubscribe) visit 
http://www.beowulf.org/mailman/listinfo/beowulf

Reply via email to