There are different physical clues they are supposed to look for. Some will administer the 'standard' roadside tests, but since they are designed for alcohol impairment they are of limited value.
They have a number of specialized tests, called the drug recognition protocol. A small percentage of officers get specialized training in administering these tests.
Ultimately, if the officer believes that the person's physical coordination or reflexes are appreciably impaired, they are empowered to make arrest / investigation decisions based on that. It's a case by case analysis.