The S&P 500 rose 0.8 percent, but still lost 3.9 percent for the month. After setting a record high Sept. 2, the index has been mostly tumbling on a range of worries in its sharpest setback since it began soaring in the spring.