Skip to content

Instantly share code, notes, and snippets.

@anuvrat
Created April 15, 2012 06:52
Show Gist options
  • Select an option

  • Save anuvrat/2390595 to your computer and use it in GitHub Desktop.

Select an option

Save anuvrat/2390595 to your computer and use it in GitHub Desktop.
/*
* Processes which fork a lot of child processes are likely
* a good choice. We add the vmsize of the childs if they
* have an own mm. This prevents forking servers to flood the
* machine with an endless amount of childs
*/
...
if (chld->mm != p->mm && chld->mm)
points += chld->mm->total_vm;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment