Communism is an ideology that demands world conquest and the extinction of Capitalism. The Soviets expanded as far as they could and absolutely would not have hesitated to conquer more of Europe without the threat of the United States military and NATO.
And many NATO countries have pretty advanced militaries. Not large ones in absolute numbers, because they're not large countries, but absolutely more advanced than most non-NATO countries with very few exceptions (like Sweden).
My point, however, is about your claim that all of this somehow subsidised social programs. Those social programs exist independently from US protection. Nobody denies that the US guaranteed the freedom of western Europe (and many other countries around the world). But that and social programs are two completely separate things.