Ivanovic, seeded fourth, was 2-0 down in the second set before winning the next six games to take the match 7-5, 6-2. Gasparyan had three break points on Ivanovic's serve at 2-2 but failed to take advantage, became frustrated and never recovered.
"I really had to dig deep," Ivanovic said. "I'm really happy with the way I played today, especially in my first match."
Second-seeded Roberta Vinci secured her place in the quarterfinals by beating Belgium's Yanina Wickmayer 6-2, 7-6 (2). Vinci served for the match at 6-5 in the second set but was broken by Wickmayer, who proved unable to put up the same resistance in the following tiebreak.
Siegemund, who made the main draw as a lucky loser, took the initiative in the second set against Mladenovic to win 1-6, 7-5, 6-1.