The man who invented the iconic AK-47 automatic rifle wrote of his regret at creating the weapon.

Mikhail Kalashnikov, who died last month aged 94, designed the weapon that became synonymous with killing on a sometimes indiscriminate scale.

He was seen in the Soviet Union as a national hero and symbol of Moscow's proud military past.

However, Kalashnikov had said he never intended for the rifle to become the preferred weapon in conflicts around the world.

He wrote to the head of the Russian Orthodox Church in May 2012, wondering if he was responsible for the many deaths caused by the weapon he had created.

The AK-47: A global killing machine The Kalashnikov is officially in service in 55 countries.

The Kalashnikov is officially in service in 55 countries. Several national emblems feature the rifle, and some boys in developing nations have been named Kalash after it.

Several national emblems feature the rifle, and some boys in developing nations have been named Kalash after it. In 1973, Chile's communist president Salvador Allende died holding an AK-47 - a gift from Soviet-backed Cuban leader Fidel Castro - in a coup staged by pro-US general Augusto Pinochet.

In 1973, Chile's communist president Salvador Allende died holding an AK-47 - a gift from Soviet-backed Cuban leader Fidel Castro - in a coup staged by pro-US general Augusto Pinochet. Thirty years later, invading US troops found a gold-plated Kalashnikov reportedly given to Saddam Hussein's son Uday at one of the Iraqi leader's palaces in Baghdad.

Thirty years later, invading US troops found a gold-plated Kalashnikov reportedly given to Saddam Hussein's son Uday at one of the Iraqi leader's palaces in Baghdad. Osama bin Laden, the Al Qaeda leader killed in 2011, posed with a Kalashnikov in videotaped diatribes against the West.

Osama bin Laden, the Al Qaeda leader killed in 2011, posed with a Kalashnikov in videotaped diatribes against the West. Taliban fighters in Afghanistan, Liberian gangs, Somali hijackers and South American guerrillas all seem to admire the rifle that enthusiasts say continues to work in dust, sand and swampland.

In his letter to the Russian Patriarch, Kalashnikov wrote that one question was causing pain to his soul.

"I keep having the same unsolved question: if my rifle claimed people's lives, then can it be that I... a Christian and an Orthodox believer, was to blame for their deaths?" he wrote.

"The longer I live, the more this question drills itself into my brain and the more I wonder why the Lord allowed man to have the devilish desires of envy, greed and aggression."

In his letter, Kalashnikov said that he first went into a church at the age of 91 and was later baptised.

The letter has been published by local Russian newspaper Isvestya.

The paper quotes a spokesman for the patriarch as saying that when weapons serve to defend the fatherland, the Russian Orthodox Church supports those who created them as well as the soldiers who use them.

AK-47's name stands for "Kalashnikov's Automatic" and the year it was designed, 1947.

Also called the "Kalashnikov", the rifle and its variants are the weapons of choice for dozens of armies and guerrilla groups around the world.

More than 100 million Kalashnikov rifles have been sold worldwide and are wielded by fighters in conflict zones as Iraq, Afghanistan and Somalia.