SAN FRANCISCO (AP) — Arizona was officially eliminated from the postseason with its 5-1 loss to the San Francisco Giants on Sunday. The inevitable didn't surprise Diamondbacks manager Chip Hale.

"We had our shot at the end of August and early September," Hale said. "We didn't hold our end of the bargain up."

Hale still wants to win as many games as possible, and A.J. Pollock feels the same way.

"We're concentrating on playing good baseball," said the center fielder. "I haven't looked at the standings in a really long time."

The Diamondbacks ran into nemesis Tim Hudson, who likely beat Arizona for the final time. He's announced he's retiring after this season.

"It's a great career. The guy is a warrior," Hale said. "I'm sure he's over there 75 percent physically, still pitching. It's sad to see him go away. He's a 100 percent battler."

Hudson (8-8) gave up four hits in improving to 11-2 with a 2.19 ERA in 16 starts against the Diamondbacks. He walked three and struck out three. Hudson won his third consecutive decision and has a 2.10 ERA over his past four starts. He also earned career win No. 222.

David Peralta homered, and Ender Inciarte had three hits for the Diamondbacks, who had won three of their previous four games.

It was still a scoreless tie when Hudson sat down next to Buster Posey after the top of the sixth.

"It was funny," Hudson said. "I said, 'Come on boys, let's get four,' without really thinking we would get four. Sometimes you just have to ask for it."

Posey's three-run homer helped give the Giants a 4-0 lead.

Santiago Casilla gave up Peralta's 16th home run of the season with one out in the ninth.

Jeremy Hellickson (9-10) took a one-hitter into the sixth before giving up a single to Angel Pagan and a run-scoring double to Alejandro De Aza. Arizona pitchers had an overall 27-inning scoreless streak end. It was the second longest run in franchise history behind a 31-inning streak in July of 2002.

"I walk away a little disappointed," Hellickson said. "My command was pretty good, even in sixth inning I executed my pitches. Good pitches, maybe not the right pitch for the situation."

Randall Delgado came on to walk Matt Duffy ahead of Posey's 19th home run of the year. Posey has driven in 10 runs over his last seven games and has 93 on the season.

The Diamondbacks won eight of the 10 games they played at AT&T Park this year, and their pitchers compiled an ERA of 1.68.

TRAINER'S ROOM:

Diamondbacks: RHP Chase Anderson, who has appeared in two games in September, will return to the starting rotation on Wednesday against the Dodgers in Los Angeles. He's replacing Rubby De La Rosa, who has struggled against the Dodgers. Anderson is 6-6 with a 4.52 ERA.

Giants: C Andrew Susac underwent successful wrist surgery and should be at full strength in spring training. ... OF Hunter Pence has not been able to hit off a batting tee and will likely not make it back into the lineup this season.

UP NEXT:

Diamondbacks: RHP Jhoulys Chacin (0-1, 2.95) starts Monday night's series opener at the Dodgers. Chacin is 4-3 with a 2.89 ERA at Dodger Stadium.

Giants: Following an off day, RHP Chris Heston (11-10, 3.61) starts against the Padres in San Diego on Tuesday. He's 0-5 with a 5.03 ERA in his last eight starts.