SAN DIEGO -- Right from the start, Brandon Webb knew something was wrong.

The D-backs ace was able to get through the first two innings of Tuesday night's game without difficulty, but while the results were good, trouble was lurking.

"I don't know. I felt fine, but I just didn't have very good stuff," said Webb, who was going for his 20th win of the year.

That became evident in the third inning when the Padres scored five runs en route to a 9-2 win over the D-backs in front of 32,104 at PETCO Park.

The loss was the second straight for the D-backs to last-place San Diego and the fourth in their last five games. Arizona, however, did not lose any ground in the National League West standings and still lead the Dodgers, who have dropped five straight, by three games.

The Rockies, however, have taken advantage of the stumbles by the division's top two teams to pull to within six games.

The inning that doomed Webb (19-5) and the D-backs started off with back-to-back singles from Nick Hundley and Tadahito Iguchi. Webb fanned pitcher Chad Reineke before falling behind Brian Giles, 3-1. Webb came back with an 89 mph fastball that Giles crushed for a three-run homer.

Had the inning stopped there, the D-backs stood a fighting chance, but it continued to snowball with Webb helpless to stop it as the Padres scored two more on a Kevin Kouzmanoff double.

"I was just wanting to get out of that inning," Webb said. "It was just brutal. It was not fun and I just wasn't making any pitches at all. Couldn't get ahead, which I've been pretty good at the past few games, and that's always tough pitching from behind."

Webb rarely shows much emotion on the mound, but it was clear from his body language that inning how frustrated he was. It was the most runs he had allowed in an inning all year.

What added to the frustration is Webb knew his problem was mechanical -- he wasn't getting on top of the ball -- but just couldn't get it corrected.

"Just a bad outing for him," manager Bob Melvin said.

The offense was not able to bail Webb out because the hitters were able to do little with Reineke.

Arizona's lone offense came in the fourth, when Mark Reynolds hit a two-out, two-run homer.

The D-backs were able to get a pair of baserunners via walks against Reineke in the second and fifth innings, but could not get them home.

"Just couldn't get the big hit with the guys on base," Melvin said. "Who knows? In the first four or five innings maybe one more hit opens the floodgates a little bit, but we couldn't get the big hit. [Reineke] did get some strikeouts when we had guys on base, maybe [we were] trying to be a little too aggressive, maybe pressing a little too hard to come up with the big hit when we had some guys on."

Webb was struck in his rib cage by a line drive in his last start, but the injury did not bother him Tuesday.

"The rib didn't enter my mind at all," he said. "Just one of those nights."

Webb will get one more chance to pick up his 20th win before the month of September. If he's successful, he will become just the sixth pitcher to do that since 1990, joining Bob Welch ('90), Roger Clemens ('90 and '97), Jack McDowell ('93), John Smoltz ('96) and former D-backs righty Curt Schilling (2002).

To do that, though, he'll need to have better stuff than he did against the Padres.

"Curveball and changeup weren't really there either," said Webb, who has six starts left this year. "All the way around, it wasn't very good."