Improvement: use localhost time in tight loops

See the code comment in the receiver for an explanation.