A commander of Iran's Islamic Revolutionary Guards Corps (IRGC) has been killed in Iraq, Iranian media reported.

The Tasnim news agency, said to be affiliated with IRGC, says Reza Hosseini Moghadam was in Samarra to confront militants of the Islamic State (IS) when he was killed on February 7.

"He [Moghadam] was martyred in the vicinity of the Al-Askari [Shi'ite] shrine in Samarra," Tasnim reported.

Hard-line news sites reported that Moghadam, who they said was a veteran of the 1980-1988 Iran-Iraq war, was killed by IS snipers and buried in Najaf.

Tasnim said Moghadam had requested in his last will to be buried in Wadi al-Salaam cemetery in Najaf.

Moghadam is the second senior IRGC member reported killed in Iraq in less than two months.

In December, the IRGC said one of its commanders, Brigadier General Hossein Taghavi, was killed while on a mission to advise the Iraqi Army and volunteers in Samarra. Taghavi was reportedly killed by a sniper.

Thousands of IRGC members attended his funeral in Tehran.

Ali Shamkhani secretary of Iran's Supreme National Security Council said at his funeral: "Taghavi and people like Taghavi gave their blood in Samarra so that we do not give our blood in Tehran."

Tehran has acknowledged sending advisers to Iraq to help combat the IS militant group and to Syria to help fight the IS and other antigovernment forces battling the regime of President Bashar al-Assad.

Iran is not a member of the U.S.-led coalition forces attacking IS targets in Iraq and Syria.

Both Iran and the U.S. have denied cooperating or any coordination of their activities in the fight against IS.

But officials have said that the issue has been discussed on the sidelines of the nuclear talks aimed at finding a lasting solution that would prevent Iran from acquiring nuclear weapons.