Federer won his second round match over Joao Sousa earlier in the day and he was back out again at around 5.30pm local time to play Coric.
And it was a sluggish start from the Swiss as he found himself 4-0 down and struggling to stay with the Croatian from the baseline.
Coric won the first set 6-2 and the second set went with serve until they traded breaks midway through then Federer broke his opponent again to take the set 6-4.
The final set was a tense affair as both men held serve to take the match into a deciding tiebreak and Federer was forced to save two match points before battling back and winning on his second match point.