ALTO DE LA COVATILLA, Spain — Primoz Roglic is poised to win his second consecutive Spanish Vuelta title after defending his slim lead over Richard Carapaz on the last competitive stage on Saturday.

Carapaz beat Roglic to the finish line of the mountainous 17th stage, but the Slovenian rider managed to protect his overall advantage. Roglic's lead over Carapaz was cut from 45 to 24 seconds ahead of Sunday's largely ceremonial stage.

France's David Gaudu won the grueling 178-kilometer (110-mile) ride from Sequeros to the beyond-category summit at the top of the Alto de la Covatilla.

Sunday's ride to Madrid is now set to be a chance for Roglic and his Jumbo-Visma teammates to savor the victory — two months after he came one day from winning this year's Tour de France.