This is not group aware.
I may have misunderstood the rationale here, but I think the discussion about cgroup support is not about limiting the number of Ps
However, as far as I can tell, there's no clear way to figure out what M is, in the general case.