The loophole is setting up a multi-national structure to implement the base erosion and profit-shifting strategies discussed here:
https://www.oecd.org/tax/aggressive/beps-2015-final-reports....
https://www.oecd.org/tax/aggressive/beps-2015-final-reports....