From 72e775bac71b2d4b5103a0e8a6f03875b1617321 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 8 Oct 2013 22:16:08 +0300 Subject: extent profiler logging into some functions. --- src/net/tmwa/network.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/net/tmwa/network.cpp') diff --git a/src/net/tmwa/network.cpp b/src/net/tmwa/network.cpp index a843c9b6b..175713d49 100644 --- a/src/net/tmwa/network.cpp +++ b/src/net/tmwa/network.cpp @@ -138,10 +138,11 @@ void Network::clearHandlers() void Network::dispatchMessages() { - BLOCK_START("Network::dispatchMessages") + BLOCK_START("Network::dispatchMessages 1") while (messageReady()) { SDL_mutexP(mMutex); + BLOCK_START("Network::dispatchMessages 2") const int msgId = readWord(0); int len; if (msgId == SMSG_SERVER_VERSION_RESPONSE) @@ -156,6 +157,8 @@ void Network::dispatchMessages() MessageIn msg(mInBuffer, len); SDL_mutexV(mMutex); + BLOCK_END("Network::dispatchMessages 2") + BLOCK_START("Network::dispatchMessages 3") if (len == 0) { @@ -175,8 +178,9 @@ void Network::dispatchMessages() } skip(len); + BLOCK_END("Network::dispatchMessages 3") } - BLOCK_END("Network::dispatchMessages") + BLOCK_END("Network::dispatchMessages 1") } bool Network::messageReady() -- cgit v1.2.3-70-g09d2