>When this boom ends, the 40+ should expect to be the first cut. Again. Just like in 1992, 2001, 2008, ...
Whether the older or the younger ones get cut first can vary, based on various factors, and probably will vary in future too.
In 2001 downturn (which was due to the dot-com bust and post 9/11), I've read that a lot of younger ones were cut first. That was reportedly because they had only one or so skill, e.g. Java (during the boom, cos. were hiring and sending to the US, people who had a few weeks of Java on their resume, they were that desperate for people), while older people often had a good mix of skills (e.g. some language, some DB, some OS, some libs, s/w engg. skills, etc., so it was higher VFM (Value For Money) to retain them), so were fired less and later. In the dot-com boom that just preceded the bust (read up on the details somewhere or ask those who know, those who don't know about it, the factors involved are too long to describe in a comment here), dotcos were flush with funds from VCs and even Wall Street types, and were throwing money at employees left and right. I've even heard that BMWs were on offer as a joining bonus (in the US, SF Bay Area). I myself (was in India) got some crazy high offers (e.g. had some years' experience in projects and with skills in a mix of in-demand technologies, did not consider myself experienced enough to be a CTO, but got an offer for that role from a Mumbai dotco for a giant sum), but did not take it seriously (although I'll admit I was tempted and considered it a bit) and did not go for it, thankfully, as it later turned out. A junior guy I knew casually around that time, quit his fairly good job to join one of those frothy (literally in a sense, in this case, called (no comment) freshlimesoda.com). I think the excesses on this front (as exemplified by that name and business plan - remember Yo (later), anyone?) were even more in India then, than they were in the US (from what I could gather).
Conversely, in a previous (less-publicized bust), I was working as a Unix system engineer in a large national-level hardware+software company in India, and was quite junior. Soon after I joined, there was an industry "shakeout" (term used then) and several mid-level people were let go (both in India and the US, probably, in the industry as a whole). We juniors were mostly spared, though, except for the bottom of the barrel, who were sacked.