Whenever demand softens, which it does every few years, women and minorities take the brunt. Once you have been out for even three years it is very hard to break in again.
Part of the problem is that when employers don't feel like paying a living wage, they easily persuade government to import foreign help, in the tens or even hundreds of thousands. The companies pretend that this doesn't depress salaries, despite overwhelming evidence to the contrary.
Furthermore, they have arranged not to be obliged to pay overtime, and then they demand overtime work on a routine basis. I have never seen such an employer pay engineers overtime, under any circumstance. Sometimes there are "bonuses" that are a tiny fraction of what overtime would cost them.
The only plausible solution to this problem will be for engineers and programmers to unionize, and start cultivating representation in legislatures. We are handicapped by myths about self-reliant cowboy engineers who don't need to join together.