Romania's Simona Halep, left, shakes hands with United States' Lauren Davis as she won their third round match at the Australian Open tennis championships in Melbourne, Australia, Saturday, Jan. 20, 2018. (AP Photo/Ng Han Guan)

United States' Lauren Davis falls during her third round match against Romania's Simona Halep at the Australian Open tennis championships in Melbourne, Australia, Saturday, Jan. 20, 2018. (AP Photo/Vincent Thian)

United States' Lauren Davis yells in frustration during her third round match against Romania's Simona Halep at the Australian Open tennis championships in Melbourne, Australia, Saturday, Jan. 20, 2018. (AP Photo/Vincent Thian)

Romania's Simona Halep celebrates after defeating United States' Lauren Davis in their third round match at the Australian Open tennis championships in Melbourne, Australia, Saturday, Jan. 20, 2018. (AP Photo/Vincent Thian)

Romania's Simona Halep celebrates after defeating United States' Lauren Davis in their third round match at the Australian Open tennis championships in Melbourne, Australia, Saturday, Jan. 20, 2018. (AP Photo/Vincent Thian)

MELBOURNE, Australia (AP) — Simona Halep joked she was "almost dead" after her 4-6, 6-4, 15-13 win over Lauren Davis in the third round of the Australian Open on Saturday, a grueling 3-hour, 45-minute match that featured a countless energy-sapping rallies and a remarkable 38 break points.

But what Halep said got her through the match wasn't her legs, it was her head.

This is a big change for a player who has sometimes wilted under pressure.

"For sure, I'm stronger mentally, and I could resist like (that) for every moment in the match," Halep said. "That makes me very happy, and I think the big win is that I could handle it."

No. 1-ranked Halep has won 15 titles in her career and is a perennial contender at the majors, but has never won a Grand Slam. In last year's French Open final against Jelena Ostapenko, Halep was up a set and 3-0 and still went on to lose.

Against Davis, however, Halep held her nerve as the third set wore on and her 24-year-old opponent seemed to be gaining in confidence.

The critical moment came when she was serving at 10-11 and found herself down 0-40, facing three match points. Halep remained composed and saved them all — the first time she's come back from triple match point down in her career.

The 26-year-old Romanian also didn't get too down after wasting chance after chance to put Davis away. She blew four break points at 8-all, then another five break points at 11-all, before finally converting to take a pivotal 14-13 lead and serve it out.

The match equaled the longest-ever in the women's draw at the Australian Open in terms of games played — Chanda Rubin's win over Arantxa Sanchez Vicario in 1996 was also 48 games — but was almost an hour shorter in duration than the record 4:44 that Francesca Schiavone needed to beat Svetlana Kuznetsova in 2011.

Had this kind of match happened a year or two ago, Halep admitted, she might not have won it.

"It's much better if we compare the old Simona with the new Simona," she said. "I'm just trying to change myself to not think that much about the points."

The other challenge was also playing an opponent like Davis, who is similarly short in stature and plays a mirror-image game. Like Halep, Davis relies on speed and footwork to make up for her lack of power. And both women are scrappy competitors, doggedly chasing down every ball that comes their way.

"I think today she played the highest level in tennis," Halep said "And her backhand was just too good sometimes."

Davis, who at 5-foot-2 (1.57-meter) is the shortest women in the top 100, surprised herself, as well. She's been ranked as high as No. 26, but has never advanced beyond the third round at a major.

Playing such a tough match against Halep, however, showed Davis just how competitive she could be.

"We were both fighting our hearts out," she said. "I got to the point where I was so tired where I just told myself to swing and move, and, I mean, for the most part it was very effective."

It was effective for Halep, too.

"I think in the past I wouldn't have fought that hard," she said. "Doesn't matter what is gonna happen now. I say that it's a big win in many ways, and I take it."