PHOENIX -- Zack Greinke and David Peralta delivered in a game Arizona manager Torey Lovullo said the Diamondbacks needed to stop a lengthy losing streak.
Greinke pitched seven strong innings and helped himself with two hits, Peralta connected for a pinch-hit, three-run homer and the Diamondbacks beat the San Diego Padres 8-4 Sunday to stop a four-game losing streak.
The Padres had won four in a row.
Peralta, out of the starting lineup for the first time this season, came up with two outs in the sixth against reliever Matt Wisler. Peralta's opposite-field home run curled over the fence in left and into the Arizona bullpen for a 6-2 lead. It was Peralta's first career pinch-hit homer.
"When it comes time to step into the box and do something for your team, you have to be ready for it," Peralta said. "It's not about the homer. When you do something special to help the team to win, it's always good."
Greinke (2-1) allowed two runs and four hits with six strikeouts. He won despite surrendering his seventh and eighth home runs of the season.
"Put some balls in play and found some holes," Greinke said. "Pitching, felt like I did a good job keeping them off balance."
A career .224 hitter, Greinke doubled, singled and scored twice.
"Overall, it started and stopped with Zack. He did a terrific job, and that's why he's our ace," Lovullo said.
Ketel Marte and Christian Walker also homered for the Diamondbacks. Marte's homer barely cleared the left-field wall and the glove of left fielder Hunter Renfroe.
"You'd love to see him catch that. Any ball that goes over the fence, it is hard to say the guy should have caught it," Padres manager Andy Green said. "Whenever you are jumping into the wall ... you see it all the time, if you get too close to the wall, a guy goes up, catches his shoulder on the wall and can't get up. That's ultimately what happened there."
Manuel Margot led off the game with a home run and Fernando Tatis Jr. also connected for NL West-leading San Diego. The 20-year-old Tatis homered for the second straight day and has five in his rookie season.
Padres starter Eric Lauer (2-2) gave up three runs on eight hits over five innings.
Greinke led off the bottom of the third with a bloop single and two outs later came home on Marte's homer. Greinke made a nice defensive play in the fourth, starting a double play on a comebacker in which he bounded off the mound to his right to retrieve the ball and throw to second base.
Greinke doubled in the fifth, took third on a wild pitch and scored when Ildemaro Vargas grounded a one-out double past first base.
INSIDE PITCHES IRK GREEN
Diamondbacks closer Greg Holland threw a couple of tight inside pitches in the bottom of the ninth to the Padres' Francisco Mejia, raising questions about whether it was in retaliation for Padres pitchers hitting two Diamondbacks with pitches on Saturday.
Lovullo said all that mattered was that Holland got three outs to end the game. But Green had some choice words for the umpire crew.
"Umpires being literally clueless on the field right now. That's inexcusable at that point in time," Green said. "The first one, OK maybe slips. The second one, we know what is going on there. It is not lost on us at all. If it is lost on them (umpires), they are not paying attention to the baseball game."
San Diego called up RHPs Phil Maton and Luis Perdomo from Triple-A El Paso before the game and optioned right-handers Gerardo Reyes and Robert Stock to El Paso. Reyes got a win in his big league debut on Friday. Stock appeared as recently as Saturday and has pitched in seven games.
Padres: 3B Manny Machado didn't play Sunday, missing his first game of the season for rest.
Padres: Return home for to open a series with the Colorado Rockies on Monday, sending LHP Joey Lucchesi to the mound. Lucchesi (2-1, 4.40 ERA) made 26 starts last season as a rookie.
Diamondbacks: Get Monday off before opening a series in Atlanta. LHP Robbie Ray (0-1, 3.52) is scheduled to start Tuesday's opener, and he has allowed three or fewer hits in three straight starts to begin the season.
More AP MLB: https://apnews.com/MLB and https://twitter.com/AP-Sports