More wrapping code, logging for latency test