On the other hand, if you get hired by FAANG and work on the "next big thing", like, say, new operating system for smartphones, then the amount of money that can be made from it is virtually unlimited.
The difference between the US and Europe is mostly that: cool, product-focused jobs are all in America, Europe only has the boring, low-risk, low-reward ones. Europe needs to innovate more, that's it.
This is also true in the opposite sense. A mediocre programmer at a bank or a high-profit company could still create a lot of value because of the surroundings or simply the industry. And they're probably compensated for that, at least in part.
Even more interesting – the cafeteria workers, cleaning staff, etc at those companies also produce more value than their colleagues in less fortunate companies/industries. But they're probably not compensated for it, because markets.
In other industries, engineers (software or not) just make products and products are built and sold with "normal" margins and limited growth opportuntites. A healthy company can make a 10% profit every year for a century. Scaling up means having more people because you need more sales, more manufacturing and so on.
In some more pure tech industries like SaaS, Games etc, the profit margins can be much higher. I'd be upset too if I was at a company that made $1M profit per employee and I didn't have a cut. That doesn't apply to most software jobs (at least not here) though.
There doesn't have to be someone capturing profit if the whole industry is priced lower.