Usually, you pay tax in the jurisdiction whose services provided by the tax you will use. I'm Canadian, and pay Canadian taxes, because I use Canadian services.
If I own a small piece of say, Disney, I can usually apply for an exemption to some or all of the income tax because the US recognizes that I live and work in Canada, and pay taxes there. This encourages me to buy more Disney shares.
Guess what happens when the IRS decides that I have to pay them, while at the same time getting taxed by the Canadian government? Exactly. I sell Disney.