Dow jumps 1,041 points as Iran deal hopes lift S&P 500