For caramelized onions, melt butter in a skillet over medium-low heat. Stir in onions and salt. Let cook undisturbed for about 10 minutes. Sprinkle with sugar and stir. Allow to continue cooking until browned and softened. Mostly leave undisturbed but give it a stir every eight to 10 minutes or so. This should take about as long as the polenta.
In a saucepan, bring stock to a boil over medium-high heat. Constantly stirring with a wooden spoon, slowly pour in cornmeal.
Reduce heat to low. Cover and cook for 30 to 40 minutes, vigorously stirring about every 10 minutes. The polenta is done when the grains soften to your liking. Turn off heat and stir in Parmesan and butter until they melt. Add heavy cream, salt and pepper. Stir in caramelized onions.
You can serve polenta immediately or pour into a buttered dish for baking. If baking, you can either let the polenta set until it firms in texture or put it in the oven after about 10 minutes to keep the creamy consistency but develop a crust. To set the polenta, you can do this in room temperature or in the refrigerator overnight. If setting in the refrigerator, remove the dish for about 30 minutes to an hour before baking to prevent the dish from cracking. Bake at 375 degrees for about 20 minutes.
For the blue cheese sauce, melt butter in skillet. Sprinkle flour over butter and constantly whisk for three minutes. Pour in heavy cream, garlic and Dijon mustard while whisking to prevent lumps. Once warm, stir in blue cheese until it's somewhat melted but with some crumbles intact. Season with salt and pepper to taste. Whether you cook or also bake the polenta, prepare this about 10 minutes before the polenta is ready.
Spoon blue cheese sauce over polenta. Enjoy!