Place a rimmed baking sheet on the middle oven rack. Preheat to 450°. Toss potatoes, garlic, oil, salt, and pepper together in a large bowl. Spread on the hot baking sheet, roast, stirring halfway through, until tender and golden brown, about 20 minutes.
Sprinkle with rosemary, and serve immediately.