The IRS can issue Private Letter Rulings (which are anoymized but public so you could check if they treat a company preferentially - although not which company) and Advance Pricing Agreements.
Rulings from different countries are typically used to ensure no taxes are paid. E.g. get a ruling from the US that some activity is taxable in Luxembourg, and then get a ruling from Luxembourg that it's taxable in the US. Like McDonald's did. Either country will then say "well, it's up to the other country to tax that, I'm not policing that". Mostly after a while, multiple companies get clued in and it all gets exposed and the "loophole" is closed. E.g. a uble Irish with a Dutch Sandwich. See https://en.wikipedia.org/wiki/Double_Irish_arrangement
This can be an honest error by one or both tax services, a strategic move (to be a "tax paradise" and prevent other taxable activities from leaving the country), or - one would speculate, allegedly - for political or personal gain.