What's the best way to measure network latency between two imps?

I’d like to measure the network latency between two imps, one of which will be frequently (~2Hz) sending data to the other via ports. time()/date() only give the time down to seconds, and other functions are available that give process-relative time in milliseconds, but I’d rather avoid the math headache of deriving UTC down to the milliseconds or the equivalent as required for estimating delay. Suggestions?

We have ms/us timers in release-12. Until then you might need to use external equipment…