Many international corporations specifically choose to put their EU HQ in Ireland because they have the lowest corporate taxes, yet it enables them to do business in all of the EU.
Many countries invest in their people, provide education, houses, jobs, services, etc, and as a result, they have a wealthy, educated population that is an attractive market to sell to. But if that country has high corporate taxes, and the company can sell to that market from another country, then they end up paying less taxes and not contributing to the country that invested in that market.
That's what I mean with a race to the bottom. Of course there are other reasons why a company might choose a certain place. New York, despite its bad roads and high property prices, is popular because it's close to Wall Street, for example. But companies that have no geographical ties to New York specifically, will probably put their main office somewhere else. Wasn't Delaware a popular state to register your company?