Forget immigration, the USA had slavery, which too, went away due to the natural forces of the democracy (and liberty of man). I subscribe to the notion that The US Constitution always had eventual emancipation of the slaves in mind, during the drafting (typical political can kicking).
Over time, the choices that affect an underclass are more lenient, as the underclasses vote in their own interest. Short term, there can always be less efficient redistribution outcomes, which does not contradict the mid term effect.
The long term effect is that Democracies are subject to the tyranny of the majority or the pareto curve via coordinated propaganda toward an extensive uneducated/politically-ineffectual population. The USA is no different, but is still very young.
> I think even a cursory analysis of the state would lead you conclude that governments don't efficiently allocate resources in any meaningful sens
A cursory analysis shows that US Govt entitlements are the largest part of the US Budget year over year, since Social Security was introduced (at least). What you mean by efficient is a sticking point, but the majority of the budget goes to supporting the people. That seems to fit.
https://www.nationalpriorities.org/budget-basics/federal-bud...
https://www.cbpp.org/research/federal-budget/policy-basics-w...