Rape, robbery and murder will attract the death penalty in Papua New Guinea after the country's parliament passed a series of measures aimed at deterring violent crime.

PNG's parliament on Tuesday also passed laws allowing for five types of execution - hanging, lethal injection, medical death by deprivation of oxygen, firing squad and electrocution.

The parliament also repealed the controversial 1971 Sorcery Act, meaning those convicted of killing accused "sorcerers" will be sentenced to death, Prime Minister Peter O'Neill's spokesman, Daniel Korimbao, said in a statement.

"These are very tough penalties, but they reflect the seriousness of the nature of the crimes and the demand by the community for parliament to act," he said.

"Which method (of execution is) to be used will be determined by the head of state on advice from the National Executive Council (cabinet)."