You can assemble this recipe up to four hours before, and simply bake for about 10 minutes before go-time. Thinly slicing the potatoes is key to the lovely smooth, silky texture of the dish.
Preheat the oven to 475 degrees. Lightly butter a 2-qt. baking dish. In a large pot, heat 2 tbsp. butter and the oil over medium-high. Add the mushrooms and cook, stirring occasionally, until browned, about 10 minutes. Reduce the heat to medium, then stir in the potatoes, cream, garlic and kosher salt. Simmer, stirring occasionally, until the potatoes are just tender but not falling apart, about 15 minutes.
Using a slotted spoon, transfer half the potato and mushroom mixture to the prepared baking dish. Sprinkle with half the cheese and season lightly with pepper. Spoon the remaining potatoes and mushrooms on top of the cheese; top with any sauce left in the pan. Using the back of a spoon, lightly press the potato mixture into the dish in an even layer. Sprinkle the remaining cheese over the potato mixture and season lightly with pepper.
Bake until the top is browned, the potatoes are tender and the sauce is bubbling, 20 to 30 minutes. Sprinkle with the thyme and let rest at least 5 minutes before serving.