Preheat the oven to 350 degrees. Slice the squash in half lengthwise, and remove the seeds and stringy pulp with a spoon. Rub the flat side with olive oil and place the squash, cut side down, in a glass baking dish; sprinkle the garlic cloves around the squash.