Anonymous mapped regions increases unlimitely on spawn
    unDEFER 
    undefer at gmail.com
       
    Fri Dec 14 16:35:38 UTC 2018
    
    
  
Hello!
I have the program which uses BDB and while testing often makes 
spawn. And after 12 hours of testing bdb said:
mmap: Cannot allocate memory
But the problem that I've found that it is not BDB created too 
many maps. Watching for /proc/[PID]/maps shows that number of 
anonymous mapped regions increases on 2 every spawn process, and 
never decreases even after finishing the spawned thread.
According to logs my program made 32543 spawns for test time. And 
my /proc/sys/vm/max_map_count = 65530. So only 444 maps was 
allocated by other reasons and 65086 by spawn.
So what to do? How to make spawn decrease count of anonymous 
mapped regions?
    
    
More information about the Digitalmars-d-learn
mailing list