Younes Mohammad | Getty Images

Iraq's reconstruction efforts desperately need international investment, and the U.S. and its Gulf allies want to push back on Iran's entrenched influence in the war-weary country. Billions of dollars in recently pledged investment from Saudi Arabia and its neighbors may serve as a tool to meet both of these ends, but Iraq's upcoming election could threaten that — depending on who comes out on top. Iraqis go to the polls this weekend in their first election since defeating the Islamic State (ISIS), with nearly every aspect of the country's future on the line: its economy, reconstruction, terrorism, sectarian reconciliation, stability, and which international powers will wield the most influence. The latter is in particular focus for Saudi Arabia and the U.S., who view Iran's fortified presence in Iraqi politics as a direct threat to their interests and to regional stability. All of the frontrunners in the leadership contest have ties to Tehran, but those that are particularly loyal to the Islamic Republic and could effectively force out U.S. and Sunni Gulf involvement in Iraq.

Reconstruction works continue in Mosul, Iraq after 9 months long anti Daesh operations on January 25, 2018. Hemn Baban | Anadolu Agency | Getty Images

Iran's geographical, cultural and religious ties to Iraq — particularly much of its Shia population — as well as its role in the anti-ISIS fight, make it a heavyweight in the country. Meanwhile, its regional arch-rival Saudi Arabia has just started its engagement with Baghdad, recently pledging $1.5 billion in reconstruction funds and making a series of diplomatic overtures.

Iran: Wielding influence through pro-Tehran candidates

Iraq's population is roughly 65 percent majority Shia Muslim, and the role of prime minister has been reserved for a Shia ever since the fall of Saddam Hussein's Sunni government during the 2003 U.S. invasion. While several parties and candidates are running, the pack is led by the current prime minister, Haider Al Abadi, who is seen as the most pro-Western and who the U.S. hopes will win re-election. Abadi has been praised for running on a pan-Iraqi, anti-sectarian platform, reaching out to Sunni neighbors like Saudi Arabia and working across religious sects.

His primary competition is former Iraqi prime minister Nuri Al Maliki, who is often blamed for the sectarian rule that disenfranchised many Sunnis and led to the empowerment of ISIS. Heavily backed by Iran, Maliki still remains one of the most powerful politicians in the country. Another potent contender is Hadi Al Amiri, firebrand leader of the Badr Organization that is a part of the Iranian-funded Popular Mobilization Forces (PMF), the Shia paramilitaries that played a key role in defeating ISIS but who have been accused of sectarian atrocities by Iraq's Sunni and Kurdish communities.

Threats to U.S. interests

Both Maliki and Amiri are viewed as conduits through which Iran can exercise political power, said James Jeffrey, former U.S. ambassador to Iraq from 2010 to 2012 and a fellow at the Washington Institute for Near East Affairs. "Iran is doing everything they can to block Abadi, who they see as too pro-American," Jeffrey told CNBC in a phone call. Through Maliki or Amiri, "Iran will try to ease the U.S. out of Iraq, and diminish our influence through parliament to push out U.S. troops." More than 5,000 U.S. troops remain in Iraq. The composition of Iraq's parliament after Sunday's elections, Jeffrey said, "will determine how Iran manipulates the system."

An Iraqi soldier works on a map during a training portion in support of Operation Inherent Resolve, the US-led coalition in the fight against ISIS. Department of Defense photo

In March, U.S. Defense Secretary Jim Mattis accused Iran of "mucking around" in Iraq's elections, saying it was using money to sway voters and candidates. Iran has denied interference. The PMF was officially made a part of the Iraqi military the same month, something that also worries Washington — multiple PMF commanders have issued threats against U.S. troops in the country.

Saudi rapprochement: Old neighbors, new friends

Saudi Arabia has been steadily expanding its engagement with Iraq's government, which is a big deal — the two countries had no diplomatic relations for 24 years following Saddam Hussein's invasion of Kuwait in 1990. Late 2017 saw the first flight between Riyadh and Baghdad in 27 years, and now the kingdom has opened up a consulate in Iraq's southeastern city of Basra while several Saudi businesses have set up offices in Baghdad. Iraqi officials estimate $100 billion will be needed to rebuild the country after its bloody three-year offensive against ISIS, which swept one-third of the country in 2014. Allies pledged $30 billion for reconstruction during a donor conference in February, far short of the target — but one-third of that came from Sunni Gulf states. Those funds are expected to go toward much-needed investment in sectors like housing, energy, and transportation. Iraq's post-ISIS reconstruction will be vital to avoiding a return to future conflict. But those investment dollars may become a victim of the Saudi-Iran rivalry, said Nicholas Fitzroy, Iraq analyst at the Economist Intelligence Unit. "Abadi is largely accepted across the international community and his victory would be least likely to jeopardize investment," he said. "Should Amiri or Maliki head the government, the Gulf countries, and Saudi Arabia in particular, would be much more reluctant to commit funds, given both candidates' close links to Iran."

Bandar Algaloud | Saudi Royal Council | Handout/Anadolu Agency | Getty Images

Meanwhile, as tensions between the Saudis and Iranians heat up, Abadi has said he does not want them turning Iraq into their battlefield, as has happened to varying extents through proxy conflicts in Syria and Yemen.

Not going anywhere