Bring a large pot of water to a boil and salt it. Smash the garlic cloves with the flat side of a knife and discard the skins; chop. Put the oil, pine nuts, and garlic in a large skillet over medium-low heat and sprinkle with salt. Cook, stirring occasionally, until the pine nuts and garlic just turn golden, 2 to 4 minutes. Turn off the heat and stir in the whole basil leaves.
Add the pasta to the boiling water, and cook, stirring occasionally, for 5 minutes, then start tasting. When the pasta is tender but still has some bite, scoop out 1 cup cooking water, then drain the pasta.
Immediately add the pasta to the skillet along with half the cheese and a splash of the cooking water and turn the heat to medium. Toss to coat the pasta evenly, adding a little more cooking water if necessary to create a creamy—but not soupy— sauce. Taste, adjust the seasoning, adding more cheese if you like, and serve, passing the remaining cheese at the table.