Energy companies led U.S. stocks to modest gains Wednesday as the market recouped some of its hefty losses from the day before. Big retailers and health care companies also helped lift the market, which was coming off its worst day in almost three weeks. Utilities and phone companies were the biggest laggards.