Proving that the old adage that nothing is guaranteed except death and taxes, pharmaceutical company GlaxoSmithKline (NYSE:GSK) yesterday decided to pay up and settle its long-running tax dispute with the IRS for $3.1 billion.

The dispute over the amount of taxes that Glaxo owed goes all the way back to 2001, when the IRS claimed that the company owed taxes dating back to 1989 in the amount of $8.6 billion (interest included). The disagreement between the IRS and Glaxo stemmed from the issue of what accountants and economists call transfer pricing.

The idea of transfer pricing is that, for tax purposes, a company has to estimate what countries and subsidiaries its costs and revenues are occurring in so that it pays accurate tax bills in each country. This is a huge chore for even the simplest companies. For a geographically diversified $150 billion corporation, this sort of accounting work is at best a rough estimation.

Imagine having to estimate what portion of the cost of producing a drug sold in the U.S. was borne by researchers in Canada, while the drug was manufactured in Puerto Rico, but with the company's headquarters and administrative facilities in the UK. If you guessed that accurately accounting for these costs is a darn near impossible task, then you're right. And this is just a small sample of what companies have to do via transfer pricing in order to figure out tax liabilities in multiple countries with different tax laws and rates.

Glaxo's accountants were no doubt just engaging in smart tax avoidance strategies as they handled the transfer pricing of goods between subsidiaries. At some nebulous point, though (often arbitrarily chosen by the IRS), tax avoidance slips over into tax evasion and becomes a legal issue. In the grand scheme of things, this tax disagreement probably came down to nothing more than a debate over accounting issues between Glaxo and the IRS.

By settling for $3.1 billion, Glaxo put this tax issue in the past, thus cutting down on future legal fees and eliminating the risk of loss at trial. This was no broad Enron-like scheme by Glaxo to defraud the IRS and U.S. government. The real issue is that if countries eliminated or cut down the corporate tax rate (which minimally contributes to government coffers) then tax disputes like this wouldn't occur -- but that's an issue I'll save for another article.

GlaxoSmithKline is a Motley Fool Income Investor recommendation. To discover more promising stocks with dynamic dividends, sign up today for a free30-day guest pass.

Fool contributor Brian Lawler does not own shares of any company mentioned in this article. He welcomes your feedback at blawler@utk.edu. The Fool has a disclosure policy .