Remove the loose, papery outer skin from the head of garlic. Cut about ½ inch off the top to expose the cloves. Place the garlic head on an 8-inch square of aluminum foil and drizzle 1 teaspoon of the oil over the cloves. Fold up the foil sides and seal to make a packet, leaving a little room for the expansion of steam.
Prepare the grill for indirect cooking over medium heat (350° to 450°F).
Brush the cooking grates clean. Grill the garlic packet over indirect medium heat, with the lid closed, until the cloves are soft, 30 to 45 minutes. Remove from the grill and allow to cool. Squeeze the garlic from the individual cloves into a small bowl. Add the remaining 3 tablespoons oil and mash the garlic and oil together with a fork to form a paste.
Trim the tenderloin of any excess fat and silver skin. Spread the paste on the tenderloin, rubbing it into the meat.
In a small bowl combine the peppercorns, rosemary, salt, and pepper. Mix well and press into the paste on the top and sides of the tenderloin.
Allow the tenderloin to stand at room temperature for 15 to 30 minutes before grilling. Grill over indirect medium heat, with the lid closed, until the internal temperature reaches 125° to 130°F for medium rare, 30 to 40 minutes.
Remove from the grill and let rest for 5 to 10 minutes (the internal temperature will rise 5 to 10 degrees during this time). Cut into ¾- to 1-inch slices and serve warm.