By "divestment" I assume you are suggesting that the U.S. should have pursued a policy of not allowing investment in Iranian businesses.

The United States has engaged in sanctions against Iran since 1979. To date, they have been proven largely ineffective. Furthermore, given that we have had sanctions in place for nearly thirty years, I don't see how failing to invade Iraq would have affected "divestment" either way.