Andrea Dovizioso led Sunday morning's MotoGP warm-up at Barcelona, with Avintia Ducati's Tito Rabat narrowly edging Valentino Rossi out for second.
Dovizioso set his time of 1m39.571s with six minutes left on the clock, taking first place from Marc Marquez, who had been the first rider to go below 1m40s four minutes earlier.
Avintia Ducati, which is running black bikes in honour of its rider Andreas Perez, who passed away last weekend in Spanish Moto3, took second, with Rabat falling just 0.082s short of Dovizioso's benchmark.
Yamaha's Rossi was 0.003s slower than Rabat in third with Marquez, one of two riders to use hard rears in the session, taking fourth.
The Honda rider narrowly beat Johann Zarco and pole-sitter Jorge Lorenzo, who was slightly held up by Aleix Espargaro on his final flyer.
Danilo Petrucci was seventh ahead of the top Suzuki of Andrea Iannone, his teammate Jack Miller, and Maverick Vinales.
Wildcard Mika Kallio was comfortably the fastest KTM in 14th, beating both Bradley Smith and Pol Espargaro by more than three tenths.
Aspar Ducati's Alvaro Bautista and Scott Redding, who ended up last, were the only crashers in the session.