Fernando Torres scored four times and missed a penalty as Spain cantered to a 10-0 victory over Tahiti in the Confederations Cup.