Djokovic was in complete control of the match, leading 6-4 6-1 3-1 after an hour and a half on the Louis Armstrong Stadium court, when Wawrinka said he could not go on after getting medical help from his trainer at the change of ends.
"I really don't know exactly what it was but by the look of it, I think it was probably a dizziness or something," said Djokovic.
"He served well, he played well, but you could see that he didn't feel great on the court."
Djokovic, who won the US Open for the first time last year, will play Juan Martin del Potro in Thursday's quarter-finals after the Argentine beat retiring American Andy Roddick 6-7 7-6 6-2 6-4.
The world number two has not dropped a set in the tournament so far and is pleased with the way he is playing.
"It was really important for me to get the first set under my belt so I could get that mental advantage," he said.
"I think I have done well in important moments I served well.
"It's great that I haven't spent that much time on the court. I played well, and I'm looking forward to the quarter-finals."
Djokovic, however, could not hide his frustration at the length of time the match took to play. It started on Tuesday but was one of five matches held over until Wednesday because of rain.
In each of the last four years the men's final was delayed until the Monday due to foul weather, triggering an annual debate and complaints from players, including Djokovic, over why the main court was not covered.
"I really hope that they will reconsider in this event, and any other hard court event, to at least use covers if the roof is no option," he said.
"It doesn't change my opinion about this tournament. I still love playing here.
"But I just think that considering the experiences that we all had with weather in last four, five years, it's the most logical explanation and solution you can come up with."
Serbia's Janko Tipsarevic successfully wore down Germany's Philipp Kohlschreiber to win their rain-delayed fourth-round clash 6-3 7-6 6-2.
Kohlschreiber blasted 12 aces but was undone by 53 unforced errors in a two and a half hour clash that began on Tuesday and was suspended for a day because of rain.
Tipsarevic kept his cool in the tricky, windy conditions and eventually overcame his weary opponent, whose previous two matches had gone five sets.
"I'm extremely happy how I managed to play good on key and important moments in all three sets," Tipsarevic said. "I think this was the main difference. All three sets were, even though the score doesn't show it, really, really tight.
"But in important moments I guess because of the confidence I have and the way that I have being playing in the last couple months showed that I make the right decisions in the right moments of the match."
Tipsarevic, seeded eighth, has never made a semi-final at any grand slam. Standing in his way will be Spanish fourth seed David Ferrer, who beat the foul weather to win his fourth round match on Tuesday and get a day off.
"David is an established top five player, probably way more underestimated and people are not giving him enough credit for the achievements he has made in his career," Tipsarevic said.
"It's going to be a really, really difficult battle, because both of us are groundstroke players and we play well from the back.
"We don't have huge, huge weapons, so I think a guy who is tactically better and mentally stronger is going to be the winner."