All the countries you mentioned, though, have relatively high GDP per capita, so even though when taken as a whole their populations and economies may not be among the largest in the world, when it comes to to economy scaled relative to population size, they are among the tops. You still need resources to invest, no matter how hard you try. No resources, no output.
Going back to your example of Ireland, it actually has a higher GDP per capita (around $75,500) than the US (at around $59,500). In fact, except for Luxembourg, Ireland has the highest GDP per capital in the world among countries that aren’t essentially tiny little city-states, tax havens for the uber wealthy, or oil-rich Gulf states.
Sweden ($51,500) and Finland ($44,300) are also pretty high up there. In fact, both are higher than Japan ($42,800).
Yes, if make good stuff and make it available, you can pull great things off. However, if you don’t have the resources to make such good things. The examples you cited just go on to prove that you in fact _do_need resources in order to produce stuff.
Source for my data: CIA World Factbook