Cut the woody stem ends from each spear and reserve. Cut the remaining tender stalks into 1/2-inch pieces.
In a medium pot, bring the stock to a boil. Add the tough woody stems, lower the heat and simmer to infuse with asparagus flavor, 20 to 30 minutes. Remove with a slotted spoon and discard, reserving the stock.
In a medium stockpot, melt the butter over medium-high heat. When foamy, add the shallots and onions and cook until tender, about 3 minutes. Add the garlic and cook until fragrant, about 1 minute. Add the chopped asparagus, salt, and pepper, and cook, stirring, for 2 minutes. Add the reserved broth and simmer until the asparagus are very tender, about 20 minutes. Remove from the heat.
With a hand-immersion blender or in batches in a food processor, puree the soup until smooth. Adjust the seasoning to taste. Return to medium heat and add the half-and-half. Cook, stirring, until the soup is warmed through, about 3 minutes.