Philippine presidential favourite Rodrigo Duterte has warned he is prepared to cut diplomatic ties with Australia and the US, after their ambassadors criticised his comments about the jailhouse rape of a missionary.

Mr Duterte also told the ambassadors to "shut their mouths" as controversy continued to rage over his comments, in which he said he wanted to have been the first to rape the Australian woman who was taken hostage, brutalised and murdered in a 1989 prison riot.

"If I become president, go ahead and sever [diplomatic ties]," the 71-year-old said on the campaign trail on Wednesday night, referring to the relationships with Australia and the US, two of the Philippines' closest allies.

Mr Duterte, who while campaigning has called the Pope a "son of a bitch" and promised to kill thousands of criminals, recounted at a recent rally the riot events as part of his tough-on-crime pitch to voters.

"They raped all of the women ... there was this Australian lay minister ... when they took them out ... I saw her face and I thought, 'Son of a bitch. What a pity... they raped her, they all lined up," he told the crowd.

"I was mad she was raped but she was so beautiful. I thought, the mayor should have been first."

At the time, he was mayor of Davao, a major city in the southern Philippines where he is accused of running vigilante death squads that have allegedly killed more than 1,000 people.

The frontrunner has at times boasted about running the death squads, claiming they killed 1,700 people, but also denied any links to them.

Mr Duterte has similarly offered varying responses to the rape comments, with his media team releasing a statement in which he apologised.

However, while campaigning he has repeatedly told reporters he would not apologise.

Australian ambassador Amanda Gorely criticised his remarks, saying in a statement on Twitter: "Rape and murder should never be joked about or trivialised. Violence against women and girls is unacceptable anytime, anywhere."

US ambassador Philip Goldberg later agreed with her, saying in a television interview that "statements by anyone, anywhere that either degrade women or trivialise issues so serious as rape or murder are not ones that we condone".

"It would do well with the American ambassador and the Australian ambassador to shut their mouths," Mr Duterte said in response.

The US embassy did not have an immediate response to Mr Duterte's remarks while the Australian embassy could not be contacted for comment.

AFP