Now that Blu-ray disk of Avengers: Infinity War has been released, there's a special behind-the-scene video in which Russo Brothers clearly explain that after Loki and Chitauri army lost in Battle of New York, Thanos wanted to know the name of the man who foiled his plan and destroyed entire Chitauri fleet in the end. Well, Chitauri intelligence service was at his command and this is how he got to know the name of Stark.
Also, there's another Blu-ray special video in which they play an alternative script:
Ironman: How do you know my name?
Thanos: I know your soul. It's much like mine - cursed with knowledge.
This one may imply that Soul Stone gave Thanos an ability to peer into soul of Stark to know everything about him.
But, still, the answer to your question "How does Thanos know Tony Stark?" isn't Soul Stone. Because Thanos already knew Stark before acquiring Soul Stone as I described in the first part of the answer.