Make the soup: In a medium saucepan (or dutch oven), melt the butter over medium-low heat. Add the garlic and cook, stirring often, until it is golden brown and toasty. With a slotted spoon, transfer the garlic to a plate. Add the shallots to the pan and cook, stirring occasionally, for 8 to 10 minutes, or until soft and slightly golden. Stir in the tomato paste and cook for 5 minutes. Return the garlic to the pan, along with the tomatoes, sherry, stock, sugar, basil, salt, and pepper. Bring the mixture to a boil. Then, reduce to a simmer and cook for 20 minutes.