US stocks end mixed after volatile session as indexes notch weekly losses

The S&P 500 suffered its first weekly loss in three weeks and notched its worst one-week decline since December.