Are you sure that availability of resources was a limiting factor during a large part of human evolution?
ie what has driven human population growth - a fundamental change in availability of natural resources or a fundamental change in how humans exploited them?
I'd argue it's the latter, and that's driven by accumulated knowledge - and before writing - the key repository of that was - old people.
Humans have selective adaptations to reduce resource competition between older and younger members of populations - examples are menopause and testosterone levels.
Part of the reason it benefited us that some but not all people become old is because people require more attention during two phases of their lives. Our biological evolution has prioritized care for the very young over the very old, with respect to a limit on resources (like attention), effectively until the modern age. In some cultures, for instance, those with teeth must pre-chew food for those without, or expected members to engage in ritual suicide at a certain age.
I think it's a mistake ( common ) to view any organism at a point in time as perfectly adapted.
It's like saying cars pistons are designed to wear out - because they do and as the car is perfectly designed ( the mistake ) then it must be for a reason.
Also take menopause - it happens a female has all the oocytes ( eggs ) they will ever have already at birth. Menopause happens when they run out.
What you are arguing is that the number at birth is optimised with a very indirect feedback loop - as oppose to a very direct one of how much resources do you put aside for eggs in terms of maximising number of direct children versus resources used. Occams razor suggests the latter is going to be stronger.
If what you say is true - think about it - old people wouldn't gradually crumble due to wear and tear, they would have evolved some much more efficient death switch. ie Women don't suddenly die post menopause.
Sure - though the tuned behaviour around turning the innate immune system up and down is probably dominated by the more recent part of that long history.