Probably not ideological differences, but religious differences like the 12th Imam seem to leap out. Why that would lead one group to blow up the other's vegetable markets and mosques is a mystery.
The only difference between the Shia and Sunni regarding the Mahdi are the means by which he appears... once he’s here, they all agree on things he will do.
Not that it's necessarily a bad thing.
The way the Sunni Salifists view the world is this:
No country on earth is truely Islamic. The way the world is now is exactly as it was at the time of Mohemmed.
Meaning that there is a small vanguard of true Muslims and their mission is to create the first real Islamic state (again).
This means that those people who consider themselves Muslims but who are not working toward this goal are not truely Muslim and thus are legitimate targets of war.
none of the shiia are considered to be proper Muslims but apostates
thus they are legitimate targets of war.
NOT TO MENTION the ease with which the militants can cause failure of the US mission in Iraq by enflaming the Sunni/Shia divide.
The matter is complex because it does seem that in some circumstances Iran and Al Qaida are working together against the US.. which isn’t surprising... since they using their own version of the Enemy of my Enemy is my Friend.