The US president also said that he repaired relations with Philippines which soured after Obama criticized Duterte.
Manila: Donald Trump said on Tuesday that strong ties with the Philippines were vital for military reasons, as he ended a trip to Manila in which he ignored allegations of mass murder under Rodrigo Duterte.
The US president said he had repaired relations with the Philippines, which soured last year when the administration of former president Barack Obama criticised Duterte's drug war.
"The (Philippines') relationship with the past administration was horrible, to use a nice word. I would say horrible is putting it mildly," Trump told reporters.
"And now we have a very, very strong relationship with the Philippines, which is really important: less so for trade, in this case, than for military purposes."
Duterte vowed during last year's election campaign that he would wage an unprecedented crackdown to eradicate illegal drugs in society, which he said would claim up to100,000 lives.
Since Duterte took office 16 months ago thousands of people have been killed, with rights groups accusing police and hired assassins of mass murder.
Then President Obama urged Duterte to follow the rule of law in prosecuting the drug war.
Duterte responded by branding Obama a "son of a whore" and using the controversy as a reason for building closer ties with China and Russia.
The Philippines, a former American colony, had been one of the United States' most important allies in Asia, and the nations remain bound by a mutual defence pact.
Rights groups had called on Trump to voice concerns about the drug war in Manila, which was the last stop on a 12-day Asian tour.
Trump instead appeared in a range of events on the sidelines of summits involving leaders from 19 nations in which he and Duterte clearly enjoyed each others' company.
"We've had a great relationship. This has been very successful," Trump told Duterte in brief opening remarks at their official meeting on Monday. "I've really enjoyed being here."
Trump then laughed as Duterte called the foreign and local media in the room "spies".
Duterte's spokesman later said Trump did not bring up any human rights concerns in the meeting, which lasted about 40 minutes. Trump spokeswoman Sarah Huckabee Sanders said human rights were raised, although "briefly".
Duterte and Trump also sat next to each other at a pre-summit banquet on Sunday, during which they smiled, chatted and clinked champagne glasses.
Duterte sang a Filipino love song at the dinner, saying light-heartedly that he did so on the orders of the US president.