There's a lot of overlap of varying degree of trickiness that makes it more of a spectrum than a clear binary, and so it often makes sense to treat them as a such.

In particular, SF plots often mix in significant fantasy themes to the point that they are sometimes a majority of the book.

Banks' Inversions is a Culture novel (SF) that intentionally reads as fantasy if you don't know the Culture setting, while leaving the reader to infer the SF setting if you do.

"Grass" by Sheri Tepper, or "Left Hand of Darkness" by Ursula Le Guin are other examples. Both happen on other planets, but while both have SF settings, most of the stories fits better into fantasy tropes.

Vernor Vinge's A Fire Upon the Deep is very explicit SF at "top level", but a significant part of the plot is closer to fantasy, happening on a planet in a pseudo-medieval setting.

Others like Stanisław Lem's The Cyberiad, while more explicit SF, also intentionally mix the two - being written as fantasy in a mock-medieval inspired proto-feudal society, where the characters engage in typical fantasy-inspired quests, with dragons, princes and princesses, with medieval weaponry, but with most characters being robots and with access to space travel...

There's a lot of overlap where authors toys with the distinctions, or outright mocks them.

I'd argue that the setting doesn't make "A Fire On The Deep" anything close to a fantasy. The Tines are a non-human species at a certain stage of development that's similar to humanity's medieval period. There's no more fantasy there than Michael Crichton's "Timeline."