Tuesday night’s 3-2 loss to the Pittsburgh Pirates was painful on a couple of levels for the Arizona Diamondbacks.

First, the loss spoiled Wade Miley’s best start of the season. The left-hander didn’t allow a hit until the fifth inning and struck out 10 batters over eight innings of work. Miley did allow back-to-back singles to Neil Walker and Gregory Polanco to start the ninth and was relieved by Addison Reed, who eventually took the loss on Ike Davis’ walk-off RBI single.

Second, the D-backs fell to 35-50, marking just the second time they’ve dipped as many as 15 games below .500 on the season.

The constant struggles of the club have led to continued speculation about the job security of general manager Kevin Towers. But even through the tough times, Towers is focused on the things he can control.

“When it comes to job security, I’ve never really worried about it,” Towers said on the Doug and Wolf Show Wednesday on Arizona Sports 98.7 FM. “I figure every year you’re under the gun regardless of the length of your contract. You’re judged on wins and losses and ultimately, the people above you make the decision if you’re the right guy to lead this organization going forward or not.”

The All-Star break is less than two weeks away, possibly fueling more speculation that the struggling D-backs could make a front office change at that point. However, Towers still believes the team can improve.

“Hopefully I can help (manager Kirk Gibson) out and work with Gibby to try to get this thing turned around,” he said. “I’ve seen a few clubs that have made runs. The good thing is this year is that there is so much parity in the game. Clubs that have been 12 or 13 games under have made a little run.

“We’re going to need a good streak but it’s probably going to take us getting back healthy to get that streak together. Hopefully (Mark) Trumbo gives us a little jump start.”

Trumbo is one of 11 Diamondbacks on the disabled list. The outfielder, who is recovering from a stress fracture in his left foot, began a minor-league rehab assignment in rookie league Tuesday.

“Regardless of what happens, I care a lot about the organization. Not only now, but the future, and as we approach the deadline, regardless of my tenure here, I want to do what’s best for this organization going forward,” Towers said. “So if I’m here or I’m not here, at least my legacy won’t be a negative one — it’ll be a good one. We’ve got a good corps of young players with a chance to win.”