Sharapova and Jankovic were both at Nick Bolletieri's academy and played their first tour-level match nine years ago. The Russian has come out on top in seven of their eight matches, including earlier this year in Miami.
Four American women reached the last 16, the best showing at a grand slam since the US Open in 2004, but only Serena Williams is left after Bethanie Mattek-Sands joined Sloane Stephens and Hampton in exiting the tournament.
It has been a great week for Mattek-Sands, who beat former French Open champion Li Na in round two and was making her first appearance in the last 16 at Roland Garros.
She led 4-1 against 12th seed Maria Kirilenko but the Russian fought back to win 7-5 6-4 and now plays third seed Victoria Azarenka.
Mattek-Sands called for the doctor leading 5-4 in the opening set, while Kirilenko also took a medical time-out for treatment to her right shoulder in the second set but came through.
Kirilenko questioned her opponent's time-out, saying: "I was a little bit surprised. I was thinking she was kind of joking with me, so it was a little bit not maybe nice from her. Maybe she really had some problems. I don't know."
Mattek Sands explained: "It's that time of the month. I just needed a pill. The doctor gave me what he had and it helped."
Azarenka looked in fine form, beating former champion Francesca Schiavone 6-3 6-0.
The third seed has never previously been beyond the quarter-finals at Roland Garros but she is encouraged by the progress she has made on clay.
Azarenka said: "I think I'm learning more now and I'm adjusting much better.
"There's no doubt it's been always the most challenging (surface) for me, but I feel like I'm finally understanding what I need to do to improve.
"I feel it's a process, but I'm on the right way. That's the most important for me, to it take step by step. I hope I'm playing better than before, because otherwise that would be a step back.
"But I'm happy with the way my progress is going, and we'll see what happens next."