Do you understand that 'average latency' is useless statistic that core has almost no impact on? Unless you mean something other than average latency over all clients of course
CMSG_PING is handled in WorldSocket::ProcessIncoming. It's handled on ACE network reactor that is (almost) not touched by TC development team.
Also- latency that client sends is almost useless for any measurements, as it is updated only with one packet every 30 seconds.