How do academics deal with growing old?
All people deal with getting old(er) in some way, but I can think of a few aspects that are unique to academics.

One way to keep up the performance is to gradually shift from hands-on work to advisory work. It is clear that an aging professor can't keep up with the hours invested, enthusiasm, desire to prove oneself, etc. of a PhD student or junior faculty. However, our older guy has participated in a lot of academic craft (writing papers/grants, advising, doing research, reviewing, etc.) over the years, which can give a significant edge to junior people around him. Guiding others can and does produce scientific breakthroughs even though the senior professor didn't think it all up by himself. Further, it also educates the next generation of researches which also an important and challenging job.

People outside of academia are usually obligated (with exceptions, of course) to retire at a given age. On the other hand, a professor has the possibility to attain the emeritus rank, which lets him be an active member of the academic community theoretically until the end of his life. This partially offsets the time investment of PhD studies, postdocs, etc., if the argument is that people in academia have fewer "productive years" as opposed to people who start off right after undergraduate.

Finally, professors are usually respected members of their communities, so even if some of them perform less in their later career, there are always other duties they can excel at. For example, focus on teaching or department duties or writing books.

In my opinion, none of these options is inferior to the "pure research" track and I feel that many come naturally as personal development. In other words, I don't think aging professors find it necessary to outright compete with their younger colleagues, but rather mature into other roles that benefit the academic community.