I think that is significantly overlooked when people ask "where are the 50+ engineers?".
I'm not discounting ageism in the industry, but how popular of a career was it 30+ years ago compared to now?
I've had to change course several times in my career (graduated in 2004). UNIX admin and later network admin, DevOps, and now I'm doing a mixture of DevOps and development (despite not being a full time developer in my entire career, being able to use AI to plug into code and fix/enhance things like monitoring, leveraging cloud APIs, etc has been a game changer for me).
Right now, as somebody in their mid 40s, I'm seeing AI as a productivity amplifier. I am able to take my experience and steer and/or fight opus into doing what's needed and am able to recognize if it looks right.
I'm so glad I'm not fresh out of school in this environment, though people said the same thing when I graduated in the Dotcom bust...but being ready and eager to do groundwork was a door opener. Finding that first door to open was tough, though.
You’ll also find that engineers are sorted (by self or not) into different companies. I’ve worked at companies where 75% of engineers were over 40, and I’ve worked at places with the opposite.
It's a lot easier to be early than to be smart or quick.
New grads are being slammed, "because LLMs can do that work."
No new folks, no managers, and no olds. What a delightful career we've chosen for ourselves.
Now, would I relish looking for a programmer job right now at my age? Hell no.
Year after year it was just much more new people joining as things got easier and more accessible.
Now you see 40 or 50 year olds far and between where most guys I see are in their 30s. Ones that are 60 yo diluted in the sea of new entrants.
Ageism didn't came from the top it just happened with flood of young employees, there is just social dynamics where you might get 40yo not being a manager getting along with bunch of 25yolds but that's going to be an exception not the rule.