I think this is a common use case: You have an OS running many applications and the most important app running is both, very memory intensive and at the same time performance critical. You may want to allocate some containers reserving a lot of memory to prevent reallocation (for e.g. on vector::push_back) or you want to create some arenas to allocate specific objects in consecutive memory addresses.
In this case you can enable memory overcommitting for the whole system but not for individual processes. E.g. echo 1 > /proc/sys/vm/overcommit_memory
or sysctl vm.overcommit_memory=1
. Is there a way to achieve the same for a single application only?
Is there a way to only allow one specific application overcommitting?