As Bob Warwick mentions in his comment, this could well be Joe Haldeman’s The Forever War.
In this, William Mandella and his fellow soldier and lover Marygay Potter (sex between soldiers is compulsory in the novel, rather than something frowned upon) go off to fight in a distant interstellar war. They return across the vast distances of galactic space, and time dilation means that decades have passed on Earth. They go off to fight again, returning after even more time has passed (and many interesting sociological changes have taken place on Earth). Eventually they get separated by the military (they are too valuable as experienced soldiers to be used in the same battles) and lose contact.
William returns to Earth as the war ends…
… he finds Marygay again. She has been travelling around, making use of time dilation to remain young for when he eventually gets home. The novel ends with a report of the birth of their first child.
With the exception of the fact that neither of the characters are pilots (although they occasionally pilot craft), the other details fit well.