Thanks, that was an insightful reply. It's like when the banks pushed off mortgage risk to the public market before the great recession. Companies accrue massive technical debt (risk), but push it on the buying company who either isn't competent enough to DD the software, or simply doesn't care. In the end, someone has to pay for that negligence, but it's like playing hot potato or musical chairs.
In hindsight, I think that the M&A process of companies is actually correctly aligned with their true costs. For most big enterprise "tech" companies, their biggest operating expenses aren't technologists at all - it's sales commissions (stock options are as a rule terrible for engineers at every old hat tech company). So instead of paying $4.2MM to acquire a customer or two, you acquire a tech start-up that already has the customers and the product people are mostly cogs - the technology itself is an afterthought. For the few companies where engineers are compensated like the sales folks in enterprise tech (about $300k+ up) it is now cheaper to acquire technology faster than to pay for engineers in-house to develop it - market fit is not a big deal because the growth model is easy to scale with minimal sales staffing costs (a luxury in business through and through).
As for the question of whom pays for the negligence of M&As in the tech sector, it's mostly shareholders rather than the US taxpayer at least. With HP, IBM, and others laying off employees faster than Macy's and Sears the negative outlook is baked into Wall Street's prognosis of increasingly lowered expectations.
Myself, I just wish I could slightly tweak index funds to exclude specific tech companies I know are complete garbage long-term (similar to cable unbundling trends). I know Vanguard probably won't do it for me but maybe the transaction costs will be low enough that excluding the junk companies that literally only exist on an index for being big and being a market leader is a net win.